Restore cursor line number highlighting; unset mouse
dblume

dblume commited on 2024-03-26 10:10:19
Showing 2 changed files, with 5 additions and 2 deletions.


Restore highlighting for the current cursor line number to the way
neovim worked pre 8.0.
See https://vi.stackexchange.com/questions/17073/cursorlinenr-highlight-not-working
... ...
@@ -25,6 +25,8 @@ hi Normal	guifg=White guibg=grey20
25 25
 
26 26
 " highlight groups
27 27
 hi Cursor	guibg=khaki guifg=slategrey
28
+hi CursorLine	cterm=None guifg=Normal guibg=Normal
29
+hi CursorLineNr	cterm=None ctermfg=11 gui=bold guifg=Yellow
28 30
 "hi CursorIM
29 31
 "hi Directory
30 32
 "hi DiffAdd
... ...
@@ -12,6 +12,7 @@ set undofile        " undo even after closing and reopening a file
12 12
 set noshowcmd       " Show size of selected area in visual mode on last line
13 13
 set noruler         " Show coordinates on status line
14 14
 set hidden          " Don't abandon Scratch buffer when hidden.
15
+set cursorline      " For CursorLineNR formatting similar to pre 8.0.
15 16
 
16 17
 " Make j and k move to the next row, not file line
17 18
 nnoremap j gj
... ...
@@ -60,8 +61,8 @@ endif
60 61
 au InsertEnter * hi statusline guibg=Cyan ctermfg=25 guifg=Black ctermbg=248
61 62
 au InsertLeave * hi statusline term=bold,reverse cterm=bold,reverse ctermfg=23 ctermbg=250 guifg=black guibg=#c2bfa5
62 63
 
63
-" May want to "set mouse=" See https://neovim.io/doc/user/vim_diff.html#_default-mouse
64
-" set mouse=v  " visual mode, not great in PuTTY, neovim defaults to nvi
64
+" See https://neovim.io/doc/user/vim_diff.html#_default-mouse
65
+set mouse=  " neovim defaults to nvi
65 66
 
66 67
 " Make c-] show a list of tags, or jump straight if only single tag
67 68
 nnoremap <c-]> g<c-]>
68 69