Fix treesitter + vimtex, fix concealment

This commit is contained in:
Andreas Tsouchlos 2024-03-10 21:09:37 +01:00
parent 5b4ffb2514
commit 0e81707573
2 changed files with 30 additions and 4 deletions

View File

@ -28,8 +28,11 @@ return {
highlight = {
enable = true,
additional_vim_regex_highlighting = false,
disable = {
-- additional_vim_regex_highlighting = false,
-- disable = {
-- "latex"
-- },
additional_vim_regex_highlighting = {
"latex"
}
}

View File

@ -1,7 +1,10 @@
return {
{
"lervag/vimtex",
ft = {"tex", "bib"},
ft = {
"tex",
"bib"
},
config = function()
-- General configuration
@ -24,7 +27,27 @@ return {
-- Concealment
vim.cmd([[set conceallevel=1]])
vim.g.tex_conceal = 'abdmg'
vim.cmd([[
let g:vimtex_syntax_conceal = {
\ 'accents': 1,
\ 'ligatures': 1,
\ 'cites': 1,
\ 'fancy': 1,
\ 'spacing': 0,
\ 'greek': 1,
\ 'math_bounds': 1,
\ 'math_delimiters': 1,
\ 'math_fracs': 1,
\ 'math_super_sub': 0,
\ 'math_symbols': 1,
\ 'sections': 0,
\ 'styles': 0,
\}
let g:vimtex_syntax_custom_cmds = [
\ {'name': 'bm', 'mathmode': 1, 'argstyle': 'bold', 'conceal': 1},
\]
]])
-- Synctex configuration