Skip to main content

Questions tagged [mode]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
1 answer
54 views

Search for ^@ in register '+'

After yanking into register + from Visual Block mode, the lines break are marked with ^@. I would like to detect this character, but I can't.. For example, if register + contains ^@ as shown below ...
xyx's user avatar
  • 464
0 votes
2 answers
38 views

Trying to display current mode leads to vimscript where variable is undefined inside function

I have following in my .vimrc set laststatus=2 set showcmd set wildmenu function! UpdateStatusline() let currentMode = mode() if currentMode ==# 'n' let currentMode = "Normal&...
Wakan Tanka's user avatar
0 votes
2 answers
336 views

How to force the Read-only mode?

Greetings Today I was learning the different methods for opening a file in Vim, and I recently learned the view [filename] or [vim_launcher] -R [file_name], while both of these commands are great, ...
KhodeNima's user avatar
  • 131
0 votes
0 answers
40 views

Why does vim insert an underlined e that can only be escaped with <esc>?

It seems like I have found a really strange mode by accident in vim, if you hit <C-;> in vim, it replaces whatever character at the cursor with an underlined e, and if I type it, it replaces ...
user avatar
0 votes
1 answer
173 views

How to set the mode from a vimscript?

If I save the result of :call mode() in a variable, how can I restore that mode later?
minseong's user avatar
  • 2,323