CTRL-V映射到粘贴而不是阻止视觉模式在Vim on Elementary OS(linux)上

时间:2015-06-28 08:39:03

标签: linux vim editor

我刚开始在Linux发行版上使用Vim - 初级操作系统。在Vim中,CTRL-V似乎映射到paste而不是让我阻止视觉模式。我该怎么扭转这个?我非常确定我没有将vim配置为以这种方式运行,而且到目前为止,我只能在MS Windows中进行此操作。

修改:.vimrc

的内容
" 1. Pathogen (plugins autoloader)
execute pathogen#infect()
syntax on
filetype plugin indent on


" 2. Documentor
au BufRead,BufNewFile *.php inoremap <buffer> <C-P> :call PhpDoc()<CR>
au BufRead,BufNewFile *.php nnoremap <buffer> <C-P> :call PhpDoc()<CR>
au BufRead,BufNewFile *.php vnoremap <buffer> <C-P> :call PhpDocRange()<CR>

let g:pdv_cfg_Package = 'FPP Labs Package'
let g:pdv_cfg_Author = 'Gboyega Dada <gboyega@fpplabs.com>'
let g:pdv_cfg_ClassTags = ["package","author","version"]


" 3. Syntastic
set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*

let g:syntastic_always_populate_loc_list = 1
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 0


" 4. Tab stops
set tabstop=4
set shiftwidth=4
set expandtab

1 个答案:

答案 0 :(得分:5)

这不是一个真正的问题。

基本操作系统使用自己的终端,名为 Pantheon Terminal ,它使用CTRL + C / CTRL + V进行复制/粘贴。这可以防止将快捷方式传递给vim。

您应该将终端更改为其他应用程序,或在终端设置中更改此行为。

这里有一些博客,其中包含我刚发现的更多信息:

http://lmelinux.net/2014/12/06/ctrlc-will-copy-text-clipboard-elementarys-terminal/

您感兴趣的部分是:

  

初级开发人员也意识到有些人会对这种变化感到不满,这就是为什么在org.pantheon.terminal.natural-copy-paste中会有一个新的gsettings键,可以禁用这种行为。

相关问题