Pasting in VIM from KDE’s clipboard
Posted in Linux Development on January 19th, 2011 by OneOfOneFor some reason I couldn’t find it anywhere, but the register for the KDE clipboard (ctrl-c / ctrl-v) is + not * .
To paste from the KDE clipboard in insert mode : CTRL-R +, in normal mode : “+p .
To map it to ctrl-v : :imap
To paste from the system selection (mouse middle button) in insert mode : CTRL-R * or in normal mode “*p .
To paste from the VIM buffer in insert mode : CTRL-R “.
To set the system clipboard as the default clipboard for vim (for yy,dd,cc,p) : :set clipboard=unnamedplus .
Also make sure to check :registers .