fix(extmarks): missing "spell" and "conceal" in details (#27116)

This commit is contained in:
zeertzjq
2024-01-22 06:25:06 +08:00
committed by GitHub
parent 3f188bc533
commit 215244f749
2 changed files with 46 additions and 12 deletions

View File

@@ -1639,6 +1639,40 @@ describe('API/extmarks', function()
right_gravity = true,
},
}, get_extmark_by_id(ns, marks[3], { details = true }))
set_extmark(ns, marks[4], 0, 0, {
end_col = 1,
conceal = 'a',
spell = true,
})
eq({
0,
0,
{
conceal = 'a',
end_col = 1,
end_right_gravity = false,
end_row = 0,
ns_id = 1,
right_gravity = true,
spell = true,
},
}, get_extmark_by_id(ns, marks[4], { details = true }))
set_extmark(ns, marks[5], 0, 0, {
end_col = 1,
spell = false,
})
eq({
0,
0,
{
end_col = 1,
end_right_gravity = false,
end_row = 0,
ns_id = 1,
right_gravity = true,
spell = false,
},
}, get_extmark_by_id(ns, marks[5], { details = true }))
api.nvim_buf_clear_namespace(0, ns, 0, -1)
-- legacy sign mark includes sign name
command('sign define sign1 text=s1 texthl=Title linehl=LineNR numhl=Normal culhl=CursorLine')