[vte/vte-0-54] widget: Don't show the cursor occasionally over the scrollback data



commit a64ca825cae1567d5ac7b10b39a9de98b09b57ab
Author: Egmont Koblinger <egmont gmail com>
Date:   Tue Nov 27 23:13:57 2018 +0100

    widget: Don't show the cursor occasionally over the scrollback data
    
    https://gitlab.gnome.org/GNOME/vte/issues/75
    (cherry picked from commit 75b4f8440bc00fecec0286a452e7b182c46079bb)

 src/vte.cc | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/src/vte.cc b/src/vte.cc
index 26bd6f1e..bdae253d 100644
--- a/src/vte.cc
+++ b/src/vte.cc
@@ -9441,7 +9441,10 @@ Terminal::paint_cursor()
        width = m_cell_width;
        height = m_cell_height;
 
-        /* TODOegmont: clamp on rows? tricky... */
+        /* Show a tiny bit of an outline rectangle cursor just under the last displayed row,
+         * hence the +1. The cursor can't be offscreen in the other direction vertically. */
+        if (drow > last_displayed_row() + 1)
+                return;
        if (CLAMP(col, 0, m_column_count - 1) != col)
                return;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]