Variable: cursor-type
cursor-type is a customizable and buffer-local variable defined in
buffer.c.
Documentation
Cursor to use when this buffer is in the selected window.
Values are interpreted as follows:
t use the cursor specified for the frame
nil don't display a cursor
box display a filled box cursor
(box . SIZE) display a filled box cursor, but make it
hollow if cursor is under masked image larger than
SIZE pixels in either dimension.
hollow display a hollow box cursor
bar display a vertical bar cursor with default width
(bar . WIDTH) display a vertical bar cursor with width WIDTH
hbar display a horizontal bar cursor with default height
(hbar . HEIGHT) display a horizontal bar cursor with height HEIGHT
ANYTHING ELSE display a hollow box cursor
WIDTH and HEIGHT can't exceed the frame's canonical character size.
When the buffer is displayed in a non-selected window, the
cursor's appearance is instead controlled by the variable
cursor-in-non-selected-windows.
Probably introduced at or before Emacs version 21.1.
Source Code
// Defined in /usr/src/emacs/src/buffer.c
DEFVAR_PER_BUFFER ("cursor-type", &BVAR (current_buffer, cursor_type), Qnil,
doc: /* Cursor to use when this buffer is in the selected window.
Values are interpreted as follows:
t use the cursor specified for the frame
nil don't display a cursor
box display a filled box cursor
(box . SIZE) display a filled box cursor, but make it
hollow if cursor is under masked image larger than
SIZE pixels in either dimension.
hollow display a hollow box cursor
bar display a vertical bar cursor with default width
(bar . WIDTH) display a vertical bar cursor with width WIDTH
hbar display a horizontal bar cursor with default height
(hbar . HEIGHT) display a horizontal bar cursor with height HEIGHT
ANYTHING ELSE display a hollow box cursor
WIDTH and HEIGHT can't exceed the frame's canonical character size.
When the buffer is displayed in a non-selected window, the
cursor's appearance is instead controlled by the variable
`cursor-in-non-selected-windows'. */);