Mercurial > vim
comparison runtime/doc/popup.txt @ 16904:9138e2c60bf1 v8.1.1453
patch 8.1.1453: popup window "moved" property not implemented yet
commit https://github.com/vim/vim/commit/3397f74ac2ac27f1eef48e950c3c8eeb0338fe55
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jun 2 18:40:06 2019 +0200
patch 8.1.1453: popup window "moved" property not implemented yet
Problem: Popup window "moved" property not implemented yet.
Solution: Implement it.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 02 Jun 2019 18:45:06 +0200 |
parents | 52fc577a087d |
children | d23afa4d8b63 |
comparison
equal
deleted
inserted
replaced
16903:52ff7612af87 | 16904:9138e2c60bf1 |
---|---|
88 Probably 2. is the best choice. | 88 Probably 2. is the best choice. |
89 | 89 |
90 | 90 |
91 IMPLEMENTATION: | 91 IMPLEMENTATION: |
92 - Code is in popupwin.c | 92 - Code is in popupwin.c |
93 - Fix positioning with border and padding. | |
94 - Why does 'nrformats' leak from the popup window buffer??? | 93 - Why does 'nrformats' leak from the popup window buffer??? |
95 - Make redrawing more efficient and avoid flicker. | 94 - Make redrawing more efficient and avoid flicker. |
96 First draw popups, creating a mask, use the mask in screen_line() when | 95 First draw popups, creating a mask, use the mask in screen_line() when |
97 drawing other windows and stuff. Mask contains zindex of popups. | 96 drawing other windows and stuff. Mask contains zindex of popups. |
98 Keep mask until next update_screen(), use when drawing status lines. | 97 Keep mask until next update_screen(), use when drawing status lines. |
408 'encoding' is "utf-8", otherwise ASCII characters are | 407 'encoding' is "utf-8", otherwise ASCII characters are |
409 used. | 408 used. |
410 zindex Priority for the popup, default 50. | 409 zindex Priority for the popup, default 50. |
411 time Time in milliseconds after which the popup will close. | 410 time Time in milliseconds after which the popup will close. |
412 When omitted |popup_close()| must be used. | 411 When omitted |popup_close()| must be used. |
413 moved "cell": close the popup if the cursor moved at least | 412 moved Specifies to close the popup if the cursor moved: |
414 one screen cell. | 413 - "any": if the cursor moved at all |
415 "word" allows for moving the cursor within |<cword>| | 414 - "word": if the cursor moved outside |<cword>| |
416 "WORD" allows for moving the cursor within |<cWORD>| | 415 - "WORD": if the cursor moved outside |<cWORD>| |
417 a list with two numbers specifies the start and end | 416 - [{start}, {end}]: if the cursor moved before column |
418 column outside of which the popup will close | 417 {start} or after {end} |
419 {not implemented yet} | 418 The popup also closes if the cursor moves to another |
419 line or to another window. | |
420 filter A callback that can filter typed characters, see | 420 filter A callback that can filter typed characters, see |
421 |popup-filter|. | 421 |popup-filter|. |
422 callback A callback that is called when the popup closes, e.g. | 422 callback A callback that is called when the popup closes, e.g. |
423 when using |popup_filter_menu()|, see |popup-callback|. | 423 when using |popup_filter_menu()|, see |popup-callback|. |
424 | 424 |
508 | 508 |
509 The callback is invoked with two arguments: the ID of the popup window and the | 509 The callback is invoked with two arguments: the ID of the popup window and the |
510 result, which could be an index in the popup lines, or whatever was passed as | 510 result, which could be an index in the popup lines, or whatever was passed as |
511 the second argument of `popup_close()`. | 511 the second argument of `popup_close()`. |
512 | 512 |
513 If the popup is closed because the cursor moved, the number -1 is passed to | |
514 the callback. | |
515 | |
513 ============================================================================== | 516 ============================================================================== |
514 3. Examples *popup-examples* | 517 3. Examples *popup-examples* |
515 | 518 |
516 TODO | 519 TODO |
517 | 520 |