summaryrefslogtreecommitdiff
path: root/gramscii.h
diff options
context:
space:
mode:
Diffstat (limited to 'gramscii.h')
-rw-r--r--gramscii.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/gramscii.h b/gramscii.h
index a08d211..73b9db7 100644
--- a/gramscii.h
+++ b/gramscii.h
@@ -44,6 +44,9 @@
#define VIDEO_NRM 0
#define VIDEO_REV 7
+#define CUR 0x01
+#define LST 0x02
+
/** types **/
typedef struct{
@@ -59,6 +62,7 @@ typedef struct{
line_t *l;
} lineset_t;
+
/** MACROS **/
#define MIN(x,y) (x) < (y) ? (x) : (y)
@@ -73,6 +77,11 @@ typedef struct{
lineset_t screen;
lineset_t cutbuf;
+lineset_t *undo;
+
+int undo_sz;
+int undo_cur;
+int undo_lst;
int WIDTH, HEIGHT;
@@ -155,6 +164,8 @@ void ensure_line_length(line_t *l, int len);
void ensure_num_lines(lineset_t *ls, int n);
void yank_region(int x1, int y1, int x2, int y2);
void paste_region(int x1, int y1);
-
+void copy_lines_to_ring(int y1, int y2, int which);
+void undo_change();
+void redo_change();
#endif