3

Rather than make a mapping (particularly over top of the helpful <C-u> kill-line), I suggest the following: Open the command-line window. q: from normal mode, or <C-f> if already typing a : command. Use vim’s editing commands, such as gUiw


3

Yes you can. The preliminaries: we will need to determine if the last opening \( comes before or after the last closing \) in order to determine which delimiter to insert. (This also means we don't have a literal mapping—we are going to use <expr> instead.) So I created ~/.vim/autoload/pos.vim with the following contents: " true iff p1 is before p2 ...


3

Typically what you want is for backspace to send ^? and not ^H. (I need a citation, but this is typically how modern terminals work.) It looks like MobaXterm has an option to have backspace send ^H, I imagine that option is currently set on your MobaXterm, perhaps start by trying to uncheck that option. Then you should look into why Vim has an impression ...


2

You could avoid this by using the right files: :h ftplugin *41.12* Writing a filetype plugin *write-filetype-plugin* *ftplugin* A filetype plugin is like a global plugin, except that it sets options and defines mappings for the current buffer only. See |add-filetype-plugin| for how this type of plugin is used. So keep your command related to syntax in ...


2

If I understand your question correctly, you are trying to use the vimtex keybinding for the <plug>(vimtex-compile) command and you're expecting it should be available under ;ll, since you have let mapleader = ';' at the start of your _vimrc. If that's the case, the problem you're having is that vimtex actually uses the <localleader> (not <...


2

Do the :execute inside your mapping instead. You don't need to use <Space> in mappings, you can just use an actual space instead. You probably want to include a <cr> at the end, to actually execute the :Files command and not leave it pending on the command line waiting for you to press enter (but, again, maybe that's what you want?) Putting it ...


2

The question is how can I turn current words into upper case in the command line. I am aware of the command window. Simply open the command window, process the command, and get back to the command line, all inside a single mapping: cnoremap <C-U> <C-F>gUiww<C-C>


1

Assuome current command : echo "hello world" ^ ^ marks current cursor, after upcase current word, it becomes: echo "HELLO world" ^ The key part is to split your command into 3 parts: echo "hello world" --1----^ ---3----- ---2-- This can be done with :h /\%c : echo matchlist('echo "hello world"', '\v^(.*)(...


1

Use <c-\>, which despite the backslash doesn't need to be escaped in maps. Alternatively, <c-bslash> is the same, useful in cases such as strings where the backslash has meaning.


1

If you're using vim, you want a :noremap variant. To apply this for just the current editing session, and just in insert mode, :inoremap [ { :inoremap ] } :inoremap 9 ( :inoremap 0 ) :inoremap 7 & :inoremap \\ \| Note that the last one is different. \ and | are both special characters in vim's editor mode, they need to be escaped. I'm pretty sure in ...


1

You are looking for this which I found at the bottom of :h keycodes: nnoremap <C-LeftMouse> :echom 'Foo'<CR> And according to :h <LeftMouse> you also need to check that set mouse contains a or n


1

:h xterm-function-keys An xterm can send function keys F1 to F4 in two modes: vt100 compatible or not. Because Vim may not know what the xterm is sending, both types of keys are recognized. The same happens for the <Home> and <End> keys. normal vt100 ~ <F1> t_k1 <Esc>[11~ <xF1> &...


1

Reason may be not in ycm, but in other plugins: I noticed that jedi-vim takes control over go-to command and after specifying let g:jedi#use_tabs_not_buffers = 1 all work as expected


1

You could add this to your .vimrc to disable the arrow keys in Command, Insert, Normal and Visual Mode: " Remove newbie crutches in Command Mode cnoremap <Down> <Nop> cnoremap <Left> <Nop> cnoremap <Right> <Nop> cnoremap <Up> <Nop> " Remove newbie crutches in Insert Mode inoremap <Down> <Nop> ...


Only top voted, non community-wiki answers of a minimum length are eligible