[vte/wip/egmont/bidi: 30/77] off by one
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/wip/egmont/bidi: 30/77] off by one
- Date: Fri, 30 Nov 2018 11:59:07 +0000 (UTC)
commit 7cde816a1d14fa581df2230e3f00a0b5691c6572
Author: Egmont Koblinger <egmont gmail com>
Date: Fri Aug 24 09:45:25 2018 +0200
off by one
src/bidi.cc | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/bidi.cc b/src/bidi.cc
index 0a110cfb..e7713912 100644
--- a/src/bidi.cc
+++ b/src/bidi.cc
@@ -282,7 +282,7 @@ long RingView::paragraph(long row)
/* Extract the paragraph's contents, omitting unused and fragment cells. */
while (row < m_start + m_len) {
- row_data = m_ring->index(row++);
+ row_data = m_ring->index(row);
if (row_data == nullptr)
break;
@@ -306,6 +306,7 @@ long RingView::paragraph(long row)
}
lines[++line] = c;
+ row++;
if (!row_data->attr.soft_wrapped)
break;
@@ -351,7 +352,7 @@ long RingView::paragraph(long row)
m_bidirows[row - m_start].rtl = rtl;
map = m_bidirows[row - m_start].map;
- row_data = m_ring->index(row++);
+ row_data = m_ring->index(row);
if (row_data == nullptr)
break;
@@ -456,6 +457,7 @@ long RingView::paragraph(long row)
next_line:
line++;
+ row++;
if (!row_data->attr.soft_wrapped)
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]