2023-01-09 10:12:06 -07:00
|
|
|
local helpers = require('test.functional.helpers')(after_each)
|
|
|
|
local Screen = require('test.functional.ui.screen')
|
|
|
|
local clear = helpers.clear
|
|
|
|
local command = helpers.command
|
|
|
|
local eq = helpers.eq
|
|
|
|
local eval = helpers.eval
|
2023-01-15 17:24:33 -07:00
|
|
|
local exec_lua = helpers.exec_lua
|
2023-01-18 02:55:03 -07:00
|
|
|
local feed = helpers.feed
|
2023-01-09 10:12:06 -07:00
|
|
|
local meths = helpers.meths
|
|
|
|
local pcall_err = helpers.pcall_err
|
|
|
|
|
2023-04-24 20:05:04 -07:00
|
|
|
local mousemodels = { "extend", "popup", "popup_setpos" }
|
|
|
|
|
2023-01-09 10:12:06 -07:00
|
|
|
describe('statuscolumn', function()
|
|
|
|
local screen
|
|
|
|
before_each(function()
|
|
|
|
clear('--cmd', 'set number nuw=1 | call setline(1, repeat(["aaaaa"], 16)) | norm GM')
|
|
|
|
screen = Screen.new()
|
|
|
|
screen:attach()
|
2023-04-17 18:20:18 -07:00
|
|
|
exec_lua('ns = vim.api.nvim_create_namespace("")')
|
2023-01-09 10:12:06 -07:00
|
|
|
end)
|
|
|
|
|
2023-01-15 17:24:33 -07:00
|
|
|
it("fails with invalid 'statuscolumn'", function()
|
|
|
|
command([[set stc=%{v:relnum?v:relnum:(v:lnum==5?invalid:v:lnum)}\ ]])
|
2023-01-09 10:12:06 -07:00
|
|
|
screen:expect([[
|
|
|
|
4 aaaaa |
|
|
|
|
3 aaaaa |
|
|
|
|
2 aaaaa |
|
|
|
|
1 aaaaa |
|
|
|
|
8 ^aaaaa |
|
|
|
|
1 aaaaa |
|
|
|
|
2 aaaaa |
|
|
|
|
3 aaaaa |
|
|
|
|
4 aaaaa |
|
|
|
|
5 aaaaa |
|
|
|
|
6 aaaaa |
|
|
|
|
7 aaaaa |
|
|
|
|
8 aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('norm 5G')
|
|
|
|
eq('Vim(redraw):E121: Undefined variable: invalid', pcall_err(command, 'redraw!'))
|
|
|
|
eq('', eval('&statuscolumn'))
|
|
|
|
end)
|
|
|
|
|
2023-01-15 17:24:33 -07:00
|
|
|
it("widens with irregular 'statuscolumn' width", function()
|
|
|
|
command([[set stc=%{v:relnum?v:relnum:(v:lnum==5?'bbbbb':v:lnum)}]])
|
2023-01-09 10:12:06 -07:00
|
|
|
command('norm 5G | redraw!')
|
|
|
|
screen:expect([[
|
|
|
|
1 aaaaa |
|
|
|
|
bbbbba^eaaa |
|
|
|
|
1 aaaaa |
|
|
|
|
2 aaaaa |
|
|
|
|
3 aaaaa |
|
|
|
|
4 aaaaa |
|
|
|
|
5 aaaaa |
|
|
|
|
6 aaaaa |
|
|
|
|
7 aaaaa |
|
|
|
|
8 aaaaa |
|
|
|
|
9 aaaaa |
|
|
|
|
10 aaaaa |
|
|
|
|
11 aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
end)
|
|
|
|
|
2023-01-19 16:47:02 -07:00
|
|
|
it("works with 'number' and 'relativenumber'", function()
|
2023-01-09 10:12:06 -07:00
|
|
|
command([[set stc=%{&nu?v:lnum:''}%=%{&rnu?'\ '.v:relnum:''}│]])
|
|
|
|
screen:expect([[
|
|
|
|
4 │aaaaa |
|
|
|
|
5 │aaaaa |
|
|
|
|
6 │aaaaa |
|
|
|
|
7 │aaaaa |
|
|
|
|
8 │^aaaaa |
|
|
|
|
9 │aaaaa |
|
|
|
|
10│aaaaa |
|
|
|
|
11│aaaaa |
|
|
|
|
12│aaaaa |
|
|
|
|
13│aaaaa |
|
|
|
|
14│aaaaa |
|
|
|
|
15│aaaaa |
|
|
|
|
16│aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
2023-01-13 02:41:19 -07:00
|
|
|
command([[set stc=%l%=%{&rnu?'\ ':''}%r│]])
|
|
|
|
screen:expect_unchanged()
|
|
|
|
command([[set stc=%{&nu?v:lnum:''}%=%{&rnu?'\ '.v:relnum:''}│]])
|
2023-01-09 10:12:06 -07:00
|
|
|
command('set relativenumber')
|
|
|
|
screen:expect([[
|
|
|
|
4 4│aaaaa |
|
|
|
|
5 3│aaaaa |
|
|
|
|
6 2│aaaaa |
|
|
|
|
7 1│aaaaa |
|
|
|
|
8 0│^aaaaa |
|
|
|
|
9 1│aaaaa |
|
|
|
|
10 2│aaaaa |
|
|
|
|
11 3│aaaaa |
|
|
|
|
12 4│aaaaa |
|
|
|
|
13 5│aaaaa |
|
|
|
|
14 6│aaaaa |
|
|
|
|
15 7│aaaaa |
|
|
|
|
16 8│aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
2023-01-13 02:41:19 -07:00
|
|
|
command([[set stc=%l%=%{&rnu?'\ ':''}%r│]])
|
|
|
|
screen:expect_unchanged()
|
|
|
|
command([[set stc=%{&nu?v:lnum:''}%=%{&rnu?'\ '.v:relnum:''}│]])
|
2023-01-09 10:12:06 -07:00
|
|
|
command('norm 12GH')
|
|
|
|
screen:expect([[
|
|
|
|
4 0│^aaaaa |
|
|
|
|
5 1│aaaaa |
|
|
|
|
6 2│aaaaa |
|
|
|
|
7 3│aaaaa |
|
|
|
|
8 4│aaaaa |
|
|
|
|
9 5│aaaaa |
|
|
|
|
10 6│aaaaa |
|
|
|
|
11 7│aaaaa |
|
|
|
|
12 8│aaaaa |
|
|
|
|
13 9│aaaaa |
|
|
|
|
14 10│aaaaa |
|
|
|
|
15 11│aaaaa |
|
|
|
|
16 12│aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
2023-01-13 02:41:19 -07:00
|
|
|
command([[set stc=%l%=%{&rnu?'\ ':''}%r│]])
|
|
|
|
screen:expect_unchanged()
|
|
|
|
command([[set stc=%{&nu?v:lnum:''}%=%{&rnu?'\ '.v:relnum:''}│]])
|
2023-01-09 10:12:06 -07:00
|
|
|
end)
|
|
|
|
|
2023-01-15 17:24:33 -07:00
|
|
|
it("works with highlighted 'statuscolumn'", function()
|
2023-01-09 10:12:06 -07:00
|
|
|
command([[set stc=%#NonText#%{&nu?v:lnum:''}]] ..
|
|
|
|
[[%=%{&rnu&&(v:lnum%2)?'\ '.v:relnum:''}]] ..
|
|
|
|
[[%#LineNr#%{&rnu&&!(v:lnum%2)?'\ '.v:relnum:''}│]])
|
|
|
|
screen:set_default_attr_ids({
|
|
|
|
[0] = {bold = true, foreground = Screen.colors.Blue},
|
|
|
|
[1] = {foreground = Screen.colors.Brown},
|
|
|
|
})
|
|
|
|
screen:expect([[
|
|
|
|
{0:4 }{1:│}aaaaa |
|
|
|
|
{0:5 }{1:│}aaaaa |
|
|
|
|
{0:6 }{1:│}aaaaa |
|
|
|
|
{0:7 }{1:│}aaaaa |
|
|
|
|
{0:8 }{1:│}^aaaaa |
|
|
|
|
{0:9 }{1:│}aaaaa |
|
|
|
|
{0:10}{1:│}aaaaa |
|
|
|
|
{0:11}{1:│}aaaaa |
|
|
|
|
{0:12}{1:│}aaaaa |
|
|
|
|
{0:13}{1:│}aaaaa |
|
|
|
|
{0:14}{1:│}aaaaa |
|
|
|
|
{0:15}{1:│}aaaaa |
|
|
|
|
{0:16}{1:│}aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('set relativenumber')
|
|
|
|
screen:expect([[
|
|
|
|
{0:4 }{1: 4│}aaaaa |
|
|
|
|
{0:5 3}{1:│}aaaaa |
|
|
|
|
{0:6 }{1: 2│}aaaaa |
|
|
|
|
{0:7 1}{1:│}aaaaa |
|
|
|
|
{0:8 }{1: 0│}^aaaaa |
|
|
|
|
{0:9 1}{1:│}aaaaa |
|
|
|
|
{0:10}{1: 2│}aaaaa |
|
|
|
|
{0:11 3}{1:│}aaaaa |
|
|
|
|
{0:12}{1: 4│}aaaaa |
|
|
|
|
{0:13 5}{1:│}aaaaa |
|
|
|
|
{0:14}{1: 6│}aaaaa |
|
|
|
|
{0:15 7}{1:│}aaaaa |
|
|
|
|
{0:16}{1: 8│}aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('set nonumber')
|
|
|
|
screen:expect([[
|
|
|
|
{1:4│}aaaaa |
|
|
|
|
{0:3}{1:│}aaaaa |
|
|
|
|
{1:2│}aaaaa |
|
|
|
|
{0:1}{1:│}aaaaa |
|
|
|
|
{1:0│}^aaaaa |
|
|
|
|
{0:1}{1:│}aaaaa |
|
|
|
|
{1:2│}aaaaa |
|
|
|
|
{0:3}{1:│}aaaaa |
|
|
|
|
{1:4│}aaaaa |
|
|
|
|
{0:5}{1:│}aaaaa |
|
|
|
|
{1:6│}aaaaa |
|
|
|
|
{0:7}{1:│}aaaaa |
|
|
|
|
{1:8│}aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
end)
|
|
|
|
|
|
|
|
it('works with wrapped lines, signs and folds', function()
|
2023-01-15 17:24:33 -07:00
|
|
|
command([[set stc=%C%s%=%{v:virtnum?'':v:lnum}│\ ]])
|
2023-01-09 10:12:06 -07:00
|
|
|
command("call setline(1,repeat([repeat('aaaaa',10)],16))")
|
|
|
|
screen:set_default_attr_ids({
|
|
|
|
[0] = {bold = true, foreground = Screen.colors.Blue},
|
|
|
|
[1] = {foreground = Screen.colors.Brown},
|
|
|
|
[2] = {foreground = Screen.colors.DarkBlue, background = Screen.colors.WebGrey},
|
|
|
|
[3] = {foreground = Screen.colors.DarkBlue, background = Screen.colors.LightGrey},
|
2023-01-10 18:52:11 -07:00
|
|
|
[4] = {bold = true, foreground = Screen.colors.Brown},
|
|
|
|
[5] = {background = Screen.colors.Grey90},
|
2023-01-09 10:12:06 -07:00
|
|
|
})
|
|
|
|
screen:expect([[
|
|
|
|
{1: 4│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1: 5│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1: 6│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1: 7│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1: 8│ }^aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1: 9│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1: │ }a |
|
|
|
|
{1:10│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa{0:@@@}|
|
|
|
|
|
|
|
|
|
]])
|
2023-01-16 17:02:33 -07:00
|
|
|
command("set stc=%C%s%=%l│\\ ")
|
|
|
|
screen:expect_unchanged()
|
2023-01-09 10:12:06 -07:00
|
|
|
command('set signcolumn=auto:2 foldcolumn=auto')
|
|
|
|
command('sign define piet1 text=>> texthl=LineNr')
|
|
|
|
command('sign define piet2 text=>! texthl=NonText')
|
|
|
|
command('sign place 1 line=4 name=piet1 buffer=1')
|
|
|
|
command('sign place 2 line=5 name=piet2 buffer=1')
|
|
|
|
command('sign place 3 line=6 name=piet1 buffer=1')
|
|
|
|
command('sign place 4 line=6 name=piet2 buffer=1')
|
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{1:>>}{2: }{1: 4│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │ }aaaaa |
|
|
|
|
{0:>!}{2: }{1: 5│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │ }aaaaa |
|
2023-01-09 10:12:06 -07:00
|
|
|
{1:>>}{0:>!}{1: 6│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: │ }aaaaa |
|
|
|
|
{2: }{1: 7│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │ }aaaaa |
|
|
|
|
{2: }{1: 8│ }^aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │ }aaaaa |
|
|
|
|
{2: }{1: 9│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │ }aaaaa |
|
|
|
|
{2: }{1:10│ }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa{0:@@@}|
|
2023-01-09 10:12:06 -07:00
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('norm zf$')
|
|
|
|
-- Check that alignment works properly with signs after %=
|
2023-01-15 17:24:33 -07:00
|
|
|
command([[set stc=%C%=%{v:virtnum?'':v:lnum}│%s\ ]])
|
2023-01-09 10:12:06 -07:00
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 5│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
2023-01-09 10:12:06 -07:00
|
|
|
{2: }{1: 6│>>}{0:>!}{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 7│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2:+}{1: 8│}{2: }{1: }{3:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 9│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1:10│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('set cursorline')
|
|
|
|
screen:expect([[
|
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 5│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 6│>>}{0:>!}{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 7│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2:+}{4: 8│}{2: }{4: }{5:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 9│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1:10│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
2023-01-09 10:12:06 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-01-09 20:30:45 -07:00
|
|
|
-- v:lnum is the same value on wrapped lines
|
2023-01-15 17:24:33 -07:00
|
|
|
command([[set stc=%C%=%{v:lnum}│%s\ ]])
|
2023-01-09 20:30:45 -07:00
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 4│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 5│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 5│}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
{2: }{1: 6│>>}{0:>!}{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 6│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 7│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 7│}{2: }{1: }aaaaaa |
|
|
|
|
{2:+}{4: 8│}{2: }{4: }{5:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 9│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 9│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1:10│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1:10│}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
|
|
|
|
|
]])
|
|
|
|
-- v:relnum is the same value on wrapped lines
|
2023-01-15 17:24:33 -07:00
|
|
|
command([[set stc=%C%=\ %{v:relnum}│%s\ ]])
|
2023-01-09 20:30:45 -07:00
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 4│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 3│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 3│}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
{2: }{1: 2│>>}{0:>!}{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 2│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaa |
|
|
|
|
{2:+}{4: 0│}{2: }{4: }{5:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 2│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: 2│}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-01-12 02:40:53 -07:00
|
|
|
command([[set stc=%C%=\ %{v:virtnum?'':v:relnum}│%s\ ]])
|
2023-01-09 20:30:45 -07:00
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 3│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
{2: }{1: 2│>>}{0:>!}{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2:+}{4: 0│}{2: }{4: }{5:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
|
|
|
{2: }{1: 2│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaa |
|
2023-01-09 20:30:45 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-01-10 06:18:12 -07:00
|
|
|
-- Up to 9 signs in a line
|
|
|
|
command('set signcolumn=auto:9 foldcolumn=auto')
|
|
|
|
command('sign place 5 line=6 name=piet1 buffer=1')
|
|
|
|
command('sign place 6 line=6 name=piet2 buffer=1')
|
|
|
|
command('sign place 7 line=6 name=piet1 buffer=1')
|
|
|
|
command('sign place 8 line=6 name=piet2 buffer=1')
|
|
|
|
command('sign place 9 line=6 name=piet1 buffer=1')
|
|
|
|
command('sign place 10 line=6 name=piet2 buffer=1')
|
|
|
|
command('sign place 11 line=6 name=piet1 buffer=1')
|
|
|
|
screen:expect([[
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: 4│>>}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
|
|
|
{2: }{1: 3│}{0:>!}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
2023-01-10 06:18:12 -07:00
|
|
|
{2: }{1: 2│>>}{0:>!}{1:>>}{0:>!}{1:>>}{0:>!}{1:>>}{0:>!}{1:>> }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
2023-01-10 18:52:11 -07:00
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
|
|
|
{2:+}{4: 0│}{2: }{4: }{5:^+-- 1 line: aaaaaaaaaaaaaaaaa}|
|
|
|
|
{2: }{1: 1│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
|
|
|
{2: }{1: 2│}{2: }{1: }aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{2: }{1: │}{2: }{1: }aaaaaaaaaaaaaaaaaaaa |
|
2023-01-10 06:18:12 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-01-12 02:40:53 -07:00
|
|
|
-- Status column is re-evaluated for virt_lines, buffer line, and wrapped line
|
2023-01-15 17:24:33 -07:00
|
|
|
exec_lua([[
|
2023-01-12 02:40:53 -07:00
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 5, 0, {
|
2023-01-15 17:24:33 -07:00
|
|
|
virt_lines_above = true, virt_lines = {{{"virt_line above", ""}}} })
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 4, 0, { virt_lines = {{{"virt_line", ""}}} })
|
2023-01-12 02:40:53 -07:00
|
|
|
]])
|
|
|
|
command('set foldcolumn=0 signcolumn=no')
|
|
|
|
command([[set stc=%{v:virtnum<0?'virtual':(!v:virtnum?'buffer':'wrapped')}%=%{'\ '.v:virtnum.'\ '.v:lnum}]])
|
|
|
|
screen:expect([[
|
|
|
|
{1:buffer 0 4}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 4}aaaaaaaa |
|
|
|
|
{1:buffer 0 5}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 5}aaaaaaaa |
|
2023-01-15 17:24:33 -07:00
|
|
|
{1:virtual-2 5}virt_line |
|
|
|
|
{1:virtual-2 5}virt_line above |
|
2023-01-12 02:40:53 -07:00
|
|
|
{1:buffer 0 6}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 6}aaaaaaaa |
|
|
|
|
{1:buffer 0 7}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 7}aaaaaaaa |
|
|
|
|
{4:buffer 0 8}{5:^+-- 1 line: aaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
2023-01-15 17:24:33 -07:00
|
|
|
{1:buffer 0 9}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 9}aaaaaaaa |
|
2023-01-12 02:40:53 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-03-03 21:23:04 -07:00
|
|
|
-- Also test virt_lines at the end of buffer
|
|
|
|
exec_lua([[
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 15, 0, { virt_lines = {{{"END", ""}}} })
|
|
|
|
]])
|
|
|
|
feed('Gzz')
|
|
|
|
screen:expect([[
|
|
|
|
{1:buffer 0 13}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 13}aaaaaaaaa |
|
|
|
|
{1:buffer 0 14}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 14}aaaaaaaaa |
|
|
|
|
{1:buffer 0 15}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
{1:wrapped 1 15}aaaaaaaaa |
|
|
|
|
{4:buffer 0 16}{5:^aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{4:wrapped 1 16}{5:aaaaaaaaa }|
|
|
|
|
{1:virtual-1 16}END |
|
|
|
|
{0:~ }|
|
|
|
|
{0:~ }|
|
|
|
|
{0:~ }|
|
|
|
|
{0:~ }|
|
|
|
|
|
|
|
|
|
]])
|
2023-04-09 17:39:27 -07:00
|
|
|
-- Also test virt_lines when 'cpoptions' includes "n"
|
|
|
|
exec_lua([[
|
|
|
|
vim.opt.cpoptions:append("n")
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 14, 0, { virt_lines = {{{"virt_line1", ""}}} })
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 14, 0, { virt_lines = {{{"virt_line2", ""}}} })
|
|
|
|
]])
|
|
|
|
screen:expect([[
|
|
|
|
{1:buffer 0 13}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
aaaaaaaaa |
|
|
|
|
{1:buffer 0 14}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
aaaaaaaaa |
|
|
|
|
{1:buffer 0 15}aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|
|
|
|
|
aaaaaaaaa |
|
|
|
|
{1:virtual-2 15}virt_line1 |
|
|
|
|
{1:virtual-2 15}virt_line2 |
|
|
|
|
{1:buffer 0 16}{5:^aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}|
|
|
|
|
{5:aaaaaaaaa }|
|
|
|
|
{1:virtual-1 16}END |
|
|
|
|
{0:~ }|
|
|
|
|
{0:~ }|
|
|
|
|
|
|
|
|
|
]])
|
2023-01-09 10:12:06 -07:00
|
|
|
end)
|
|
|
|
|
2023-04-24 20:05:04 -07:00
|
|
|
for _, model in ipairs(mousemodels) do
|
|
|
|
it("works with 'statuscolumn' clicks with mousemodel=" .. model, function()
|
|
|
|
command('set mousemodel=' .. model)
|
|
|
|
command([[
|
|
|
|
function! MyClickFunc(minwid, clicks, button, mods)
|
|
|
|
let g:testvar = printf("%d %d %s %d", a:minwid, a:clicks, a:button, getmousepos().line)
|
|
|
|
if a:mods !=# ' '
|
|
|
|
let g:testvar ..= '(' .. a:mods .. ')'
|
|
|
|
endif
|
|
|
|
endfunction
|
|
|
|
set stc=%0@MyClickFunc@%=%l%T
|
|
|
|
]])
|
|
|
|
meths.input_mouse('left', 'press', '', 0, 0, 0)
|
|
|
|
eq('0 1 l 4', eval("g:testvar"))
|
|
|
|
meths.input_mouse('left', 'press', '', 0, 0, 0)
|
|
|
|
eq('0 2 l 4', eval("g:testvar"))
|
|
|
|
meths.input_mouse('left', 'press', '', 0, 0, 0)
|
|
|
|
eq('0 3 l 4', eval("g:testvar"))
|
|
|
|
meths.input_mouse('left', 'press', '', 0, 0, 0)
|
|
|
|
eq('0 4 l 4', eval("g:testvar"))
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 3, 0)
|
|
|
|
eq('0 1 r 7', eval("g:testvar"))
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 3, 0)
|
|
|
|
eq('0 2 r 7', eval("g:testvar"))
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 3, 0)
|
|
|
|
eq('0 3 r 7', eval("g:testvar"))
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 3, 0)
|
|
|
|
eq('0 4 r 7', eval("g:testvar"))
|
|
|
|
command('set laststatus=2 winbar=%f')
|
|
|
|
command('let g:testvar=""')
|
|
|
|
-- Check that winbar click doesn't register as statuscolumn click
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 0, 0)
|
|
|
|
eq('', eval("g:testvar"))
|
|
|
|
-- Check that statusline click doesn't register as statuscolumn click
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 12, 0)
|
|
|
|
eq('', eval("g:testvar"))
|
|
|
|
-- Check that cmdline click doesn't register as statuscolumn click
|
|
|
|
meths.input_mouse('right', 'press', '', 0, 13, 0)
|
|
|
|
eq('', eval("g:testvar"))
|
|
|
|
end)
|
|
|
|
end
|
2023-01-12 08:04:43 -07:00
|
|
|
|
2023-01-18 02:55:03 -07:00
|
|
|
it('click labels do not leak memory', function()
|
|
|
|
command([[
|
|
|
|
set laststatus=2
|
|
|
|
setlocal statuscolumn=%0@MyClickFunc@abcd%T
|
|
|
|
4vsplit
|
|
|
|
setlocal statusline=abcd
|
|
|
|
redrawstatus
|
|
|
|
setlocal statusline=
|
|
|
|
only
|
|
|
|
redraw
|
|
|
|
]])
|
|
|
|
end)
|
|
|
|
|
2023-01-15 17:24:33 -07:00
|
|
|
it('works with foldcolumn', function()
|
|
|
|
-- Fits maximum multibyte foldcolumn #21759
|
|
|
|
command([[set stc=%C%=%l\ fdc=9 fillchars=foldsep:𒀀]])
|
2023-01-12 08:04:43 -07:00
|
|
|
for _ = 0,8 do command('norm zfjzo') end
|
2023-01-15 17:24:33 -07:00
|
|
|
-- 'statuscolumn' is not drawn for `virt_lines_leftcol` lines
|
|
|
|
exec_lua([[
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 6, 0, {
|
|
|
|
virt_lines_leftcol = true, virt_lines = {{{"virt", ""}}} })
|
|
|
|
vim.api.nvim_buf_set_extmark(0, ns, 7, 0, {
|
|
|
|
virt_lines_leftcol = true, virt_lines = {{{"virt", ""}}} })
|
|
|
|
]])
|
2023-01-12 08:04:43 -07:00
|
|
|
screen:expect([[
|
2023-01-15 17:24:33 -07:00
|
|
|
4 aaaaa |
|
|
|
|
5 aaaaa |
|
|
|
|
6 aaaaa |
|
|
|
|
7 aaaaa |
|
|
|
|
virt |
|
|
|
|
--------- 8 ^aaaaa |
|
|
|
|
virt |
|
|
|
|
𒀀𒀀𒀀𒀀𒀀𒀀𒀀𒀀𒀀 9 aaaaa |
|
|
|
|
10 aaaaa |
|
|
|
|
11 aaaaa |
|
|
|
|
12 aaaaa |
|
|
|
|
13 aaaaa |
|
|
|
|
14 aaaaa |
|
2023-01-12 08:04:43 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-01-30 16:52:34 -07:00
|
|
|
command('set stc=') -- also for the default fold column
|
2023-01-15 17:24:33 -07:00
|
|
|
screen:expect_unchanged()
|
2023-02-02 02:35:51 -07:00
|
|
|
-- 'statuscolumn' is not too wide with custom (bogus) fold column
|
|
|
|
command([[set stc=%{foldlevel(v:lnum)>0?repeat('-',foldlevel(v:lnum)):''}%=%l\ ]])
|
|
|
|
feed('Gd10Ggg<C-l>')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 aaaaa |
|
|
|
|
3 aaaaa |
|
|
|
|
4 aaaaa |
|
|
|
|
5 aaaaa |
|
|
|
|
6 aaaaa |
|
|
|
|
7 aaaaa |
|
|
|
|
virt |
|
|
|
|
---------8 aaaaa |
|
|
|
|
virt |
|
|
|
|
---------9 aaaaa |
|
|
|
|
~ |
|
|
|
|
~ |
|
|
|
|
|
|
|
|
|
]])
|
2023-01-12 08:04:43 -07:00
|
|
|
end)
|
2023-02-27 19:19:58 -07:00
|
|
|
|
|
|
|
it('works with cmdwin', function()
|
|
|
|
feed(':set stc=%l<CR>q:k$')
|
|
|
|
screen:expect([[
|
|
|
|
7 aaaaa |
|
|
|
|
8 aaaaa |
|
|
|
|
9 aaaaa |
|
|
|
|
10aaaaa |
|
|
|
|
[No Name] [+] |
|
|
|
|
:1set stc=%^l |
|
|
|
|
:2 |
|
|
|
|
~ |
|
|
|
|
~ |
|
|
|
|
~ |
|
|
|
|
~ |
|
|
|
|
~ |
|
|
|
|
[Command Line] |
|
|
|
|
: |
|
|
|
|
]])
|
|
|
|
end)
|
2023-03-06 17:45:08 -07:00
|
|
|
|
|
|
|
it("has correct width when toggling '(relative)number'", function()
|
|
|
|
screen:try_resize(screen._width, 6)
|
|
|
|
command('call setline(1, repeat(["aaaaa"], 100))')
|
|
|
|
command('set relativenumber')
|
|
|
|
command([[set stc=%{!&nu&&!&rnu?'':&rnu?v:relnum?v:relnum:&nu?v:lnum:'0':v:lnum}]])
|
|
|
|
screen:expect([[
|
|
|
|
1 aaaaa |
|
|
|
|
8 ^aaaaa |
|
|
|
|
1 aaaaa |
|
|
|
|
2 aaaaa |
|
|
|
|
3 aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
-- width correctly estimated with "w_nrwidth_line_count" when setting 'stc'
|
|
|
|
command([[set stc=%{!&nu&&!&rnu?'':&rnu?v:relnum?v:relnum:&nu?v:lnum:'0':v:lnum}]])
|
|
|
|
screen:expect_unchanged()
|
|
|
|
-- zero width when disabling 'number'
|
|
|
|
command('set norelativenumber nonumber')
|
|
|
|
screen:expect([[
|
|
|
|
aaaaa |
|
|
|
|
^aaaaa |
|
|
|
|
aaaaa |
|
|
|
|
aaaaa |
|
|
|
|
aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
-- width correctly estimated with "w_nrwidth_line_count" when setting 'nu'
|
|
|
|
command('set number')
|
|
|
|
screen:expect([[
|
|
|
|
7 aaaaa |
|
|
|
|
8 ^aaaaa |
|
|
|
|
9 aaaaa |
|
|
|
|
10 aaaaa |
|
|
|
|
11 aaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
end)
|
2023-03-18 04:44:44 -07:00
|
|
|
|
|
|
|
it("has correct width with custom sign column when (un)placing signs", function()
|
2023-04-17 18:20:18 -07:00
|
|
|
screen:try_resize(screen._width, 3)
|
2023-03-18 04:44:44 -07:00
|
|
|
exec_lua([[
|
|
|
|
vim.cmd.norm('gg')
|
|
|
|
vim.o.signcolumn = 'no'
|
|
|
|
vim.fn.sign_define('sign', { text = 'ss' })
|
|
|
|
_G.StatusCol = function()
|
|
|
|
local s = vim.fn.sign_getplaced(1)[1].signs
|
2023-04-17 18:20:18 -07:00
|
|
|
local es = vim.api.nvim_buf_get_extmarks(0, ns, 0, -1, {type = "sign"})
|
2023-03-18 04:44:44 -07:00
|
|
|
local sign = ''
|
2023-04-17 18:20:18 -07:00
|
|
|
local signs = #s + #es
|
|
|
|
if signs > 0 then
|
|
|
|
sign = (vim.v.lnum == 2 and 'ss' or ' '):rep(signs)
|
2023-03-18 04:44:44 -07:00
|
|
|
end
|
|
|
|
return vim.v.lnum .. '%=' .. sign
|
|
|
|
end
|
|
|
|
vim.o.statuscolumn = "%!v:lua.StatusCol()"
|
|
|
|
]])
|
2023-04-17 18:20:18 -07:00
|
|
|
command('sign place 1 line=2 name=sign')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 ssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('sign place 2 line=2 name=sign')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 ssssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('sign unplace 2')
|
2023-03-18 04:44:44 -07:00
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
2023-04-17 18:20:18 -07:00
|
|
|
2 ssaaaaa |
|
2023-03-18 04:44:44 -07:00
|
|
|
|
|
|
|
|
]])
|
|
|
|
command('sign unplace 1')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 aaaaa |
|
2023-04-17 18:20:18 -07:00
|
|
|
|
|
|
|
|
]])
|
|
|
|
-- Also for extmark signs
|
|
|
|
exec_lua('id1 = vim.api.nvim_buf_set_extmark(0, ns, 1, 0, {sign_text = "ss"})')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 ssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
exec_lua('id2 = vim.api.nvim_buf_set_extmark(0, ns, 1, 0, {sign_text = "ss"})')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 ssssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
exec_lua("vim.api.nvim_buf_del_extmark(0, ns, id1)")
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 ssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
|
|
|
exec_lua("vim.api.nvim_buf_del_extmark(0, ns, id2)")
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa |
|
|
|
|
2 aaaaa |
|
2023-03-18 04:44:44 -07:00
|
|
|
|
|
|
|
|
]])
|
2023-04-18 15:19:26 -07:00
|
|
|
-- In all windows
|
|
|
|
command('wincmd v | set ls=0')
|
|
|
|
command('sign place 1 line=2 name=sign')
|
|
|
|
screen:expect([[
|
|
|
|
1 ^aaaaa │1 aaaaa |
|
|
|
|
2 ssaaaaa │2 ssaaaaa |
|
|
|
|
|
|
|
|
|
]])
|
2023-03-18 04:44:44 -07:00
|
|
|
end)
|
2023-04-12 08:40:58 -07:00
|
|
|
|
|
|
|
it("is only evaluated twice, once to estimate and once to draw", function()
|
|
|
|
command([[
|
|
|
|
let g:stcnr = 0
|
|
|
|
func! Stc()
|
|
|
|
let g:stcnr += 1
|
|
|
|
return '12345'
|
|
|
|
endfunc
|
|
|
|
set stc=%!Stc()
|
|
|
|
norm ggdG
|
|
|
|
]])
|
|
|
|
eq(2, eval('g:stcnr'))
|
|
|
|
end)
|
2023-01-09 10:12:06 -07:00
|
|
|
end)
|