[vte/wip/egmont/bidi: 41/82] fix crash when scrolling back
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/wip/egmont/bidi: 41/82] fix crash when scrolling back
- Date: Wed, 12 Sep 2018 11:55:07 +0000 (UTC)
commit 9d0377ce08f3894d33ba61b2d3c371a7bfb5ba6c
Author: Egmont Koblinger <egmont gmail com>
Date: Thu Aug 23 00:53:53 2018 +0200
fix crash when scrolling back
src/vte.cc | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/vte.cc b/src/vte.cc
index e207123d..bb4470c8 100644
--- a/src/vte.cc
+++ b/src/vte.cc
@@ -9059,7 +9059,7 @@ Terminal::draw_rows(VteScreen *screen_,
// FIXME find a nicer place for these
m_ringview.set_ring (m_screen->row_data);
- m_ringview.set_rows ((long) m_screen->scroll_delta, m_row_count + 2);
+ m_ringview.set_rows ((long) m_screen->scroll_delta, m_row_count + 3);
m_ringview.set_width (m_column_count);
m_ringview.update ();
@@ -9463,7 +9463,9 @@ Terminal::paint_cursor()
width = m_cell_width;
height = m_cell_height;
- /* TODOegmont: clamp on rows? tricky... */
+ /* An outer rectangle might even peek in from a line that's completely scrolled out at the bottom. */
+ if (drow > last_displayed_row() + 1)
+ return;
if (CLAMP(col, 0, m_column_count - 1) != col)
return;
@@ -9472,7 +9474,7 @@ Terminal::paint_cursor()
// FIXME find a nicer place for these
m_ringview.set_ring (m_screen->row_data);
- m_ringview.set_rows ((long) m_screen->scroll_delta, m_row_count + 2);
+ m_ringview.set_rows ((long) m_screen->scroll_delta, m_row_count + 3);
m_ringview.set_width (m_column_count);
m_ringview.update ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]