From fd2ac767ebb66adcb7ca85955f5fd40704475595 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 1 Mar 2006 22:09:21 +0000 Subject: updated for version 7.0211 --- runtime/doc/pattern.txt | 33 +++++++++++++++++++++++++++++---- 1 file changed, 29 insertions(+), 4 deletions(-) (limited to 'runtime/doc/pattern.txt') diff --git a/runtime/doc/pattern.txt b/runtime/doc/pattern.txt index 2a19909084..11a988ede6 100644 --- a/runtime/doc/pattern.txt +++ b/runtime/doc/pattern.txt @@ -1,4 +1,4 @@ -*pattern.txt* For Vim version 7.0aa. Last change: 2006 Feb 14 +*pattern.txt* For Vim version 7.0aa. Last change: 2006 Mar 01 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1191,14 +1191,23 @@ Finally, these constructs are unique to Perl: < Instead of // any character can be used to mark the start and end of the {pattern}. Watch out for using special characters, such as '"' and '|'. + {group} must exist at the moment this command is executed. - The match overrides the 'hlsearch' highlighting. - 'ignorecase' does not apply, use |/\c| in the pattern to - ignore case. Otherwise case is not ignored. + + The {group} highlighting still applies when a character is + to be highlighted for 'hlsearch'. + Note that highlighting the last used search pattern with 'hlsearch' is used in all windows, while the pattern defined with ":match" only exists in the current window. It is kept when switching to another buffer. + + The |matchparen| plugin uses match highlighting, thus will + disable your ":match" command as soon as you move to a paren. + + 'ignorecase' does not apply, use |/\c| in the pattern to + ignore case. Otherwise case is not ignored. + Another example, which highlights all characters in virtual column 72 and more: > :highlight rightMargin term=bold ctermfg=blue guifg=blue @@ -1213,4 +1222,20 @@ Finally, these constructs are unique to Perl: :mat[ch] none Clear a previously defined match pattern. + +:2mat[ch] {group} /{pattern}/ +:2mat[ch] +:2mat[ch] none +:3mat[ch] {group} /{pattern}/ +:3mat[ch] +:3mat[ch] none + Just like |:match| above, but set a separate match. Thus + there can be three matches active at the same time. The match + with the lowest number has priority if several match at the + same position. + The ":3match" command is used by the |matchparen| plugin. You + are suggested to use ":match" for manual matching and + ":2match" for another plugin. + + vim:tw=78:ts=8:ft=help:norl: -- cgit v1.2.3