diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2010-01-02 17:27:44 +0100 |
---|---|---|
committer | Tobias Klauser <tklauser@distanz.ch> | 2010-01-02 17:27:44 +0100 |
commit | 85b5baef260e770966cdc873a4e8eab05d935b64 (patch) | |
tree | ce4a1bb58100ad1a6307db08b40a94aa16797478 /.vim/ftplugin/latex.vim |
Initial commit of vim config
Diffstat (limited to '.vim/ftplugin/latex.vim')
-rw-r--r-- | .vim/ftplugin/latex.vim | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/.vim/ftplugin/latex.vim b/.vim/ftplugin/latex.vim new file mode 100644 index 0000000..a218cc7 --- /dev/null +++ b/.vim/ftplugin/latex.vim @@ -0,0 +1,24 @@ +" some general options + set ai " autoindent + set et " expandtab + set ts=2 " tabstop + set tw=85 " textwidth + +" compile tex-files with latex + set makeprg=latex\ % + +" Inserting pairs of quotes: + imap Y" ``''<Left><Left> + +" Some mappings for often used commands + iab ,b \begin{}<Esc>i + iab ,e \end{}<Esc>i + +" A mapping for more effective use of latex compiling + map <F7> : call CompileRunPDF()<CR> + func! CompileRunPDF() + exec "w" + exec "!latex % && dvipdf %<.dvi && xpdf %<.pdf" + exec "i" + endfunc + |