mirror of
https://github.com/mhinz/vim-galore.git
synced 2025-02-24 01:59:28 +08:00
Neovim: change cursor style dependent on mode
This commit is contained in:
parent
09c8f4fa9d
commit
cb2b9fa73b
@ -47,6 +47,7 @@ All notable changes to this project will be documented in this file.
|
||||
- Misc: [Map CapsLock to Control](README.md#map-capslock-to-control)
|
||||
- Neovim: [Terminal emulator](content/neovim.md#terminal-emulator)
|
||||
- Neovim: [Configuration](content/neovim.md#configuration)
|
||||
- Neovim: [Change cursor style dependent on mode](content/neovim.md#change-cursor-style-dependent-on-mode)
|
||||
|
||||
### Changed
|
||||
|
||||
|
@ -67,7 +67,7 @@ Twitter](https://twitter.com/_mhinz_). Thanks!
|
||||
- [Quickly edit your macros](#quickly-edit-your-macros)
|
||||
- [Quickly jump to header or source file](#quickly-jump-to-header-or-source-file)
|
||||
- [Quickly change font size in GUI](#quickly-change-font-size-in-gui)
|
||||
- [Change cursor style in insert mode](#change-cursor-style-in-insert-mode)
|
||||
- [Change cursor style dependent on mode](#change-cursor-style-dependent-on-mode)
|
||||
- [Don't lose selection when shifting sidewards](#dont-lose-selection-when-shifting-sidewards)
|
||||
- [Reload a file on saving](#reload-a-file-on-saving)
|
||||
- [Smarter cursorline](#smarter-cursorline)
|
||||
@ -1762,7 +1762,7 @@ command! Bigger :let &guifont = substitute(&guifont, '\d\+$', '\=submatch(0)+1'
|
||||
command! Smaller :let &guifont = substitute(&guifont, '\d\+$', '\=submatch(0)-1', '')
|
||||
```
|
||||
|
||||
#### Change cursor style in insert mode
|
||||
#### Change cursor style dependent on mode
|
||||
|
||||
I like to use a block cursor in normal mode, i-beam cursor in insert mode, and
|
||||
underline cursor in replace mode. Also when using tmux in the middle.
|
||||
|
@ -3,6 +3,7 @@
|
||||
- [Help](#help)
|
||||
- [Configuration](#configuration)
|
||||
- [Terminal emulator](#terminal-emulator)
|
||||
- [Change cursor style dependent on mode](#change-cursor-style-dependent-on-mode)
|
||||
|
||||
---
|
||||
|
||||
@ -82,3 +83,18 @@ Related help:
|
||||
|
||||
:h :terminal
|
||||
:h nvim-terminal-emulator
|
||||
|
||||
#### Change cursor style dependent on mode
|
||||
|
||||
The method mentioned in the [Vim
|
||||
section](../README.md#change-cursor-style-dependent-on-mode) doesn't work in
|
||||
Neovim. Instead, define the environment variable `NVIM_TUI_ENABLE_CURSOR_SHAPE`
|
||||
either in your shell config or in your vimrc:
|
||||
|
||||
```vim
|
||||
if has('nvim')
|
||||
let $NVIM_TUI_ENABLE_CURSOR_SHAPE = 1
|
||||
endif
|
||||
```
|
||||
|
||||
Related help: `$ man 1 nvim`
|
||||
|
Loading…
x
Reference in New Issue
Block a user