html-fold provides support for hiding and unhiding HTML/XML elements.
html-fold is a minor mode, so that you can use it with some HTML/XML editing major mode, ex. YaHTML, nxml-mode and psgml-mode.
- Put html-fold.el into your load-path
- Byte-compile it, if you would like
- Put following code into your .emacs
(autoload 'html-fold-mode "html-fold" "Minor mode for hiding and revealing elements." t)
- Initialize buffer with
Folding/Unfolding commands list
C-c C-o C-b/
C-c C-o bfolding/unfolding buffer
C-c C-o C-r/
C-c C-o rfolding/unfolding region
C-c C-o C-p/
C-c C-o pfolding/unfolding paragraph
C-c C-o C-ofolding and unfolding case by case
C-c C-o C-efolding block elements
C-c C-o C-mfolding inline elements
You can skip
M-x html-fold-buffer with
This is an example for add-hook for html-mode.
(add-hook 'html-mode-hook 'html-fold-mode)
html-fold is depeloped based on
tex-fold.el in AUCTeX, written by