lukas-reineke / headlines.nvim

This plugin adds horizontal highlights for text filetypes, like markdown, orgmode, and neorg.
MIT License
688 stars 28 forks source link

Feature request : dynamic code block highlight area, or some sort of it #83

Open sadtab opened 4 months ago

sadtab commented 4 months ago

I think it will be a nice feature to highlight the code block based on the longest line in the code block, rather than highlight it till the end of pane

image

vs

image

lukas-reineke commented 4 months ago

I agree, but I'm not sure if there is a nice way to do this.

sadtab commented 4 months ago

I saw this plug in earlier today, I couldn't manage to make it work, it seems to be non maintained https://github.com/yaocccc/nvim-hl-mdcodeblock.lua

May be gives you some idea, I hopedhave some Lua knowledge to post a PR