On Jul 3, 2008, at 3:40 AM, Maximilian Albert wrote:
These verbal descriptions will disappear as soon as I've figured out how to add a images to the dropdown box like in the fill/stroke dialog. I succeeded in adding the widget from that dialog to the toolbar, but it always appeared at the very end (I think even after the "style of new objects" swatch) -- as if it was put outside some inner hbox containing all the other widgets. Any ideas what that hbox would be and how to access it? What precisely does the 'holder' refer to anyway that is passed as an argument to all the toolbar prep functions?
What you need to do is have some subclass of GtkAction that will dynamically create your dropdown. Those are passed into the ui builder and at runtime they are called upon to make toolbar items or menu items as needed.
Look to the ege-select-one-action.h/cpp files and their use in widgets/toolbar.cpp