Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 6. Folding/Outline *vimwiki-folding*
- Vimwiki can fold or outline sections using headers and preformatted blocks.
- Alternatively, one can fold list subitems instead.
- Example for list folding:
- = My current task =
- * [ ] Do stuff 1
- * [ ] Do substuff 1.1
- * [ ] Do substuff 1.2
- * [ ] Do substuff 1.2.1
- * [ ] Do substuff 1.2.2
- * [ ] Do substuff 1.3
- * [ ] Do stuff 2
- * [ ] Do stuff 3
- Hit |zM| :
- = My current task = [8] --------------------------------------~
- Hit |zr| :
- = My current task =~
- * [ ] Do stuff 1 [5] --------------------------------------~
- * [ ] Do stuff 2~
- * [ ] Do stuff 3~
- Hit |zr| one more time:
- = My current task =~
- * [ ] Do stuff 1~
- * [ ] Do substuff 1.1~
- * [ ] Do substuff 1.2 [2] -------------------------------~
- * [ ] Do substuff 1.3~
- * [ ] Do stuff 2~
- * [ ] Do stuff 3~
- NOTE:If you use the default vimwiki syntax, folding on list items will work
- properly only if all of them are indented using current |shiftwidth|.
- For MediaWiki, * or # should be in the first column.
- To turn folding on/off check |g:vimwiki_folding|.
- *g:vimwiki_folding*
- Enable/disable vimwiki's folding (outline) functionality. Folding in vimwiki
- can uses either the 'expr' or the 'syntax' |foldmethod| of Vim.
- Value Description~
- '' Disable folding.
- 'expr' Folding based on expression (folds sections and code blocks).
- 'syntax' Folding based on syntax (folds sections; slower than 'expr').
- 'list' Folding based on expression (folds list subitems; much slower).
- Default: ''
- Limitations:
- - Opening very large files may be slow when folding is enabled.
- - 'list' folding is particularly slow with larger files.
- - 'list' is intended to work with lists nicely indented with 'shiftwidth'.
- - 'syntax' is only available for the default syntax so far.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement