Cursor PreviousLine should respect the top margin

From esctest:
CPLTests.test_CPL_StopsAtTopMarginInScrollRegion
wilder
Luis Javier Merino Morán 5 years ago
parent d2437fbb2b
commit 717b615ab6
  1. 3
      src/Screen.cpp

@ -155,7 +155,8 @@ void Screen::cursorPreviousLine(int n)
n = 1; // Default
}
_cuX = 0;
_cuY = qMax(0, _cuY - n);
const int stop = _cuY < _topMargin ? 0 : _topMargin;
_cuY = qMax(stop, _cuY - n);
}
void Screen::cursorRight(int n)

Loading…
Cancel
Save