mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
test: Fix clear/eol_clear in screen.lua
These functions need to operate on the current the scroll region.
This commit is contained in:
parent
9b4f6fbd33
commit
1ccbd94bee
@ -185,12 +185,13 @@ function Screen:_handle_resize(width, height)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function Screen:_handle_clear()
|
function Screen:_handle_clear()
|
||||||
self:_clear_block(1, self._height, 1, self._width)
|
self:_clear_block(self._scroll_region.top, self._scroll_region.bot,
|
||||||
|
self._scroll_region.left, self._scroll_region.right)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Screen:_handle_eol_clear()
|
function Screen:_handle_eol_clear()
|
||||||
local row, col = self._cursor.row, self._cursor.col
|
local row, col = self._cursor.row, self._cursor.col
|
||||||
self:_clear_block(row, 1, col, self._width - col)
|
self:_clear_block(row, 1, col, self._scroll_region.right - col)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Screen:_handle_cursor_goto(row, col)
|
function Screen:_handle_cursor_goto(row, col)
|
||||||
|
Loading…
Reference in New Issue
Block a user