aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui/popupmenu_spec.lua
Commit message (Collapse)AuthorAge
* refactor: use nvim.foo.bar format for autocommand groupsMaria José Solano2025-01-14
|
* vim-patch:9.1.1011: popupmenu internal error with some abbr in completion ↵zeertzjq2025-01-13
| | | | | | | | | | | | item (#31988) Problem: Popup menu internal error with some abbr in completion item. Solution: Don't compute attributes when there is no corresponding text. Reduce indent in pum_redraw() while at it (zeertzjq). fixes: vim/vim#16427 closes: vim/vim#16435 https://github.com/vim/vim/commit/3a0cc36c69744a7727ce34311d39d2d9d8ddc6f9
* vim-patch:9.1.1005: completion text is highlighted even with no pattern ↵zeertzjq2025-01-12
| | | | | | | | | | | | | found (#31973) Problem: completion text is highlighted even with no pattern found Solution: use ins_compl_leader_len() instead of checking compl_leader.length (glepnir) closes: vim/vim#16422 https://github.com/vim/vim/commit/9fddb8ae770be3e16545dd4c2f4cfaad8f62cb40 Co-authored-by: glepnir <glephunter@gmail.com>
* vim-patch:9.1.0996: ComplMatchIns may highlight wrong text (#31931)glepnir2025-01-10
| | | | | | | | | | Problem: ComplMatchIns may highlight wrong text Solution: don't highlight in case of fuzzy match, skip-highlight when not inserting anything (glepnir) closes: vim/vim#16404 https://github.com/vim/vim/commit/e890887b8052561ac5f8dce218e578ed28599cc6
* fix(popup): wrong extmark data sync when lines changed in popup preview #30246glepnir2025-01-05
| | | | | | | | Problem: when popup preview buffer has filetype like markdown and ts is enabled, the extmark clean and update not correct, if add the extmark sync there has lots of duplicate codes like nvim_buf_set_lines. Solution: use nvim_buf_set_lines api internally to set info to popup preview buffer.
* vim-patch:9.1.0956: completion may crash, completion highlight wrong with ↵glepnir2024-12-24
| | | | | | | | | | | | | | | | | | | | preview window Problem: completion may crash, completion highlight wrong with preview window (after v9.1.0954) Solution: correctly calculate scroll offset, check for preview window when adding extra highlighting (glepnir) when there have a preview window prepare_tagpreview will change curwin to preview window and this may cause ComplMatchIns check condition not correct. check wp is curwin and also the type of wp is not a preview or poup info fixes: https://github.com/vim/vim/issues/16284 closes: https://github.com/vim/vim/pull/16283 https://github.com/vim/vim/commit/8d0bb6dc9f2e5d94ebb59671d592c1b7fa325ca6
* vim-patch:9.1.0945: ComplMatchIns highlight doesn't end after inserted text ↵zeertzjq2024-12-18
| | | | | | | | | | | | (#31628) Problem: ComplMatchIns highlight doesn't end after inserted text. Solution: Handle ComplMatchIns highlight more like search highlight. Fix off-by-one error. Handle deleting text properly. (zeertzjq) closes: vim/vim#16244 https://github.com/vim/vim/commit/f25d8f9312a24da2727671560a865888812ab8d9
* vim-patch:9.1.0942: a few typos were foundzeertzjq2024-12-18
| | | | | | | | | Problem: a few typos were found Solution: fix them (zeertzjq) closes: vim/vim#16232 https://github.com/vim/vim/commit/d32bf0a06762f9ad08334d67b4d7f235f87f9063
* vim-patch:9.1.0941: ComplMatchIns doesn't work after multibyte charszeertzjq2024-12-18
| | | | | | | | | | Problem: ComplMatchIns doesn't work after multibyte chars (after v9.1.0936) Solution: Use (ptr - line) instead of wlv.col (zeertzjq). closes: vim/vim#16233 https://github.com/vim/vim/commit/f4ccada5c372b2c14cc32490860c6995cd00268c
* vim-patch:9.1.0934: hard to view an existing buffer in the preview window ↵zeertzjq2024-12-17
| | | | | | | | | | | | | | | | | | | | | | (#31605) Problem: hard to view an existing buffer in the preview window Solution: add the :pbuffer command (Yinzuo Jiang) Similar as `:pedit` and `:buffer` command. `:pbuffer` edits buffer [N] from the buffer list in the preview window. `:pbuffer` can also open special buffer, for example terminal buffer. closes: vim/vim#16222 https://github.com/vim/vim/commit/a2a2fe841ed2efdbb1f8055f752a3a4d0988ae9d Cherry-pick Test_popup_and_previewwindow_dump() changes from patch 9.0.0625. Cherry-pick Run_noroom_for_newwindow_test() changes from patches 8.2.0432 and 9.0.0363. Co-authored-by: Yinzuo Jiang <jiangyinzuo@foxmail.com>
* fix(float): close preview float window when no selected #29745glepnir2024-12-11
| | | | | | | Problem: Float preview window still exist when back at original. Or no info item is selected. Solution: if selected is -1 or no info is selected, if float preview window exist close it first.
* fix(tests): needing two calls to setup a screen is cringebfredl2024-11-14
| | | | | | | | | | Before calling "attach" a screen object is just a dummy container for (row, col) values whose purpose is to be sent as part of the "attach" function call anyway. Just create the screen in an attached state directly. Keep the complete (row, col, options) config together. It is still completely valid to later detach and re-attach as needed, including to another session.
* refactor(tests): continue the global highlight definition workbfredl2024-11-08
|
* vim-patch:9.1.0830: using wrong highlight group for spaces for popupmenu ↵zeertzjq2024-11-03
| | | | | | | | | | | | | (#31054) Problem: using wrong highlight group for spaces for popupmenu Solution: use original attribute instead of combined attributed (glepnir) closes: vim/vim#15978 https://github.com/vim/vim/commit/bc10be7a4060748ed1876ab91cf53a2a8701ac13 Co-authored-by: glepnir <glephunter@gmail.com>
* test(pum): add test for item selection with 'rightleft' (#30968)zeertzjq2024-10-28
|
* fix(pum): don't select item when clicking to the left/right (#30967)zeertzjq2024-10-28
| | | | | | | Problem: Selecting an item in the right-click menu when clicking to the left/right of it is confusing, especially in a UI that doesn't support 'mousemoveevent'. Solution: Don't select an item when clicking to the left/right of the right-click menu.
* feat(ui): cascading style inheritance for Pmenu* highlights #29980Riley Bruins2024-10-10
| | | | - `PmenuSel` and `PmenuMatch` inherit from `Pmenu` - `PmenuMatchSel` inherits from both `PmenuSel` and `PmenuMatch`
* vim-patch:9.1.0771: completion attribute hl_group is confusingzeertzjq2024-10-10
| | | | | | | | | | | | | Problem: Currently completion attribute hl_group is combined with all items, which is redundant and confusing with kind_hlgroup Solution: Renamed to abbr_hlgroup and combine it only with the abbr item (glepnir). closes: vim/vim#15818 https://github.com/vim/vim/commit/0fe17f8ffbd2588ecd2bf42dced556897bc64f89 Co-authored-by: glepnir <glephunter@gmail.com>
* vim-patch:9.1.0756: missing change from patch v9.1.0754 (#30636)glepnir2024-10-03
| | | | | | | | | Problem: missing change from patch v9.1.0754 Solution: use correct width for the actual item in pum_redraw() (glepnir) closes: vim/vim#15786 https://github.com/vim/vim/commit/a6d9e3c4e07f73f6523699961d8b7b54bdb80cf6
* vim-patch:9.1.0754: fixed order of items in insert-mode completion menu (#30619)glepnir2024-10-03
| | | | | | | | | | | | | Problem: fixed order of items in insert-mode completion menu Solution: Introduce the 'completeitemalign' option with default value "abbr,kind,menu" (glepnir). Adding an new option `completeitemalign` abbr is `cia` to custom the complete-item order in popupmenu. closes: vim/vim#14006 closes: vim/vim#15760 https://github.com/vim/vim/commit/6a89c94a9eeee53481ced1a1260a177bffde4c0f
* feat(defaults): popupmenu "Open in browser", "Go to definition" #30261Justin M. Keyes2024-09-05
| | | | - Use the popup to expose more features such as LSP and gx. - Move the copy/paste items lower in the menu, they are lower priority.
* vim-patch:9.1.0690: cannot set special highlight kind in popupmenu (#30128)zeertzjq2024-08-24
| | | | | | | | | | | Problem: cannot set special highlight kind in popupmenu Solution: add kind_hlgroup item to complete function (glepnir) closes: vim/vim#15561 https://github.com/vim/vim/commit/38f99a1f0d61e9bde3f4a3d0cbe2d06185c4a57f Co-authored-by: glepnir <glephunter@gmail.com>
* vim-patch:9.1.0629: Rename of pum hl_group is incompletezeertzjq2024-07-27
| | | | | | | | | | | Problem: Rename of pum hl_group is incomplete in source. Solution: Also rename the test function. Rename to user_hlattr in code to avoid confusion with pum_extra. Add test with matched text highlighting (zeertzjq). closes: vim/vim#15348 https://github.com/vim/vim/commit/4100852e099133a0c9603e1087e5dc6d82001ce7
* test(ui/popupmenu_spec): add case of hl_group field in complete itemsglepnir2024-07-27
| | | | | Problem: Missing test case for hl_group field in complete items. Solution: Add a test case for hl_group field.
* test(ui/popupmenu_spec): make highlights more consistentzeertzjq2024-07-27
|
* vim-patch:9.1.0538: not possible to assign priority when defining a sign ↵zeertzjq2024-07-07
| | | | | | | | | | | | | | | | | | (#29592) Problem: not possible to assign priority when defining a sign (Mathias Fußenegger) Solution: Add the priority argument for the :sign-define ex command and the sign_define() function (LemonBoy) Use the specified value instead of the default one (SIGN_DEF_PRIO) when no priority is explicitly specified in sign_place or :sign place. fixes: vim/vim#8334 closes: vim/vim#15124 https://github.com/vim/vim/commit/b975ddfdf96644b8df808415dee36f99abd48753 Co-authored-by: LemonBoy <thatlemon@gmail.com>
* vim-patch:9.1.0534: completion wrong with fuzzy when cycling back to ↵zeertzjq2024-07-06
| | | | | | | | | | | | | | original (#29588) Problem: completion wrong with fuzzy when cycling back to original (Quan Nguyen) Solution: reset show_match_ok when cp_score is zero (glepnir) fixes: vim/vim#15095 closes: vim/vim#15105 https://github.com/vim/vim/commit/65407ce1d2963e7a758af8fecdcbd67b9a90bdb9 Co-authored-by: glepnir <glephunter@gmail.com>
* vim-patch:9.1.0496: matched text is highlighted case-sensitivelyzeertzjq2024-06-18
| | | | | | | | | | | | | Problem: matched text is highlighted case-sensitively Solution: use MB_STRNICMP, update highlighting when the base changes (glepnir) fixes: vim/vim#15021 closes: vim/vim#15023 https://github.com/vim/vim/commit/f189138b39a11ed5cf3adea6610469b478841aba Co-authored-by: glepnir <glephunter@gmail.com>
* vim-patch:9.1.0495: Matched text isn't highlighted in cmdline pumzeertzjq2024-06-18
| | | | | | | | | | | | Problem: Matched text isn't highlighted in cmdline pum. Solution: Use cmdline completion pattern in cmdline mode. (zeertzjq) closes: vim/vim#15029 https://github.com/vim/vim/commit/d8c9340fc67ca19f82ec3e77ec38296424e758cf Cherry-pick syntax.txt change from runtime update.
* vim-patch:9.1.0494: Wrong matched text highlighted in pum with 'rightleft' ↵zeertzjq2024-06-17
| | | | | | | | | | | (#29371) Problem: Wrong matched text highlighted in pum with 'rightleft'. Solution: Match using the original text instead of the reversed text. (zeertzjq) closes: vim/vim#15020 https://github.com/vim/vim/commit/63901e89638d683ecbc8e3323170dd485657fd1d
* vim-patch:9.1.0491: Cmdline pum doesn't work properly with 'rightleft' (#29355)zeertzjq2024-06-15
| | | | | | | | | | | Problem: Cmdline pum doesn't work properly with 'rightleft'. Solution: Don't use curwin->w_p_rl in cmdline mode in pum_redraw(). Use a static variable since pum_may_redraw() may be called in any mode. Also correct position of other popups with 'rightleft'. (zeertzjq) closes: vim/vim#15005 https://github.com/vim/vim/commit/883018feff43413813770dd1e13d4f950aa38524
* vim-patch:9.1.0488: Wrong padding for pum "kind" with 'rightleft' (#29352)zeertzjq2024-06-15
| | | | | | | | | | | | | | Problem: Wrong padding for pum "kind" with 'rightleft'. Solution: Fix off-by-one error (zeertzjq). The screen_fill() above is end-exclusive, and - With 'rightleft' it fills `pum_col - pum_base_width - n + 1` to `col`, so the next `col` should be `pum_col - pum_base_width - n`. - With 'norightleft' it fills `col` to `pum_col - pum_base_width + n - 1`, so the next `col` should be `pum_col - pum_base_width + n`. closes: vim/vim#15004 https://github.com/vim/vim/commit/a2324373eb1c3f1777bc40cb6dcd5e895a15fe10
* vim-patch:9.1.0485: Matched text shouldn't be highlighted in "kind" and "menu"zeertzjq2024-06-15
| | | | | | | | | | Problem: Matched text shouldn't be highlighted in "kind" and "menu". Solution: Pass hlf_T instead of the attribute. Fix indent. (zeertzjq) closes: vim/vim#14996 https://github.com/vim/vim/commit/afbe5359e981e5d19ad23c394aefe60395c3648e
* vim-patch:9.1.0476: Cannot see matched text in popup menuzeertzjq2024-06-15
| | | | | | | | | | | | Problem: Cannot see matched text in popup menu Solution: Introduce 2 new highlighting groups: PmenuMatch and PmenuMatchSel (glepnir) closes: vim/vim#14694 https://github.com/vim/vim/commit/40c1c3317d92f8c2adadf744fab72e4458e2a9fa Co-authored-by: glepnir <glephunter@gmail.com>
* test: do not set termguicolors in test runnerGregory Anders2024-05-31
| | | | | It's not clear why this is needed and it has adverse side effects on other tests.
* fix(api): mark nvim__complete_set as experimental #28579Justin M. Keyes2024-04-30
| | | | | | | | Problem: nvim_complete_set was added in 5ed55ff14c8b7e346811cb6228bf63fb5106bae9 but needs more bake time. Solution: Rename it, mark it as experimental.
* fix(completion): improve popup window position (#26739)Raphael2024-04-25
|
* test: improve test conventionsdundargoc2024-04-23
| | | | | | | | | Specifically, functions that are run in the context of the test runner are put in module `test/testutil.lua` while the functions that are run in the context of the test session are put in `test/functional/testnvim.lua`. Closes https://github.com/neovim/neovim/issues/27004.
* refactor(test): inject after_each differentlyLewis Russell2024-04-10
|
* test: improve test conventionsdundargoc2024-04-08
| | | | Work on https://github.com/neovim/neovim/issues/27004.
* Merge pull request #28156 from bfredl/attr_extendbfredl2024-04-03
|\ | | | | refactor(tests): allow to extend the new base set of attrs
| * refactor(tests): allow to extend the new base set of attrsbfredl2024-04-02
| | | | | | | | | | | | | | | | | | | | | | We start at 100 so we can make the base set larger if needed. (It might need to grow/shrink as a result of adopting the new default color scheme as the default for tests) Usage best illustrataded by example. Improving the workflow for making new tests with `screen:snapshot_util()` will be a follow up.
* | vim-patch:9.0.0581: adding a character for incsearch fails at end of linezeertzjq2024-04-03
|/ | | | | | | | | Problem: Adding a character for incsearch fails at end of line. Solution: Only check cursor line number. https://github.com/vim/vim/commit/d4566c14e71c55dcef05fb34ea94eba835831527 Co-authored-by: Bram Moolenaar <Bram@vim.org>
* test: add test for scroll wheel at right-click menu (#27409)zeertzjq2024-02-10
|
* test: big cleanup followupLewis Russell2024-01-17
| | | | Followup to 07a7c0ec
* test: use integers for API Buffer/Window/Tabpage EXT typesLewis Russell2024-01-16
|
* test: rename (meths, funcs) -> (api, fn)Lewis Russell2024-01-12
|
* test: typing for helpers.methsLewis Russell2024-01-12
|
* test: remove helpers.sleep()Lewis Russell2024-01-12
|
* fix(pum): handle right-click menu repositioning with multigrid (#26975)zeertzjq2024-01-10
|