diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2017-01-20 01:20:34 +0100 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2017-01-20 15:48:41 +0100 |
commit | ef753a76b95425e22638005f813cb2f22c6a0cfc (patch) | |
tree | 5e821b6e06848aa123931c191978833bd3a7e0d2 /test/functional/ui/screen.lua | |
parent | 8684fdda3b831c3ee75c65f70e6c088762b0b63e (diff) | |
download | rneovim-ef753a76b95425e22638005f813cb2f22c6a0cfc.tar.gz rneovim-ef753a76b95425e22638005f813cb2f22c6a0cfc.tar.bz2 rneovim-ef753a76b95425e22638005f813cb2f22c6a0cfc.zip |
tui: Enable mode-sensitive cursor by default.
Also give NVIM_TUI_ENABLE_CURSOR_SHAPE more granularity:
0 = do not change cursor shape
1 = non-blinking ("steady") cursor with mode-sensitive shape
2 = blinking cursor with mode-sensitive shape
Note: blink state is not changed for Konsole, instead user's terminal
preference makes the decision. (Can't do that for xterm-likes, DECSCUSR
forces us to choose blink-state.)
This is a temporary step until the TUI respects 'guicursor'
Ref: https://github.com/neovim/neovim/issues/2583#issuecomment-272988384
Diffstat (limited to 'test/functional/ui/screen.lua')
-rw-r--r-- | test/functional/ui/screen.lua | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/functional/ui/screen.lua b/test/functional/ui/screen.lua index ef1f0783e7..bb82f11a58 100644 --- a/test/functional/ui/screen.lua +++ b/test/functional/ui/screen.lua @@ -68,7 +68,8 @@ -- }) -- screen:set_default_attr_ignore( {{}, {bold=true, foreground=NonText}} ) -- --- To help write screen tests, see screen:snapshot_util(). +-- To help write screen tests, see Screen:snapshot_util(). +-- To debug screen tests, see Screen:redraw_debug(). local helpers = require('test.functional.helpers')(nil) local request, run, uimeths = helpers.request, helpers.run, helpers.uimeths @@ -520,9 +521,11 @@ function Screen:_current_screen() return table.concat(rv, '\n') end --- Utility to generate/debug tests. Call it where screen:expect() would be. --- Waits briefly, then dumps the current screen state in the form of --- screen:expect(). Use snapshot_util({},true) to generate a text-only test. +-- Generates tests. Call it where Screen:expect() would be. Waits briefly, then +-- dumps the current screen state in the form of Screen:expect(). +-- Use snapshot_util({},true) to generate a text-only (no attributes) test. +-- +-- @see Screen:redraw_debug() function Screen:snapshot_util(attrs, ignore) self:sleep(250) self:print_snapshot(attrs, ignore) |