summaryrefslogtreecommitdiffstats
path: root/runtime/doc/map.txt
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc/map.txt')
-rw-r--r--runtime/doc/map.txt9
1 files changed, 6 insertions, 3 deletions
diff --git a/runtime/doc/map.txt b/runtime/doc/map.txt
index d6dbd5032f..64d0ea1e3e 100644
--- a/runtime/doc/map.txt
+++ b/runtime/doc/map.txt
@@ -371,8 +371,9 @@ job running in the terminal. See |terminal-typing|.
*omap-info*
Operator-pending mappings can be used to define a movement command that can be
-used with any operator. Simple example: ":omap { w" makes "y{" work like "yw"
-and "d{" like "dw".
+used with any operator. Simple example: >
+ :omap { w
+makes "y{" work like "yw" and "d{" like "dw".
To ignore the starting cursor position and select different text, you can have
the omap start Visual mode to select the text to be operated upon. Example
@@ -383,9 +384,11 @@ Normal mode commands find the first '(' character and select the first word
before it. That usually is the function name.
To enter a mapping for Normal and Visual mode, but not Operator-pending mode,
-first define it for all three modes, then unmap it for Operator-pending mode:
+first define it for all three modes, then unmap it for
+Operator-pending mode: >
:map xx something-difficult
:ounmap xx
+
Likewise for a mapping for Visual and Operator-pending mode or Normal and
Operator-pending mode.