Search code examples
emacslatexauctex

fold LaTeX document by \section in AucTeX?


I can't seem to find examples of how to fold LaTeX documents by section headings using AucTeX (though I find claims that this is possible and I have not doubt that this is a true statement). Currently -- in the default configuration -- folding the whole buffer seems to just hide the names of the macros and environments but does not fold anything vertically... Any leads? Thanks --

Edit: not sure if this helps, but my TeX-fold-type-list is (env macro math), which is the default value.


Solution

  • AucTeX supports emacs' outline minor mode, which does what you want (hint: bind outline-toggle-children to something or set outline-minor-mode-prefix).