--- Thomas Adam <[EMAIL PROTECTED]> wrote:
>
> --- Yakov Lerner <[EMAIL PROTECTED]> wrote:
>
> > How about using 'au BufLeave',
> > and placing the mirroring menu-deletion
> > commands under the 'au BufLeave' ?
> >
> > :au BufLeave *.ext ...menu-deletion-commands here...
>
> Thanks, but how do I do that for each buffer that might set menus
> irrespective of the filetype present? For instance, I might have any
> number
> of buffers with various extensions that set menus -- having to list them
> one
> by one might be tedious. Is there some generic means of telling a buffer
> to
> unassert and then reassert itself for the specific plugin it has loaded?
Replying to my own post here... I have had no luck in trialing this with just
vim-latex. I've tried the following for just one menu:
:au BufLeave *.tex aunmenu TeX-S&uite
... which (when I switched buffers), did indeed remove the menu. However,
upon issuing:
:au BufEnter *.tex amenu TeX-S&uite
... produced an error, as the menu obviously isn't there anymore. Do I have
to resource the appropriate plugin file for that type?
I still cannot see any generic way of getting a buffer with a known type
(that load plugins) to unload and reload themselves on demand in this way.
Am I having to hence (for each menu) unload them and reload them on demand?
That would create a very long list...
-- Thomas Adam
___________________________________________________________
Yahoo! Photos NEW, now offering a quality print service from just 7p a photo
http://uk.photos.yahoo.com