summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPaul LeoNerd Evans <leonerd@leonerd.org.uk>2015-01-03 02:32:45 +0000
committerPaul LeoNerd Evans <leonerd@leonerd.org.uk>2015-01-03 02:32:45 +0000
commitfd91c06a0b71c7e739397eb707090bb20818ca8e (patch)
tree892a7d2399bef9b812dee662a875dcb59dbfbef6 /include
parent5517d6ccf386c106d3b329b573abb23c14f93af7 (diff)
Provide new mouse API functions at toplevel, first stage of killing setmousefunc
Diffstat (limited to 'include')
-rw-r--r--include/vterm.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/vterm.h b/include/vterm.h
index 75fd3c4..a543039 100644
--- a/include/vterm.h
+++ b/include/vterm.h
@@ -7,6 +7,7 @@ extern "C" {
#include <stdint.h>
#include <stdlib.h>
+#include <stdbool.h>
#include "vterm_keycodes.h"
@@ -97,7 +98,7 @@ enum {
VTERM_PROP_CURSORSHAPE_BAR_LEFT,
};
-typedef void (*VTermMouseFunc)(int x, int y, int button, int pressed, int modifiers, void *data);
+typedef void (*VTermMouseFunc)(int col, int row, int button, int pressed, int modifiers, void *data);
typedef struct {
const uint32_t *chars;
@@ -140,6 +141,9 @@ size_t vterm_output_bufferread(VTerm *vt, char *buffer, size_t len);
void vterm_keyboard_push_unichar(VTerm *vt, VTermModifier state, uint32_t c);
void vterm_keyboard_push_key(VTerm *vt, VTermModifier state, VTermKey key);
+void vterm_mouse_move(VTerm *vt, int row, int col, VTermModifier mod);
+void vterm_mouse_button(VTerm *vt, int button, bool pressed, VTermModifier mod);
+
// ------------
// Parser layer
// ------------