summaryrefslogtreecommitdiff
path: root/runtime/doc
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2013-02-20 17:59:11 +0100
committerBram Moolenaar <Bram@vim.org>2013-02-20 17:59:11 +0100
commit8738fc1be888d73fb4fe302cf085c0bcf4f52e91 (patch)
tree729de834b2f1a341d052d0f3e3db35a08e1c156f /runtime/doc
parent995a8cd18190c0b922796a8ee865e95bd1dbd916 (diff)
downloadvim-8738fc1be888d73fb4fe302cf085c0bcf4f52e91.zip
updated for version 7.3.828
Problem: Mappings are not aware of wildmenu mode. Solution: Add wildmenumode(). (Christian Brabandt)
Diffstat (limited to 'runtime/doc')
-rw-r--r--runtime/doc/eval.txt13
1 files changed, 13 insertions, 0 deletions
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index b1748c16a..6e8fa13a7 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -1993,6 +1993,7 @@ undotree() List undo file tree
values( {dict}) List values in {dict}
virtcol( {expr}) Number screen column of cursor or mark
visualmode( [expr]) String last visual mode used
+wildmenumode() Number whether 'wildmenu' mode is active
winbufnr( {nr}) Number buffer number of window {nr}
wincol() Number window column of the cursor
winheight( {nr}) Number height of window {nr}
@@ -6162,6 +6163,18 @@ visualmode([expr]) *visualmode()*
Dictionary or Float is not a Number or String, thus does not
cause the mode to be cleared.
+wildmenumode() *wildmenumode()*
+ Returns non-zero when the wildmenu is active and zero
+ otherwise. See 'wildmenu' and 'wildmode'.
+ This can be used in mappings to handle the 'wildcharm' option
+ gracefully. (Makes only sense with |mapmode-c| mappings).
+
+ For example to make <c-j> work like <down> in wildmode, use: >
+ :cnoremap <expr> <C-j> wildmenumode() ? "\<Down>\<Tab>" : "\<c-j>"
+<
+ (Note, this needs the 'wildcharm' option set appropriately).
+
+
*winbufnr()*
winbufnr({nr}) The result is a Number, which is the number of the buffer
associated with window {nr}. When {nr} is zero, the number of