当我在Vim上编辑一个TeX文件时,插入模式下的回拨(TeX)工作方式很奇怪。我希望当我键入`a Vim显示`a时,当我键入`b时它会显示`b,等等。但是,实际上,当我键入`a时,它只显示a,当我键入`b时,它只显示b。此外,例如,当我键入`j时,它会显示`j,正如我所期望的那样。在反勾后面的一些字母将以反勾(如我所料)显示,而其他没有回勾(奇怪的行为)。下面的列表显示哪些字母跟随反勾号,哪些字母替换了反勾。
下面是
// `j becomes `j
j o v B C H I J K M
N O R T V Z 1 2 3 4
5 7 9 ! @ # $ % ^ &
- _ + | ~ { } ; : '
" , / ?
Space(0x20)替换
// `a becomes a
a b c d e f g h i k
l m n p q r s t u w
x y z A D E F G L P
Q S U W X Y 6 8 0 *
( ) = \ ` [ ] . < >只有在编辑TeX文件并处于插入模式时,才会出现此行为。在正常模式下,我跳到标记位置,在Markdown上,我的Vim显示一定数量的后背。
为什么它会以这样的方式起作用,我该怎么做才能让它以某种方式起作用呢?
我的虚拟世界:
if 0 | endif
if has('vim_starting')
if &compatible
set nocompatible
endif
set runtimepath+=~/.vim/bundle/neobundle.vim/
endif
call neobundle#begin(expand('~/.vim/bundle/'))
NeoBundleFetch 'Shougo/neobundle.vim'
NeoBundle 'thinca/vim-quickrun'
NeoBundle 'Shougo/vimproc',{
\'build' : {
\ 'windows' : 'make -f make_mingw32.mak',
\ 'cygwin' : 'make -f make_cygwin.mak',
\ 'mac' : 'make -f make_mac.mak',
\ 'unix' : 'make -f make_unix.mak',
\ },
\ }
NeoBundle 'Shougo/unite.vim'
NeoBundle 'osyo-manga/unite-quickfix'
NeoBundle 'osyo-manga/shabadou.vim'
NeoBundle 'lervag/vimtex'
NeoBundle 'Shougo/neosnippet'
NeoBundle 'Shougo/neocomplete'
NeoBundle 'Shougo/neosnippet-snippets'
NeoBundle 'nelstrom/vim-visual-star-search'
NeoBundle 'tpope/vim-fugitive'
NeoBundle 'vim-ruby/vim-ruby'
NeoBundle 'tpope/vim-endwise'
NeoBundle 'plasticboy/vim-markdown'
NeoBundle 'kannokanno/previm'
NeoBundle 'tyru/open-browser.vim'
NeoBundle 'derekwyatt/vim-scala'
NeoBundle 'scrooloose/nerdtree'
call neobundle#end()
filetype plugin indent on
NeoBundleCheck
syntax on
set spelllang=en,cjk
set spell
set expandtab
set shiftwidth=2
set softtabstop=2
set autoindent
set smartindent
set pumheight=10
set showmatch
set matchtime=1
set wrap
set ignorecase
set smartcase
set scrolloff=3
set ruler
set display=lastline
set cole=0
set backspace=indent,eol,start
au FileType * setl cole=0
nnoremap j gj
nnoremap k gk
nnoremap <Down> gj
nnoremap <Up> gk
nnoremap gj j
nnoremap gk k
nnoremap <silent><C-l> <C-w>l
nnoremap <silent><C-h> <C-w>h
nnoremap <silent><C-k> <C-w>k
nnoremap <silent><C-j> <C-w>j
nnoremap <silent><C-e> :NERDTreeToggle<CR>
nnoremap <Space>h ^
nnoremap <Space>l $
inoremap <C-j> <BS>
cnoremap <C-j> <BS>
imap <C-k> <Plug>(neosnippet_expand_or_jump)
smap <C-k> <Plug>(neosnippet_expand_or_jump)
xmap <C-k> <Plug>(neosnippet_expand_target)
imap <expr><TAB> neosnippet#expandable_or_jumpable() ?
\ "\<Plug>(neosnippet_expand_or_jump)"
\: pumvisible() ? "\<C-n>" : "\<TAB>"
smap <expr><TAB> neosnippet#expandable_or_jumpable() ?
\ "\<Plug>(neosnippet_expand_or_jump)"
\: "\<TAB>"
let g:tex_conceal = ''
let g:quickrun_config = {
\ 'split' : '',
\ 'runner' : 'vimproc',
\ 'runner/vimproc/updatetime' : 10,
\ 'tex' : {
\ 'command' : 'latexmk',
\ 'cmdopt' : '-pvc -pdfdvi',
\ 'exec' : ['%c %o %s']
\ },
\}发布于 2017-02-21 15:25:52
检查您的文件类型、语法、键映射。
:set ft? syn?
:imap
:map尝试禁用有向图:
:set nodigraph尝试删除可能在语法配置文件中定义的任何回勾映射:
:iunmap `https://stackoverflow.com/questions/42357716
复制相似问题