The variable cursor-type
controls how the appearance of the cursor, defaulting to t
, which uses the cursor specified for the frame (see the docstring for options). If you'd like the cursor to default to a block, you can (setq cursor-type 'box)
.
However, evil
provides a number of different cursors for the different states, which you can adjust to give you a visual reminder of what state you're in when you're typing:
evil-normal-state-cursor
evil-insert-state-cursor
evil-visual-state-cursor
evil-motion-state-cursor
evil-replace-state-cursor
evil-operator-state-cursor
The docstring states that each of these:
May be a cursor type as per cursor-type
, a color string as passed
to set-cursor-color
, a zero-argument function for changing the
cursor, or a list of the above.
So, for example, if you wanted a yellow bar 5 pixels wide in insert state and a purple-filled box in normal state, you could do the following:
(setq evil-insert-state-cursor '((bar . 5) "yellow")
evil-normal-state-cursor '(box "purple"))
See the docstring for cursor-type
for your options in adjusting the cursor.
apropos
. You can hitC-h a
(apropos
), type a search ("evil cursor"), and hitRET
to find the documentation of any matching functions, variables, commands, etc. Helm has a built-in source for this as well:helm-apropos
.apropos
. Note, however, thatC-h a
is bound toapropos-command
by default, which will only list matching commands. If you wantapropos-command
to consider non-interactive functions, you'll have to doC-u
C-h a
. Theapropos
command (which will show both commands and variables) is not bound to a key by default.apropos-command
toapropos
-- turns out I had reboundC-h a
toapropos
a long time ago, forgot, and assumed it was the default.