glade needs support for gmenu construction
@pborelli
Submitted by Paolo Borelli Link to original bug (#667970)
Description
(not sure if gmenu bugs should be filed against gtk or glib)
The new menu xml has some properties that make its use from gtkbuilder weird.
-
First (and most important) when you build objects with gtkbuilder you normally get specific instances of the object itself, menu is different since once you get the app_menu/menu_bar from the builder you set them on the app and then instances are created for each window of the app. This also translates to the fact that menus cannot have an "id" attribute, which is sometime a problem by itself (e.g. if I want to apply css by id to a specificic menu entry)
-
all other objects in builder file use the
<object>
tag, using a<menu>
tag is pretty much ad hoc, and using get_object() to get it is strange.
When I asked to desrt he said good practice is to put the menu definition in a separate file to be loaded with a different builder instance at a different time, so the question is: if we are using a completely different xml, we put in a separate file and we parse it at a different time, why do we abuse GtkBuilder?