Well, I tracked down _why_ the menubar in XEmacs/GTK is flickering so much
when using 'speedbar' or 'grep'. Basically, the variable current-menubar
is both buffer-local and magic. Its magic function calls
MARK_MENUBAR_CHANGED, which causes the menubar to get reconstructed. No
problem in and of itself, but when calling set-buffer, this causes the
buffer-local variables to be evaluated, which nukes the menubar, etc.
I don't think that the menubar should be invalidated just because of
set-buffer, because it isn't supposed to change the buffer for more than
the current command.
But menubar_variable_changed() in menubar.c does not / cannot know whether
the change is permanent or temporary.
I couldn't find any place in lwlib where it tries to be smart about this
type of thing, so either I am missing something or it is gobs faster than
the GTK menubar widget at updating itself.
Can anyone think of a way around this? The flicker is horrendous with
speedbar.
-Bill P.