snosov1 / toc-org

toc-org is an Emacs utility to have an up-to-date table of contents in the org files without exporting (useful primarily for readme files on GitHub)
GNU General Public License v3.0
287 stars 29 forks source link

depth control tag doesn't work #79

Closed spacerainbow000 closed 2 years ago

spacerainbow000 commented 3 years ago

I tried tagging a header like :TOC_8: and still got a TOC of depth 2; I had to change the setting toc-org-max-depth in custom to change the depth. I'm also not seeing where in the code this tag is meant to be processed

snosov1 commented 3 years ago

This is the regexp that accounts for _ and @ separators.

This is where the depth is being assigned to either the value specified in the tag or the value from toc-org-max-depth.

I've also wanted to add a url to a test for that specific functionality, but realized that I have only tests for format of the tag (not testing "depth functionally" really).

Do you still see the problem? If yes, do you care to provide a test that fails ? (and a fix, if possible =) )