feat(extui): use winborder for msg window #34859

Problem:  The message window is essentially a regular floating window
          but does not use 'winborder'.
          Still some "scratch" buffer options unset after it was removed
          from its window.
Solution: Do not set the border when opening the window message.
          Forego passing `scratch = true` when opening a buffer,
          set the options manually when necessary.

Co-authored-by: Luuk van Baal <luukvbaal@gmail.com>
This commit is contained in:
Sebastian Lyng Johansen
2025-07-10 02:42:47 +02:00
committed by GitHub
parent 8aed423072
commit 7526fb449d
4 changed files with 50 additions and 30 deletions

View File

@@ -87,14 +87,6 @@ function M.enable(opts)
return true
end)
-- Use MsgArea and hide search highlighting in the cmdline window.
-- TODO: Add new highlight group/namespaces for other windows? It is
-- not clear if MsgArea is wanted in the msg, pager and dialog windows.
api.nvim_set_hl(ext.ns, 'Normal', { link = 'MsgArea' })
api.nvim_set_hl(ext.ns, 'Search', { link = 'MsgArea' })
api.nvim_set_hl(ext.ns, 'CurSearch', { link = 'MsgArea' })
api.nvim_set_hl(ext.ns, 'IncSearch', { link = 'MsgArea' })
-- The visibility and appearance of the cmdline and message window is
-- dependent on some option values. Reconfigure windows when option value
-- has changed and after VimEnter when the user configured value is known.