summaryrefslogtreecommitdiff
path: root/src/main/bindings.h
diff options
context:
space:
mode:
authorAlbert Cervin <albert@acervin.com>2024-09-17 08:47:03 +0200
committerAlbert Cervin <albert@acervin.com>2025-11-01 22:11:14 +0100
commit4459b8b3aa9d73895391785a99dcc87134e80601 (patch)
treea5204f447a0b2b05f63504c7fe958ef9bbf1918a /src/main/bindings.h
parent4689f3f38277bb64981fc960e8e384e2d065d659 (diff)
downloaddged-4459b8b3aa9d73895391785a99dcc87134e80601.tar.gz
dged-4459b8b3aa9d73895391785a99dcc87134e80601.tar.xz
dged-4459b8b3aa9d73895391785a99dcc87134e80601.zip
More lsp support
This makes the LSP support complete for now: - Completion - Diagnostics - Goto implementation/declaration - Rename - Documentation - Find references
Diffstat (limited to 'src/main/bindings.h')
-rw-r--r--src/main/bindings.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/main/bindings.h b/src/main/bindings.h
index 96f20fd..74f43e3 100644
--- a/src/main/bindings.h
+++ b/src/main/bindings.h
@@ -1,15 +1,24 @@
#include <stdint.h>
+#include "dged/hook.h"
+
struct keymap;
struct buffer;
struct binding;
void init_bindings(void);
+struct keymap *buffer_default_keymap(void);
+
typedef uint64_t buffer_keymap_id;
buffer_keymap_id buffer_add_keymap(struct buffer *buffer, struct keymap keymap);
void buffer_remove_keymap(buffer_keymap_id id);
uint32_t buffer_keymaps(struct buffer *buffer, struct keymap *keymaps[],
uint32_t max_nkeymaps);
+typedef uint32_t (*buffer_keymaps_cb)(struct buffer *, struct keymap **,
+ uint32_t, void *);
+uint32_t buffer_add_keymaps_hook(buffer_keymaps_cb callback, void *userdata);
+void buffer_remove_keymaps_hook(uint32_t id, remove_hook_cb callback);
+
void destroy_bindings(void);