diff options
author | Přemysl Janouch <p.janouch@gmail.com> | 2016-09-28 05:27:22 +0200 |
---|---|---|
committer | Přemysl Janouch <p.janouch@gmail.com> | 2016-09-28 05:27:22 +0200 |
commit | 1f60d096ea3ce54c0a31107c6b8be34b3c42f11f (patch) | |
tree | 84b6cc234b008efb79856299fe1fed74847eede6 /src | |
parent | 30345ec8d4e9093452cc1798caede15e28dc4841 (diff) | |
download | tdv-1f60d096ea3ce54c0a31107c6b8be34b3c42f11f.tar.gz tdv-1f60d096ea3ce54c0a31107c6b8be34b3c42f11f.tar.xz tdv-1f60d096ea3ce54c0a31107c6b8be34b3c42f11f.zip |
Fix mouse in the search bar
Diffstat (limited to 'src')
-rw-r--r-- | src/sdtui.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/sdtui.c b/src/sdtui.c index f2bf15c..f14b920 100644 --- a/src/sdtui.c +++ b/src/sdtui.c @@ -1671,12 +1671,13 @@ app_process_left_mouse_click (Application *self, int line, int column) ; // At the moment there's nothing useful for us to do else if (line == 1) { + // FIXME: this is only an approximation gsize label_len = g_utf8_strlen (self->search_label, -1); gint pos = column - label_len; if (pos >= 0) { self->input_pos = MIN ((guint) pos, self->input->len); - move (0, label_len + self->input_pos); + move (1, label_len + self->input_pos); refresh (); } } |