mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
fix(statuscolumn): foldcolumn buffer is too small (#21761)
Resolve https://github.com/neovim/neovim/issues/21759.
This commit is contained in:
parent
443bbfd59e
commit
0fd59f0121
@ -1426,7 +1426,7 @@ struct statuscol {
|
||||
int sign_attr[SIGN_SHOW_MAX + 1]; ///< attributes used for signs
|
||||
int truncate; ///< truncated width
|
||||
bool draw; ///< draw statuscolumn or not
|
||||
char fold_text[10]; ///< text in fold column (%C)
|
||||
char fold_text[9 * 4 + 1]; ///< text in fold column (%C)
|
||||
char *sign_text[SIGN_SHOW_MAX + 1]; ///< text in sign column (%s)
|
||||
char text[MAXPATHL]; ///< text in status column
|
||||
char *textp; ///< current position in text
|
||||
|
@ -367,4 +367,26 @@ describe('statuscolumn', function()
|
||||
meths.input_mouse('right', 'press', '', 0, 3, 0)
|
||||
eq('0 4 r 7', eval("g:testvar"))
|
||||
end)
|
||||
|
||||
it('fits maximum multibyte foldcolumn #21759', function()
|
||||
command('set stc=%C fdc=9 fillchars=foldsep:𒀀')
|
||||
for _ = 0,8 do command('norm zfjzo') end
|
||||
screen:expect([[
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
--------- ^aaaaa |
|
||||
𒀀𒀀𒀀𒀀𒀀𒀀𒀀𒀀𒀀 aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
aaaaa |
|
||||
|
|
||||
]])
|
||||
end)
|
||||
|
||||
end)
|
||||
|
Loading…
Reference in New Issue
Block a user