Skip to content

Commit

Permalink
Merge pull request #20 from alvarosevilla95/main
Browse files Browse the repository at this point in the history
Use nvim_buf_set_extmark to allow 'combine' hl_mode
  • Loading branch information
cmgriffing authored Nov 2, 2021
2 parents f2b266f + bc41c44 commit ebc9b50
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions lua/nvim-biscuits/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,13 @@ nvim_biscuits.decorate_nodes = function(bufnr, lang)
vim.api.nvim_buf_clear_namespace(bufnr,
biscuit_highlight_group,
end_line, end_line + 1)
vim.api.nvim_buf_set_virtual_text(bufnr,
biscuit_highlight_group,
end_line, {
{text, biscuit_highlight_group_name}
}, {})
vim.api.nvim_buf_set_extmark(bufnr, biscuit_highlight_group, end_line, 0, {
virt_text_pos = "eol",
virt_text = {
{text, biscuit_highlight_group_name}
},
hl_mode = "combine"
})
end
end

Expand Down

0 comments on commit ebc9b50

Please sign in to comment.