Home Explore Blog CI



neovim

100th chunk of `runtime/doc/options.txt`
b4ead032e74e18f227aad2a328a7f18c1554e211712300ff0000000100000fa1

		filename	the name of the file being edited
		-		indicates the file cannot be modified, 'ma' off
		+		indicates the file was modified
		=		indicates the file is read-only
		=+		indicates the file is read-only and modified
		(path)		is the path of the file being edited
		- Nvim		the server name |v:servername| or "Nvim"

							*'titlelen'*
'titlelen'		number	(default 85)
			global
	Gives the percentage of 'columns' to use for the length of the window
	title.  When the title is longer, only the end of the path name is
	shown.  A '<' character before the path name is used to indicate this.
	Using a percentage makes this adapt to the width of the window.  But
	it won't work perfectly, because the actual number of characters
	available also depends on the font used and other things in the title
	bar.  When 'titlelen' is zero the full path is used.  Otherwise,
	values from 1 to 30000 percent can be used.
	'titlelen' is also used for the 'titlestring' option.

							*'titleold'*
'titleold'		string	(default "")
			global
	If not empty, this option will be used to set the window title when
	exiting.  Only if 'title' is enabled.
	This option cannot be set from a |modeline| or in the |sandbox|, for
	security reasons.

							*'titlestring'*
'titlestring'		string	(default "")
			global
	When this option is not empty, it will be used for the title of the
	window.  This happens only when the 'title' option is on.

	When this option contains printf-style '%' items, they will be
	expanded according to the rules used for 'statusline'.  If it contains
	an invalid '%' format, the value is used as-is and no error or warning
	will be given when the value is set.

	The default behaviour is equivalent to: >vim
	    set titlestring=%t%(\ %M%)%(\ \(%{expand(\"%:~:h\")}\)%)%a\ -\ Nvim
<
	This option cannot be set in a modeline when 'modelineexpr' is off.

	Example: >vim
	    auto BufEnter * let &titlestring = hostname() .. "/" .. expand("%:p")
	    set title titlestring=%<%F%=%l/%L-%P titlelen=70
<	The value of 'titlelen' is used to align items in the middle or right
	of the available space.
	Some people prefer to have the file name first: >vim
	    set titlestring=%t%(\ %M%)%(\ (%{expand(\"%:~:.:h\")})%)%(\ %a%)
<	Note the use of "%{ }" and an expression to get the path of the file,
	without the file name.  The "%( %)" constructs are used to add a
	separating space only when needed.
	NOTE: Use of special characters in 'titlestring' may cause the display
	to be garbled (e.g., when it contains a CR or NL character).

					*'ttimeout'* *'nottimeout'*
'ttimeout'		boolean	(default on)
			global
	This option and 'ttimeoutlen' determine the behavior when part of a
	key code sequence has been received by the |TUI|.

	For example if <Esc> (the \x1b byte) is received and 'ttimeout' is
	set, Nvim waits 'ttimeoutlen' milliseconds for the terminal to
	complete a key code sequence. If no input arrives before the timeout,
	a single <Esc> is assumed. Many TUI cursor key codes start with <Esc>.

	On very slow systems this may fail, causing cursor keys not to work
	sometimes.  If you discover this problem you can ":set ttimeoutlen=9999".
	Nvim will wait for the next character to arrive after an <Esc>.

						*'ttimeoutlen'* *'ttm'*
'ttimeoutlen' 'ttm'	number	(default 50)
			global
	Time in milliseconds to wait for a key code sequence to complete. Also
	used for CTRL-\ CTRL-N and CTRL-\ CTRL-G when part of a command has
	been typed.

					*'undodir'* *'udir'* *E5003*
'undodir' 'udir'	string	(default "$XDG_STATE_HOME/nvim/undo//")
			global
	List of directory names for undo files, separated with commas.
	See 'backupdir' for details of the format.
	"." means using the directory of the file.  The undo file name for
	"file.txt" is ".file.txt.un~".
	For other directories the file name is the full path of the edited
	file, with path separators replaced with "%".
	When writing: The first directory that exists is used.  "." always
	works, no directories after "." will be used

Title: Vim Options: 'titleold', 'titlestring', 'ttimeout', 'ttimeoutlen', and 'undodir'
Summary
This section describes the Vim options related to window titles, terminal timeouts, and undo directories. 'titleold' sets the window title upon exiting Vim, 'titlestring' customizes the window title when the 'title' option is enabled, and 'ttimeout' and 'ttimeoutlen' control the behavior when a key code sequence is received by the TUI. Finally, 'undodir' specifies a list of directories for storing undo files.