Replies: 4 comments 1 reply
-
I never used this. For example, what do the first 2 blocs you posted? |
Beta Was this translation helpful? Give feedback.
-
if (TRUE)
if (TRUE)
print(FALSE)
for (n in 1:10)
print(n) Without it, the code is "indented" as: if (TRUE)
if (TRUE)
print(FALSE)
for (n in 1:10)
print(n) The and highlighting of I just noted that the |
Beta Was this translation helpful? Give feedback.
-
I update the contents of the
However, the highlighting will only work if :hi @define
:hi @delimiter
:hi @include If they are :hi def link @define Define
:hi def link @delimiter Delimiter
:hi def link @include Include Note: you have to choose color groups that actually work with your |
Beta Was this translation helpful? Give feedback.
-
The background color of code blocks is done by -- Background of headers and code blocks in Quarto documents
{
"lukas-reineke/headlines.nvim",
dependencies = "nvim-treesitter/nvim-treesitter",
config = function ()
require("headlines").setup({
quarto = {
--- Copied from headlines.nvim doc, replacing parse_query with query.parse
query = vim.treesitter.query.parse(
"markdown",
[[
(atx_heading [
(atx_h1_marker)
(atx_h2_marker)
(atx_h3_marker)
(atx_h4_marker)
] @headline)
(thematic_break) @dash
(fenced_code_block) @codeblock
(block_quote_marker) @quote
(block_quote (paragraph (inline (block_continuation) @quote)))
(block_quote (paragraph (block_continuation) @quote))
(block_quote (block_continuation) @quote)
]]
),
treesitter_language = "markdown",
headline_highlights = { "Headline" },
bullet_highlights = {
"@text.title.1.marker.markdown",
"@text.title.2.marker.markdown",
"@text.title.3.marker.markdown",
"@text.title.4.marker.markdown",
},
bullets = { "◉", "○", "✸", "•" },
codeblock_highlight = "CodeBlock",
dash_highlight = "Dash",
dash_string = "-",
quote_highlight = "Quote",
quote_string = "┃",
fat_headlines = true,
fat_headline_upper_string = "▃",
fat_headline_lower_string = "🬂",
},
})
end
}, |
Beta Was this translation helpful? Give feedback.
-
What
~/.config/nvim/after/queries
are you using? We could add a session to the Wiki with suggestions.I'm using the following:
~/.config/nvim/after/queries/r/indents.scm
:~/.config/nvim/after/queries/r/highlights.scm
:~/.config/nvim/after/queries/markdown/highlights.scm
:~/.config/nvim/after/queries/markdown_inline/highlights.scm
:~/.config/nvim/after/queries/python/highlights.scm
:Beta Was this translation helpful? Give feedback.
All reactions