Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are the necessary plugins in VIM for Latex? [closed]

Tags:

vim

latex

What are your favourite plugins in VIM for Latex editing? Is there some ready variant of VIM for Latex?

like image 679
Léo Léopold Hertz 준영 Avatar asked Feb 12 '09 15:02

Léo Léopold Hertz 준영


1 Answers

Actually, I think the default support that Vim includes for filetype=tex is already quite good. So strictly, no plugins are necessary.

However, I do recommend a few settings that you can cherry-pick from and adapt to your own taste. See the help to see what each command/setting does.

setlocal iskeyword+=:,-
setlocal makeprg=pdflatex\ -file-line-error\ -interaction=nonstopmode\ %

inoremap <buffer> { {}<ESC>i
inoremap <buffer> [ []<ESC>i

iab <buffer> ,b \begin{
iab <buffer> ,e \end{
" More abbreviations...

You can put these in ~/.vim/ftplugin/tex.vim to load them for every tex file. The following are some global settings that I keep in ~/.vimrc:

let g:tex_flavor = "latex"
set suffixes+=.log,.aux,.bbl,.blg,.idx,.ilg,.ind,.out,.pdf
like image 109
Bruno De Fraine Avatar answered Oct 22 '22 17:10

Bruno De Fraine