Hi,
Mouse wheel scrolling works in neovim, which goes in TSM_VTE_MOUSE_MODE_SGR. However when entering tmux or vim, it does not work. I've confirmed they enter TSM_VTE_MOUSE_MODE_VT200.
Adding the same piece of code for translating the mouse button enum to 64/65 fixed the problem:
diff --git a/src/tsm/tsm-vte.c b/src/tsm/tsm-vte.c
index 120ca65..d3b2df7 100644
--- a/src/tsm/tsm-vte.c
+++ b/src/tsm/tsm-vte.c
@@ -3404,6 +3404,12 @@ bool tsm_vte_handle_mouse(struct tsm_vte *vte, unsigned int cell_x,
cell_y = 0xff;
}
+ if (button == TSM_MOUSE_BUTTON_WHEEL_UP) {
+ button = 64;
+ } else if (button == TSM_MOUSE_BUTTON_WHEEL_DOWN) {
+ button = 65;
+ }
+
if (event & TSM_MOUSE_EVENT_RELEASED) {
/* translates to released but the information which key is
* released gets lost by design of this encoding scheme */
Hi,
Mouse wheel scrolling works in neovim, which goes in TSM_VTE_MOUSE_MODE_SGR. However when entering tmux or vim, it does not work. I've confirmed they enter TSM_VTE_MOUSE_MODE_VT200.
Adding the same piece of code for translating the mouse button enum to 64/65 fixed the problem: