[vte/vte-0-36] widget: Fix painting the preedit text near the right margin
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/vte-0-36] widget: Fix painting the preedit text near the right margin
- Date: Fri, 2 Oct 2015 17:54:15 +0000 (UTC)
commit e7415dd121fb4cf6c37301198047b2b38b1e1b59
Author: Egmont Koblinger <egmont gmail com>
Date: Fri Oct 2 19:52:58 2015 +0200
widget: Fix painting the preedit text near the right margin
https://bugzilla.gnome.org/show_bug.cgi?id=755668
(cherry picked from commit d69645413f35ba6ebff9359a89bd121733a2e475)
src/vte.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/vte.c b/src/vte.c
index 77b249c..508dc00 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -744,9 +744,9 @@ _vte_invalidate_cursor_once(VteTerminal *terminal, gboolean periodic)
columns++;
}
}
- if (preedit_width > 0) {
- columns += preedit_width;
- columns++; /* one more for the preedit cursor */
+ columns = MAX(columns, preedit_width);
+ if (column + columns > terminal->column_count) {
+ column = MAX(0, terminal->column_count - columns);
}
_vte_debug_print(VTE_DEBUG_UPDATES,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]