[Vim-latex-cvs] vimfiles/ftplugin/latex-suite/packages babel,NONE,1.1
Brought to you by:
srinathava,
tmaas
From: <sri...@us...> - 2003-01-17 10:05:39
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages In directory sc8-pr-cvs1:/tmp/cvs-serv16962 Added Files: babel Log Message: - A first go at the babel file. This file is sourced exactly once when it is first detected by Tex_pack_updateall(). It then sets up an au to catch the LatexSuiteScannedPackages event which gets thrown by Tex_pack_updateall(). This enables it to set buffer local smart quote characters each time \usepackage{babel} is seen. --- NEW FILE: babel --- " This package sets some language specific options. " Since it needs to find out which options the user used with the babel " package, it needs to wait till latex-suite is done scanning packages. It " then catches the LatexSuiteScannedPackages event which " Tex_pack_updateall() throws at which time g:Tex_pack_detected and " g:Tex_babel_options contain the necessary information. if exists('s:doneOnce') finish endif let s:doneOnce = 1 augroup LatexSuite au LatexSuite User LatexSuiteScannedPackages \ call Tex_Debug('babel: catching LatexSuiteScannedPackages event') | \ call s:SetQuotes() augroup END let s:path = expand('<sfile>:p:h') " SetQuotes: sets quotes for various languages {{{ " Description: function! <SID>SetQuotes() if g:Tex_package_detected =~ '\<babel\>' if g:Tex_babel_options =~ 'german' exec 'so '.s:path.'/german' endif endif endfunction " }}} " vim:ft=vim:ff=unix: |