google / vimdoc

Helpfile generation for vim
Apache License 2.0
291 stars 29 forks source link

Support per-buffer settings #58

Closed dbarnett closed 10 years ago

dbarnett commented 10 years ago

Vimdoc should be able to document buffer-local variables users can set to control plugin behavior on a buffer-by-buffer basis.

These per-buffer settings typically don't have a centrally-defined value with a let line. Usually they'll just be accessed via an exists('b:myplugin_somevar') or get(b:, 'myplugin_somevar', g:myplugin_somevar) somewhere in the code, so we'll probably need to support declaring them explicitly with a @setting NAME block directive that works like @function ... and @command ..., which will also be useful for #57.

We'll need to fix a few places throughout the code that assume "g:" scope, like whatever is adding the extra "g:" prefixes from #18.