From 4a30d880368c08732fd89657f7a0c3679c00b654 Mon Sep 17 00:00:00 2001 From: Peter Odding Date: Mon, 20 May 2013 01:13:15 +0200 Subject: Document the g:easytags_events option (issue #46) Issue #46 on GitHub: https://github.com/xolox/vim-easytags/issues/46 --- doc/easytags.txt | 43 +++++++++++++++++++++++++++++++------------ 1 file changed, 31 insertions(+), 12 deletions(-) (limited to 'doc') diff --git a/doc/easytags.txt b/doc/easytags.txt index f6edef1..1e134c9 100644 --- a/doc/easytags.txt +++ b/doc/easytags.txt @@ -16,17 +16,18 @@ Contents ~ 3. The |g:easytags_file| option 4. The |g:easytags_dynamic_files| option 5. The |g:easytags_by_filetype| option - 6. The |g:easytags_always_enabled| option - 7. The |g:easytags_on_cursorhold| option - 8. The |g:easytags_updatetime_min| option - 9. The |g:easytags_updatetime_warn| option - 10. The |g:easytags_auto_update| option - 11. The |g:easytags_auto_highlight| option - 12. The |g:easytags_autorecurse| option - 13. The |g:easytags_include_members| option - 14. The |g:easytags_resolve_links| option - 15. The |g:easytags_suppress_ctags_warning| option - 16. The |g:easytags_ignored_syntax_groups| option + 6. The |g:easytags_events| option + 7. The |g:easytags_always_enabled| option + 8. The |g:easytags_on_cursorhold| option + 9. The |g:easytags_updatetime_min| option + 10. The |g:easytags_updatetime_warn| option + 11. The |g:easytags_auto_update| option + 12. The |g:easytags_auto_highlight| option + 13. The |g:easytags_autorecurse| option + 14. The |g:easytags_include_members| option + 15. The |g:easytags_resolve_links| option + 16. The |g:easytags_suppress_ctags_warning| option + 17. The |g:easytags_ignored_syntax_groups| option 5. Customizing the easytags plug-in |customizing-easytags-plug-in| 1. Passing custom command line arguments to Exuberant Ctags 2. Update & highlight tags immediately after save @@ -257,6 +258,24 @@ option. If you already have a global tags file you can create file type specific tags files from the global tags file using the command ':TagsByFileType'. +------------------------------------------------------------------------------- +The *g:easytags_events* option + +This option can be used to customize the events that trigger the automatic +updating and highlighting performed by the easytags plug-in. The |g:easytags_always_enabled| +and |g:easytags_on_cursorhold| options are more user friendly but limited ways +to accomplish the same thing. + +Here's an example: Say you want the easytags plug-in to automatically update & +highlight tags for the current file right after you save the file. You can +accomplish this by adding the following line to your |vimrc| script: +> + :let g:easytags_events = ['BufWritePost'] + +Note that if you set |g:easytags_events| in your |vimrc| script, the values of +the options |g:easytags_always_enabled| and |g:easytags_on_cursorhold| will be +ignored completely. + ------------------------------------------------------------------------------- The *g:easytags_always_enabled* option @@ -453,7 +472,7 @@ If you want the easytags plug-in to automatically update & highlight tags for the current file right after you save the file, you can add the following line to your |vimrc| script: > - :autocmd BufWritePost * call xolox#easytags#autoload('BufWritePost') + :let g:easytags_events = ['BufWritePost'] ------------------------------------------------------------------------------- How to customize the highlighting colors? ~ -- cgit v1.2.3