Re: [Vim-latex-devel] Re: [Vim-latex-cvs] A little review...
Brought to you by:
srinathava,
tmaas
From: Srinath A. <sr...@fa...> - 2003-01-17 19:06:18
|
On Fri, 17 Jan 2003, Benji Fisher wrote: > I think this is going to be helpful in the long run. In the short > run, I am afraid that the whle system may be unstable for a while. I > would have started a new branch for this. > I am sorry I didn't start a branch... This thing just snowballed from what was supposed to be not too big a change... > We should document how the system works. Parts of your e-mail, > quoted above, can serve as a draft. See > > :help syntax-loading > > for one model. > Yup... That looks good... > You did not (yet) take my suggestion about packages/german-babel > and so on. Is this because you did not like the idea, or just because > you had a lot of other things on your mind? Again, the point is that > packages/german does nothing more than set smart-quote options, but (1) > this may change and (2) polski already does much more. > I just had too many things on my mind... Please go ahead and change things as needed. Note however that there does need to exist a babel package because packages/polski is never going to be used if \usepackage{polski} is not detected. Did you have something else in mind? Maybe instead of just defining all these dummy package files, just make a function Tex_SetLanguageSettings() and an au which calls this on the LatexSuitePackagesScanned event? Maybe as in vim, put this in a packages/allpackage.vim file which gets sourced once when latex-suite starts? > If you have already declared > > :augroup LatexSuite > > then you do not have to include LatexSuite (the augroup) in the :au > lines. I find it easier to read without this repetition. Do you > disagree, or were you just following the cvs plugin model? > I was just following the cvscommand model... The way you suggests looks better because User is highlighted too... > If "ngerman" is given as an option to the babel package, then the > "german" package will be :source'd. This will work fine. Do we want it > to work this way in general? I think there are (at least) two versions > of french; can they also be treated the same way? I would rather parse > g:Tex_babel_options and, for each option given (Is it legal to give more > than one?) :source the appropriate file if it exists. > Yes... The present packages/babel is just a prototype for the general event handling mechanism... I haven't actually invested time in the actual options setting part of it... I would be glad if someone with knowledge of the babel package could take over... > What is the format of the g:Tex_package_detected and > g:Tex_{pack}_options variables? If it is something like "pack1,pack2", > then it is pretty easy to parse; in particular, your match with > '\<babel\>' should work reliably. > Yes. g:Tex_package_detected is guarenteeed to be of the form 'pack1,pack2' g:Tex_{pack}_options is however just yanked from between the [ ]'s of the \usepackage[options]{pack}. Since latex is quite a bit more forgiving about commas, we cannot guarantee a fixed sytnax here. Srinath |