mirror of
https://github.com/neovim/neovim.git
synced 2026-04-20 14:25:32 +00:00
fix(extui): cmdline visibility, cmdheight cursor position (#33774)
Problem: The cmdline popupmenu is hidden behind extui windows.
'showmode' message is drawn over the cmdline.
Changing the 'cmdheight' to accommodate space for the text in
the cmdline may change the current cursor position.
Solution: Ensure kZIndexMessages < zindex < kZIndexCmdlinePopupMenu.
Clear the 'showmode' message when the cmdline level is negative.
Temporarily set 'splitkeep' = "screen" when changing the 'cmdheight'.
This commit is contained in:
@@ -331,7 +331,7 @@ function M.msg_clear() end
|
||||
---
|
||||
---@param content MsgContent
|
||||
function M.msg_showmode(content)
|
||||
M.virt.last[M.virt.idx.mode] = content
|
||||
M.virt.last[M.virt.idx.mode] = ext.cmd.level < 0 and content or {}
|
||||
M.virt.last[M.virt.idx.search] = {}
|
||||
set_virttext('last')
|
||||
end
|
||||
@@ -386,7 +386,6 @@ function M.set_pos(type)
|
||||
height = height,
|
||||
row = win == ext.wins[ext.tab].box and 0 or 1,
|
||||
col = 10000,
|
||||
zindex = type == 'more' and 299 or nil,
|
||||
})
|
||||
if type == 'box' then
|
||||
-- Ensure last line is visible and first line is at top of window.
|
||||
|
||||
Reference in New Issue
Block a user