diff options
Diffstat (limited to 'x11-libs/vte/files/vte-ng-0.42.4/02-expose-function-for-setting.patch')
| -rw-r--r-- | x11-libs/vte/files/vte-ng-0.42.4/02-expose-function-for-setting.patch | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/x11-libs/vte/files/vte-ng-0.42.4/02-expose-function-for-setting.patch b/x11-libs/vte/files/vte-ng-0.42.4/02-expose-function-for-setting.patch new file mode 100644 index 00000000..df0a2f8f --- /dev/null +++ b/x11-libs/vte/files/vte-ng-0.42.4/02-expose-function-for-setting.patch @@ -0,0 +1,56 @@ +expose function for setting the cursor position + +From: Daniel Micay <danielmicay@gmail.com> + + +--- + src/vte.cc | 22 ++++++++++++++++++++++ + src/vte/vteterminal.h | 2 ++ + 2 files changed, 24 insertions(+) + +diff --git a/src/vte.cc b/src/vte.cc +index af75d2d..5daa311 100644 +--- a/src/vte.cc ++++ b/src/vte.cc +@@ -6529,6 +6529,28 @@ vte_terminal_get_cursor_position(VteTerminal *terminal, + } + } + ++/** ++ * vte_terminal_set_cursor_position: ++ * @terminal: a #VteTerminal ++ * @column: the new cursor column ++ * @row: the new cursor row ++ * ++ * Set the location of the cursor. ++ */ ++void ++vte_terminal_set_cursor_position(VteTerminal *terminal, ++ long column, long row) ++{ ++ g_return_if_fail(VTE_IS_TERMINAL(terminal)); ++ ++ _vte_invalidate_cursor_once(terminal, FALSE); ++ terminal->pvt->screen->cursor.col = column; ++ terminal->pvt->screen->cursor.row = row; ++ _vte_invalidate_cursor_once(terminal, FALSE); ++ _vte_check_cursor_blink(terminal); ++ vte_terminal_queue_cursor_moved(terminal); ++} ++ + /* Place the selected text onto the clipboard. Do this asynchronously so that + * we get notified when the selection we placed on the clipboard is replaced. */ + static void +diff --git a/src/vte/vteterminal.h b/src/vte/vteterminal.h +index f9c95ed..4a03a96 100644 +--- a/src/vte/vteterminal.h ++++ b/src/vte/vteterminal.h +@@ -290,6 +290,8 @@ char *vte_terminal_get_text_range(VteTerminal *terminal, + void vte_terminal_get_cursor_position(VteTerminal *terminal, + glong *column, + glong *row) _VTE_GNUC_NONNULL(1); ++void vte_terminal_set_cursor_position(VteTerminal *terminal, ++ long column, long row) _VTE_GNUC_NONNULL(1); + + /* Add a matching expression, returning the tag the widget assigns to that + * expression. */ |
