summaryrefslogtreecommitdiff
path: root/txt.h
diff options
context:
space:
mode:
Diffstat (limited to 'txt.h')
-rw-r--r--txt.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/txt.h b/txt.h
index ccc71be..3af9970 100644
--- a/txt.h
+++ b/txt.h
@@ -19,15 +19,16 @@ typedef struct {
} TxtBuf;
typedef struct {
- u32 p, i;
-} TxtLoc;
-
-typedef struct {
DYNARR(TxtPiece) ptbl;
TxtBuf buf[2];
u32 len;
} Txt;
+typedef struct {
+ Txt *t;
+ u32 p, i;
+} TxtLoc;
+
u32 txt_split_piece(Txt *b, u32 pi, u32 i);
void txt_remove_piece(Txt *b, u32 pi);
void txt_insert_piece(Txt *b, u32 pi, TxtBufIdx buf, u32 ofs, u32 n);