Re: Integrating EggMenu code into GTK+



Hi,

I thought I'd go in and do the easy API docs, but they look mostly
done, except for GtkMenuMerge and there are only about 10 functions
there.

The real missing thing is just to transfer "howitshouldwork.txt" 
into overview documentation, I'd say.

I really like the API. It looks very nice, and to boot is much simpler
than past attempts at the same thing.

Random comments:

- why not make all the member variables private
  using the new GObject feature?
  (presumably because it was in libegg)

- should GtkMenuMergeNode be opaque?

- needs egtk-format-protos, lots of "foo(" vs. "foo (" stuff

- the various class structs could use padding functions

- what's the use case for gtk_menu_merge_ensure_update?

- weren't we unhappy with use of GSList for radio groups 
  for GtkRadioButton? Should we copy that for consistency 
  or do something nicer?

- agree with the comment in howitshouldwork.txt that GtkMenuMerge
  should have an "execute the following action" operation; this way
  you can programmatically support running a "copy" action or whatever

- if I wanted to make the Cut/Copy/Paste menu items affect the focused
  text widget, I assume each text widget would have an ActionGroup 
  and a UI XML string, and when focusing the text widget that 
  group and string would be merged. 

  Where do I get the GtkMenuMerge to merge into?

- should we deprecate the populate_popup hacks in the various
  widgets and instead use this; and how would that work?
  Would there be a separate GtkMenuMerge for each popup?
  gtk_text_view_get_popup_menu_merge()?

- do we replace gtk_im_multicontext_append_menuitems() 
  and _gtk_text_util_append_special_char_menuitems() 
  with some kind of get_action_group()/get_ui() calls?   

With the addition of an "app window" widget or dock widget, this would
certainly be nicer; right now, an app using this is going to have to
manually write the add_widget/remove_widget handlers it looks
like. That'll make the gtk-demo example look scarier than it ought to.

Havoc



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]