Reputation: 792
I've used vi/vim for editing files and am comfortable with the basics of entering insert mode (pressing "a" key) and using ESC to get into control mode to write the file and exit.
I'm following the cvim
tutorial here, except I'm using vim-gtk on Ubuntu 12.04. Commands like ^Wv (Left Ctrl + W, then v) work correctly (split window down the middle), but when I go into command mode (press ESC) and do (\ is backslash character):
\if
It automatically puts me in insert mode. However, I can run the command from the GUI menu and it works fine (creating a C++ function in this case).
Am I missing something fundamental here? Is a backslash not a backslash? I cannot find any documentation anywhere on Google about this.
I'd be grateful if someone could point out where I'm going wrong. GVIM works fine from the menu, but it would be more productive to be able to use the commands within the editor.
Thanks in advance for any help/tips/pointers :-)
Upvotes: 2
Views: 515
Reputation: 792
The file must be saved as a valid C/C++ file before it will work. Thanks ire_and_curses for the resource
Upvotes: 1