Re: [Vim-latex-devel] Vim-LaTeX problem with "
Brought to you by:
srinathava,
tmaas
From: Benji F. <be...@me...> - 2003-01-14 23:13:31
|
Mikolaj Machowski wrote: > On Tue, Jan 14, 2003 at 11:41:50AM -0500, Benji Fisher wrote: > >> That is the function that gets invoked when you type " . But you >>do not have to worry about that: the rest of us can handle the >>implementation. What I need to know is how to tell whether to use >>English or German quotes. Is there a \documentclass option or a >>\usepackage line that you use to tell TeX that you are writing in >>German? I think there must be something like this, because TeX uses >>different hyphenation patterns for different languages. > > > Oops. I did not understand (post about v:lang). > For Polish it will be package polski and: > opening quotes: ,, > closing quotes: '' > > Names of detected packages are stored in g:Tex_package_detected. But > this variable is created by packages.vim which is sourced at the end of > main.vim. > > Mikolaj That is good: it is quite possible that a user will edit two files, one in Polish and the other in German, during the same session. When the user types ", it triggers the s:TexQuotes() function. This function can extract matchstr(g:Tex_package_detected, 'german\|polski\|french') and then use g:Tex_SmartQuoteOpen_{lang} if it exists, and otherwise use the current default. I'll try to implement this tomorrow. --Benji |