summaryrefslogtreecommitdiffstats
path: root/runtime
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-05-30 21:24:26 +0200
committerBram Moolenaar <Bram@vim.org>2019-05-30 21:24:26 +0200
commitac1f1bc222b7de3cb2d3f1f2aa076f11c75e69de (patch)
treebc71b9f718cce9434723e4e452d13ccd93d6c177 /runtime
parentcc31ad9f9b601d53926b96586bd6b40602d57951 (diff)
patch 8.1.1429: "pos" option of popup window not supported yetv8.1.1429
Problem: "pos" option of popup window not supported yet. Solution: Implement the option. Rename popup_getposition() to popup_getpos().
Diffstat (limited to 'runtime')
-rw-r--r--runtime/doc/popup.txt26
1 files changed, 15 insertions, 11 deletions
diff --git a/runtime/doc/popup.txt b/runtime/doc/popup.txt
index 58728c8c4f..ad30e58270 100644
--- a/runtime/doc/popup.txt
+++ b/runtime/doc/popup.txt
@@ -232,7 +232,8 @@ popup_setoptions({id}, {options}) *popup_setoptions()*
popup_getoptions({id}) *popup_getoptions()*
Return the {options} for popup {id} in a Dict.
- A zero value means the option was not set.
+ A zero value means the option was not set. For "zindex" the
+ default value is returned, not zero.
The "highlight" entry is omitted, use the 'wincolor' option
for that: >
@@ -240,7 +241,7 @@ popup_getoptions({id}) *popup_getoptions()*
< If popup window {id} is not found an empty Dict is returned.
-popup_getposition({id}) *popup_getposition()*
+popup_getpos({id}) *popup_getpos()*
Return the position and size of popup {id}. Returns a Dict
with these entries:
col screen column of the popup, one-based
@@ -303,19 +304,22 @@ optionally text properties. It is in one of three forms:
|popup-props|.
The second argument of |popup_create()| is a dictionary with options:
- line screen line where to position the popup; can use
- "cursor", "cursor+1" or "cursor-1" to use the line of
- the cursor and add or subtract a number of lines;
- default is "cursor-1".
- col screen column where to position the popup; can use
- "cursor" to use the column of the cursor, "cursor+99"
- and "cursor-99" to add or subtract a number of
- columns; default is "cursor"
+ line screen line where to position the popup; can use a
+ number or "cursor", "cursor+1" or "cursor-1" to use
+ the line of the cursor and add or subtract a number of
+ lines; if omitted the popup is vertically centered,
+ otherwise "pos" is used.
+ col screen column where to position the popup; can use a
+ number or "cursor" to use the column of the cursor,
+ "cursor+99" and "cursor-99" to add or subtract a
+ number of columns; if omitted the popup is
+ horizontally centered, otherwise "pos" is used
pos "topleft", "topright", "botleft" or "botright":
defines what corner of the popup "line" and "col" are
used for. When not set "topleft" is used.
Alternatively "center" can be used to position the
- popup in the center of the Vim window.
+ popup in the center of the Vim window, in which case
+ "line" and "col" are ignored.
{not implemented yet}
flip when TRUE (the default) and the position is relative
to the cursor, flip to below or above the cursor to