aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui
Commit message (Collapse)AuthorAge
...
* test(ui/messages_spec): unskip msg_puts_printf test on Unix CI (#27941)zeertzjq2024-03-20
| | | It no longer fails on Unix CI.
* fix(pager): handle consecutive newlines properly (#27913)zeertzjq2024-03-18
|
* fix(messages): allow more prompt in headless mode with UI (#27905)zeertzjq2024-03-18
| | | | | Problem: More prompt is not shown in headless mode even if there is a UI attached. Solution: Don't skip more prompt when there is a UI active.
* fix(mouse): click after eol with conceal and virtual text (#27897)zeertzjq2024-03-17
| | | | | Problem: Wrong cursor position when clicking after end of line with 'virtualedit', conceal and virtual text. Solution: Always fill linebuf_vcol[] for the columns to clear.
* refactor(drawline): integrate terminal hl with eol loop (#27893)zeertzjq2024-03-17
| | | | | | | There is no test for using 'cursorline' in Normal mode in a terminal buffer, so add a test and fix 'cursorcolumn' remaining when entering Terminal mode. Also move synIDattr() tests to ui/highlight_spec.lua.
* fix(normal): don't check conceal when pressing 'r' (#27892)zeertzjq2024-03-17
| | | | | | | | Problem: Cursor line is unconcealed when pressing 'r' in Normal mode when 'concealcursor' contains 'n' but not 'i'. Solution: Don't check conceal when pressing 'r' in Normal mode. Vim doesn't have this problem because it doesn't call redrawWinline() in conceal_check_cursor_line() and instead sets a global variable.
* fix(drawline): check filler_todo in place of removed draw_state (#27889)zeertzjq2024-03-17
| | | | The only place it matters is the conceal wcol check, but it can avoid unnecessary computations at other places.
* Merge pull request #27877 from bfredl/pseudorandombfredl2024-03-16
|\ | | | | fix(intro): redrawing intro exposing pseudo-randomness
| * fix(intro): redrawing intro exposing pseudo-randomnessbfredl2024-03-16
| | | | | | | | | | problem: redrawing intro exposes pseudo-randomness solution: remove pseudo-randomness
* | fix(l10n): update Japanese translations (#27856)ite-usagi2024-03-16
|/
* Merge pull request #27867 from bfredl/intro_multigridbfredl2024-03-15
|\ | | | | fix(ui): startup intro message should be visible with ext_multigrid
| * fix(ui): startup intro message should be visible with ext_multigridbfredl2024-03-15
| | | | | | | | | | | | | | | | As this message is literally drawn on top of the EOB area of the first window, the simple solution is to just draw the message on top of the grid of the first window. We still want #24764 (msg_intro event) but now only for ext_messages.
* | fix(ui): ext_cmdline should not move cursor to curwinLuuk van Baal2024-03-15
|/ | | | | | | | | | | Problem: The ext_cmdline cursor position on the screen seems to rely on an implicit assumption that the event listener implements a cmdline window that is made the current window which is problematic (e.g. breaks 'incsearch' in the actual current window). Solution: Remove this assumption and allow nvim_win_set_cursor() to move the cursor on the screen to a non-current window (previous commit).
* fix(highlight): don't show CursorColumn on current line (#27848)zeertzjq2024-03-15
| | | | | | | | | | | | Problem: CursorColumn highlight behavior is inconsistent with 'virtualedit' set: - If cursor is on the text, CursorColumn is not shown. - If cursor is after end of line, CursorColumn is shown. Solution: Don't shown CursorColumn on current line if cursor is after end of line. Vim doesn't have this problem because in most cases it uses the code path for drawing buffer text when CursorColumn highlight is needed.
* fix(intro): make intro explicitly statefulbfredl2024-03-14
| | | | | | | | | | | Instead of randomly disappearing because some random event might have caused mid_start or bot_scroll_start to randomly take a low value, treat intro message as a _first class stateful_ thing. This means that intro message will kept being _redrawn_ as long as we are in the state it should be shown. This also includes screen resizes. you will not lose the intro message because there was a delay in detecting terminal features.
* fix(drawline): initialize linebuf_attr to 0 instead of -1 (#27840)zeertzjq2024-03-13
| | | This also obviates the end-of-line loop when there is virtual text.
* Merge pull request #27812 from luukvbaal/cmdheightbfredl2024-03-11
|\ | | | | feat(ui): allow non-zero 'cmdheight' with ext_messages
| * feat(ui): allow non-zero 'cmdheight' with ext_messagesLuuk van Baal2024-03-11
| | | | | | | | | | | | | | Problem: Arbitrary restriction on 'cmdheight' with ext_messages. The 'cmdheight'-area may be desirable for the replacing cmdline. Solution: Allow non-zero 'cmdheight' with ext_messages.
* | test: correct order of arguments to eq() (#27816)zeertzjq2024-03-11
|/
* revert: "fix(window): :close crash with autocmd, floats and tabpage" (#27796)zeertzjq2024-03-10
| | | | | | | | This reverts PR #27793. On second thought, this solution may still crash, because it can leave a window with a NULL buffer if there are autocommand windows or if closing a floating window fails. It also makes close_last_window_tabpage() more complicated, so revert it.
* fix(window): :close crash if WinClosed from float closes window (#27794)zeertzjq2024-03-10
| | | | Problem: :close crash if WinClosed from float closes window. Solution: Check if window has already been closed.
* fix(window): :close crash with autocmd, floats and tabpage (#27793)zeertzjq2024-03-10
| | | | Problem: :close crash with autocmd, floats and tabpage. Solution: Close floating windows in one more case.
* fix(window): :close may cause Nvim to quit with autocmd and floatzeertzjq2024-03-09
| | | | | | | Problem: :close may cause Nvim to quit if an autocommand triggered when closing the buffer closes all other non-floating windows and there are floating windows. Solution: Correct the check for the only non-floating window.
* vim-patch:9.1.0118: Use different restoration strategy in win_splitmoveSean Dewar2024-03-08
| | | | | | | | | | | | | Problem: saving and restoring all frames to split-move is overkill now that WinNewPre is not fired when split-moving. Solution: defer the flattening of frames until win_split_ins begins reorganising them, and attempt to restore the layout by undoing our changes. (Sean Dewar) https://github.com/vim/vim/commit/704966c2545897dfcf426dd9ef946aeb6fa80c38 Adjust winframe_restore to account for Nvim's horizontal separators when the global statusline is in use. Add a test.
* vim-patch:9.1.0116: win_split_ins may not check available roomSean Dewar2024-03-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: win_split_ins has no check for E36 when moving an existing window Solution: check for room and fix the issues in f_win_splitmove() (Sean Dewar) https://github.com/vim/vim/commit/0fd44a5ad81ade342cb54d8984965bdedd2272c8 Omit WSP_FORCE_ROOM, as it's not needed for Nvim's autocmd window, which is floating. Shouldn't be difficult to port later if it's used for anything else. Make win_splitmove continue working for turning floating windows into splits. Move the logic for "unfloating" a float to win_split_ins; unlike splits, no changes to the window layout are needed before calling it, as floats take no room in the window layout and cannot affect the e_noroom check. Add missing tp_curwin-fixing logic for turning external windows into splits, and add a test. NOTE: there are other issues with the way "tabpage independence" is implemented for external windows; namely, some things assume that tp_curwin is indeed a window within that tabpage, and as such, functions like tabpage_winnr and nvim_tabpage_get_win currently don't always work for external windows (with the latter aborting!) Use last_status over frame_add_statusline, as Nvim's last_status already does this for all windows in the current tabpage. Adjust restore_full_snapshot_rec to handle this. This "restore everything" approach is changed in a future commit anyway, so only ensure it's robust enough to just pass tests. Keep check_split_disallowed's current doc comment, as it's actually a bit more accurate here. (I should probably PR Vim to use this one) Allow f_win_splitmove to move a floating "wp" into a split; Nvim supports this. Continue to disallow it from moving the autocommand window into a split (funnily enough, the check wasn't reachable before, as moving a float was disallowed), but now return -1 in that case (win_splitmove also returns FAIL for this, but handling it in f_win_splitmove avoids us needing to switch windows first). Cherry-pick Test_window_split_no_room fix from v9.1.0121. Update nvim_win_set_config to handle win_split_ins failure in later commits.
* fix(column): full redraw with 'stc, 'rnu' and inserted lines (#27712)luukvbaal2024-03-03
| | | | Problem: Text is not redrawn with 'relativenumber' when only the 'statuscolumn' is redrawn after inserted lines. Solution: Force a full redraw if statuscolumn width changed.
* fix(float): allow floating window in cmdline areaLuuk van Baal2024-03-01
| | | | | Problem: Floats are arbitrarily positioned at 1 row above screen size. Solution: Position at 1 row above 'cmdheight', only if window is hidden behind the message area.
* vim-patch:b1427b46f5fe (#27652)zeertzjq2024-02-28
| | | | | | | | | | | | | runtime(vim): Update base-syntax, improve :echo highlighting (vim/vim#14103) - Normalise behaviour of :echo commands and improve expression matching. - Allow continued argument lines. - Refine string interpolation groups. - Remove duplicated :menu and :map generated commands that are handled specially later in the file. https://github.com/vim/vim/commit/b1427b46f5fe50a1daba102c4017d0ef2624b3ba Co-authored-by: dkearns <dougkearns@gmail.com>
* test: don't use minimal timeout for "intermediate" flag (#27620)zeertzjq2024-02-25
| | | | | | With "intermediate" flag, only using minimal timeout is too short and may lead to failures. Also remove the fallback timeout in screen:expect_unchanged(), as having a different fallback timeout than screen:expect() is confusing.
* fix(marktree): some marks counted twice when checking for overlapbfredl2024-02-23
| | | | fixes #27046
* fix(api): don't leak memory with nvim_win_get_ns (#27570)zeertzjq2024-02-22
|
* fix(extmarks): redraw properly with scoped inline virt_text (#27569)zeertzjq2024-02-22
|
* feat(extmark): window scoped extmarkaltermo2024-02-21
| | | | Co-authored-by: zeertzjq <zeertzjq@outlook.com>
* fix(extmarks): priority order of inline and non-inline virt_text (#27532)zeertzjq2024-02-20
|
* feat(tabline): middle mouse button now closes tab (#27522)Nacho Nieva2024-02-19
|
* fix(decorations): crash with revised mark with changed decoration flagsbfredl2024-02-17
| | | | fixes #27211
* vim-patch:9.1.0106: Visual highlight hard to read with 'termguicolors'zeertzjq2024-02-15
| | | | | | | | | | | | | | | Problem: Visual highlight hard to read with 'termguicolors' (Maxim Kim) Solution: Set Visual GUI foreground to black (with background=light) and lightgrey (with background=dark) (Maxim Kim) fixes: vim/vim#14024 closes: vim/vim#14025 https://github.com/vim/vim/commit/34e4a05d02a016fe230495be8f6c60ddd56f9567 Co-authored-by: Maxim Kim <habamax@gmail.com>
* fix(extmarks): redraw line on adding/removing conceal (#27463)zeertzjq2024-02-14
|
* vim-patch:9.1.0103: 'breakindentopt' "min" not correct with 'signcolumn' ↵zeertzjq2024-02-13
| | | | | | | | | | | (#27451) Problem: 'breakindentopt' "min" works incorrectly with 'signcolumn'. Solution: Use win_col_off() and win_col_off2(). (zeertzjq) closes: vim/vim#14014 https://github.com/vim/vim/commit/f0a9d65e0a1d693cdfa964aa72de5b93b4cacdea
* Merge pull request #27348 from fredizzimo/fsundvik/fix-ext-hlstatebfredl2024-02-12
|\ | | | | fix: crashes with large msgpack messages
| * test: add more hlstate testsFred Sundvik2024-02-05
| |
* | fix(extmarks): redraw pre-undo position (#27437)zeertzjq2024-02-12
| | | | | | | | | | | | | | Problem: Virtual text not redrawn properly after undo moves its extmark. Solution: Redraw the moved extmark's pre-undo position.
* | perf(extmarks): avoid unnecessary invalidations for virt_text (#27435)zeertzjq2024-02-12
| | | | | | | | Invalidation of most w_valid flags isn't needed when adding or removing virtual text below cursor.
* | fix(column): use a single path for sign sorting (#27431)luukvbaal2024-02-12
| | | | | | | | | | | | Problem: #25826 added a (duplicate) sign comparison function, which was modified and strayed from the original in #27418. Solution: Merge the two functions and add a display test that actually tests for this order in addition to the legacy tests.
* | fix(messages): clear new lines when increasing 'cmdheight' (#27421)zeertzjq2024-02-11
| |
* | test(ui/mouse_spec): make sure click is processed (#27412)zeertzjq2024-02-10
| |
* | test: add test for scroll wheel at right-click menu (#27409)zeertzjq2024-02-10
| |
* | vim-patch:9.1.0083: Redrawing can be improved when deleting lines with 'number'zeertzjq2024-02-08
| | | | | | | | | | | | | | | | | | | | | | Problem: Redrawing can be improved when inserting/deleting lines with 'number'. Solution: Only redraw the number column of lines below changed lines. Add a test as this wasn't previously tested. (zeertzjq) closes: vim/vim#13985 https://github.com/vim/vim/commit/ae07ebc04b0726e12b1af39d52e01d86ae79ef0a
* | refactor(api): use keydict and arena for more api return valuesbfredl2024-02-08
| | | | | | | | | | | | | | Implement api_keydict_to_dict as the complement to api_dict_to_keydict Fix a conversion error when nvim_get_win_config gets called from lua, where Float values "x" and "y" didn't get converted to lua numbers.
* | fix(column): handle w_redr_statuscol at end filler lines (#27365)zeertzjq2024-02-06
| | | | | | | | There doesn't seem to be an easy solution that doesn't involve a goto. Also remove duplicate assignment in win_line().