lukas-reineke / headlines.nvim

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

feat: allow fat_headlines to be a function #79

Closed rsforge closed 6 months ago

rsforge commented 6 months ago

While using Neorg toc (Table of Contents) I found the fat_headlines taking up far to much space. However, I really like the way they look outside of the toc buffer. This can now be achieved by adding something like this to your headlines.nvim config:

require('headlines').setup({
    norg = {
        fat_headlines = function()
            -- Return a true if not toc file
        end,
    },
})
lukas-reineke commented 6 months ago

Thanks, but sorry I don't think allowing functions for each option is a good idea. Instead, setup itself should be callable per buffer.

I want to implement this when I have some time.