/*
-This file is part of the visor text editor and text editor framework
+visor - lightweight system-independent text editor and framework
Copyright (C) 2019 John Tsiombikas <nuclear@member.fsf.org>
This program is free software: you can redistribute it and/or modify
struct vi_buffer;
struct vi_span {
- vi_addr beg;
+ vi_addr start;
unsigned long size;
+ int src;
};
enum vi_motdir {
int vi_buf_write(struct vi_buffer *vb, const char *path);
long vi_buf_size(struct vi_buffer *vb);
+/* find the span which corresponds to the specified text position */
+struct vi_span *vi_buf_find_span(struct vi_buffer *vb, vi_addr at);
+
void vi_buf_ins_begin(struct vi_buffer *vb, vi_motion mot);
void vi_buf_insert(struct vi_buffer *vb, char *s);
void vi_buf_ins_end(struct vi_buffer *vb);