You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add basic support for org-indent-mode like behavior
## Details
Request: #134
Adds a new top level configuration for `indent` which is disabled by default.
The effect of enabling it is to mimic org-indent-mode by adding
`per_level` * (level - 1) spaces to the start of each line. This is
accomplished by using the section nodes which nicely contain everything
within a header including nested headers. Since the sections themselves
are nested we don't even do the math for creating the padding we simply
add `per_level` for each line of each section and the fact they are
nested means the paddings stack.
We need to use inline virtual text to accomplish this since that is the
only way to shift text, meaining this only works for neovim >= 0.10.0.
Since virtual_lines are not impacted by inline text we need to manaully
pad them based on the level of the current object.
There are probably many edge cases that look weird or cause all sorts of
alignment problems. I'll work on them as they come up if they're not too
bad to handle, otherwise I will enumerate any non functional
configurations in the README.
0 commit comments