mirror of
https://github.com/neovim/neovim
synced 2025-07-15 16:51:49 +00:00
feat(option): custom chars in 'winborder' #33772
Problem: winborder option only supported predefined styles and lacked support for custom border characters. Solution: implement parsing for comma-separated list format that allows specifying 8 individual border characters (topleft, top, topright, right, botright, bottom, botleft, left).
This commit is contained in:
@ -10938,7 +10938,16 @@ describe('float window', function()
|
||||
winid = api.nvim_open_win(buf, false, config)
|
||||
eq('┏', api.nvim_win_get_config(winid).border[1])
|
||||
|
||||
-- it is currently not supported.
|
||||
command([[set winborder=+,-,+,\|,+,-,+,\|]])
|
||||
winid = api.nvim_open_win(buf, false, config)
|
||||
eq('+', api.nvim_win_get_config(winid).border[1])
|
||||
|
||||
command([[set winborder=●,○,●,○,●,○,●,○]])
|
||||
winid = api.nvim_open_win(buf, false, config)
|
||||
eq('●', api.nvim_win_get_config(winid).border[1])
|
||||
|
||||
eq('Vim(set):E474: Invalid argument: winborder=,,', pcall_err(command, 'set winborder=,,'))
|
||||
eq('Vim(set):E474: Invalid argument: winborder=+,-,+,|,+,-,+,', pcall_err(command, [[set winborder=+,-,+,\|,+,-,+,]]))
|
||||
eq('Vim(set):E474: Invalid argument: winborder=custom', pcall_err(command, 'set winborder=custom'))
|
||||
end)
|
||||
end
|
||||
|
Reference in New Issue
Block a user