summary refs log tree commit diff
path: root/chat.h
diff options
context:
space:
mode:
Diffstat (limited to 'chat.h')
-rw-r--r--chat.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/chat.h b/chat.h
index eecb7d9..b7de9ac 100644
--- a/chat.h
+++ b/chat.h
@@ -396,6 +396,22 @@ int bufferReflow(
 	struct Buffer *buffer, int cols, enum Heat thresh, size_t tail
 );
 
+struct Cursor {
+	uint gen;
+	struct Node *node;
+};
+void cacheInsert(bool touch, uint id, const char *key);
+void cacheInsertColor(bool touch, uint id, const char *key, enum Color color);
+void cacheReplace(bool touch, const char *old, const char *new);
+enum Color cacheColor(uint id, const char *key);
+const char *cachePrefix(struct Cursor *curs, uint id, const char *prefix);
+const char *cacheSubstr(struct Cursor *curs, uint id, const char *substr);
+uint cacheID(struct Cursor *curs, const char *key);
+void cacheAccept(struct Cursor *curs);
+void cacheReject(struct Cursor *curs);
+void cacheRemove(uint id, const char *key);
+void cacheClear(uint id);
+
 const char *complete(uint id, const char *prefix);
 const char *completeSubstr(uint id, const char *substr);
 void completeAccept(void);