Commit 0b8c4b3e authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer
Browse files

app/widgets/Makefile.am app/widgets/widgets-types.h new GtkUIManager

2004-04-21  Michael Natterer  <mitch@gimp.org>

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpuimanager.[ch]: new GtkUIManager subclass. Adds
	API to update all action groups and knows which UIs it can create
	from which XML files.

	* app/widgets/gimpmenufactory.[ch]: register the XML file
	basenames along with path of their toplevel menus. Create
	GimpUIManagers instead of GtkUIManagers and register the
	XML files and menu paths with them.

	* app/gui/menus.c: register all XML files and their toplevel
	menu paths.

	* app/widgets/gimpeditor.[ch]: also create a GimpUIManager when
	creating the GtkItemFactory. Added "const gchar *ui_identifier"
	parameter to gimp_editor_create_menu().

	* app/widgets/gimpcontainereditor.[ch]
	* app/widgets/gimpdataeditor.[ch]
	* app/widgets/gimpdatafactoryview.[ch]
	* app/widgets/gimpitemtreeview.[ch]: added "ui_identifier"
	parameters to all constructors.

	* app/widgets/gimpbrusheditor.c
	* app/widgets/gimpbrushfactoryview.c
	* app/widgets/gimpbufferview.c
	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcomponenteditor.c
	* app/widgets/gimpcontainerpopup.c
	* app/widgets/gimpdocumentview.c
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimpfontview.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpimageview.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimppatternfactoryview.c
	* app/widgets/gimptemplateview.c
	* app/widgets/gimptooloptionseditor.c
	* app/gui/dialogs-constructors.c
	* app/gui/gradient-select.c
	* app/gui/palette-select.c
	* app/gui/pattern-select.c: pass UI identifiers to the changed
	functions above.

	* app/display/gimpdisplayshell.[ch]: added a GimpUIManager for
	the menubar (menubar creating code still commented out).

	* app/display/gimpdisplay.c
	* app/gui/gui-vtable.c: update the ui manager.
parent 2c601c7d
2004-04-21 Michael Natterer <mitch@gimp.org>
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimpuimanager.[ch]: new GtkUIManager subclass. Adds
API to update all action groups and knows which UIs it can create
from which XML files.
* app/widgets/gimpmenufactory.[ch]: register the XML file
basenames along with path of their toplevel menus. Create
GimpUIManagers instead of GtkUIManagers and register the
XML files and menu paths with them.
* app/gui/menus.c: register all XML files and their toplevel
menu paths.
* app/widgets/gimpeditor.[ch]: also create a GimpUIManager when
creating the GtkItemFactory. Added "const gchar *ui_identifier"
parameter to gimp_editor_create_menu().
* app/widgets/gimpcontainereditor.[ch]
* app/widgets/gimpdataeditor.[ch]
* app/widgets/gimpdatafactoryview.[ch]
* app/widgets/gimpitemtreeview.[ch]: added "ui_identifier"
parameters to all constructors.
* app/widgets/gimpbrusheditor.c
* app/widgets/gimpbrushfactoryview.c
* app/widgets/gimpbufferview.c
* app/widgets/gimpcolormapeditor.c
* app/widgets/gimpcomponenteditor.c
* app/widgets/gimpcontainerpopup.c
* app/widgets/gimpdocumentview.c
* app/widgets/gimperrorconsole.c
* app/widgets/gimpfontview.c
* app/widgets/gimpgradienteditor.c
* app/widgets/gimpimageview.c
* app/widgets/gimppaletteeditor.c
* app/widgets/gimppatternfactoryview.c
* app/widgets/gimptemplateview.c
* app/widgets/gimptooloptionseditor.c
* app/gui/dialogs-constructors.c
* app/gui/gradient-select.c
* app/gui/palette-select.c
* app/gui/pattern-select.c: pass UI identifiers to the changed
functions above.
* app/display/gimpdisplayshell.[ch]: added a GimpUIManager for
the menubar (menubar creating code still commented out).
* app/display/gimpdisplay.c
* app/gui/gui-vtable.c: update the ui manager.
2004-04-21 Michael Natterer <mitch@gimp.org>
* app/actions/actions.c: forgot to register the "patterns" actions.
......
......@@ -32,6 +32,7 @@
#include "core/gimplist.h"
#include "widgets/gimpitemfactory.h"
#include "widgets/gimpuimanager.h"
#include "tools/gimptool.h"
#include "tools/tool_manager.h"
......@@ -511,6 +512,7 @@ gimp_display_flush_whenever (GimpDisplay *gdisp,
GimpContext *user_context;
gimp_item_factory_update (shell->menubar_factory, shell);
gimp_ui_manager_update (shell->menubar_manager, shell);
user_context = gimp_get_user_context (gdisp->gimage->gimp);
......
......@@ -314,7 +314,8 @@ dialogs_gradient_list_view_new (GimpDialogFactory *factory,
dialogs_edit_gradient_func,
context,
preview_size, 1,
factory->menu_factory, "<Gradients>");
factory->menu_factory, "<Gradients>",
"/gradients-popup");
return dialogs_dockable_new (view,
_("Gradients"), NULL,
......@@ -334,7 +335,8 @@ dialogs_palette_list_view_new (GimpDialogFactory *factory,
dialogs_edit_palette_func,
context,
preview_size, 1,
factory->menu_factory, "<Palettes>");
factory->menu_factory, "<Palettes>",
"/palettes-popup");
return dialogs_dockable_new (view,
_("Palettes"), NULL,
......@@ -521,7 +523,8 @@ dialogs_gradient_grid_view_new (GimpDialogFactory *factory,
dialogs_edit_gradient_func,
context,
preview_size, 1,
factory->menu_factory, "<Gradients>");
factory->menu_factory, "<Gradients>",
"/gradients-popup");
return dialogs_dockable_new (view,
_("Gradients"), NULL,
......@@ -541,7 +544,8 @@ dialogs_palette_grid_view_new (GimpDialogFactory *factory,
dialogs_edit_palette_func,
context,
preview_size, 1,
factory->menu_factory, "<Palettes>");
factory->menu_factory, "<Palettes>",
"/palettes-popup");
return dialogs_dockable_new (view,
_("Palettes"), NULL,
......@@ -647,7 +651,8 @@ dialogs_layer_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) layers_edit_layer_query,
(GimpNewItemFunc) layers_new_layer_query,
(GimpActivateItemFunc) layers_text_tool,
factory->menu_factory, "<Layers>");
factory->menu_factory, "<Layers>",
"/layers-popup");
dockable = dialogs_dockable_new (view,
_("Layers"), NULL,
......@@ -678,7 +683,8 @@ dialogs_channel_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) channels_edit_channel_query,
(GimpNewItemFunc) channels_new_channel_query,
(GimpActivateItemFunc) channels_edit_channel_query,
factory->menu_factory, "<Channels>");
factory->menu_factory, "<Channels>",
"/channels-popup");
dockable = dialogs_dockable_new (view,
_("Channels"), NULL,
......@@ -710,7 +716,8 @@ dialogs_vectors_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) vectors_edit_vectors_query,
(GimpNewItemFunc) vectors_new_vectors_query,
(GimpActivateItemFunc) vectors_vectors_tool,
factory->menu_factory, "<Vectors>");
factory->menu_factory, "<Vectors>",
"/vectors-popup");
vectors_view = GIMP_VECTORS_TREE_VIEW (view);
......
......@@ -32,6 +32,7 @@
#include "core/gimplist.h"
#include "widgets/gimpitemfactory.h"
#include "widgets/gimpuimanager.h"
#include "tools/gimptool.h"
#include "tools/tool_manager.h"
......@@ -511,6 +512,7 @@ gimp_display_flush_whenever (GimpDisplay *gdisp,
GimpContext *user_context;
gimp_item_factory_update (shell->menubar_factory, shell);
gimp_ui_manager_update (shell->menubar_manager, shell);
user_context = gimp_get_user_context (gdisp->gimage->gimp);
......
......@@ -59,6 +59,7 @@
#include "widgets/gimphelp-ids.h"
#include "widgets/gimpitemfactory.h"
#include "widgets/gimpmenufactory.h"
#include "widgets/gimpuimanager.h"
#include "widgets/gimpwidgets-utils.h"
#include "gui/info-window.h"
......@@ -207,6 +208,7 @@ gimp_display_shell_init (GimpDisplayShell *shell)
{
shell->gdisp = NULL;
shell->menubar_factory = NULL;
shell->menubar_manager = NULL;
shell->popup_factory = NULL;
shell->qmask_factory = NULL;
......@@ -374,6 +376,12 @@ gimp_display_shell_destroy (GtkObject *object)
shell->menubar_factory = NULL;
}
if (shell->menubar_manager)
{
g_object_unref (shell->menubar_manager);
shell->menubar_manager = NULL;
}
shell->popup_factory = NULL;
if (shell->qmask_factory)
......@@ -478,6 +486,7 @@ gimp_display_shell_real_scaled (GimpDisplayShell *shell)
/* update the <Image>/View/Zoom menu */
gimp_item_factory_update (shell->menubar_factory, shell);
gimp_ui_manager_update (shell->menubar_manager, shell);
user_context = gimp_get_user_context (shell->gdisp->gimage->gimp);
......@@ -594,6 +603,10 @@ gimp_display_shell_new (GimpDisplay *gdisp,
GTK_TYPE_MENU_BAR,
gdisp,
FALSE);
shell->menubar_manager = gimp_menu_factory_manager_new (menu_factory,
"<Image>",
gdisp,
FALSE);
shell->popup_factory = popup_factory;
......@@ -603,6 +616,7 @@ gimp_display_shell_new (GimpDisplay *gdisp,
shell,
FALSE);
/* The accelerator table for images */
gtk_window_add_accel_group (GTK_WINDOW (shell),
GTK_ITEM_FACTORY (shell->menubar_factory)->accel_group);
......@@ -658,6 +672,13 @@ gimp_display_shell_new (GimpDisplay *gdisp,
if (shell->options->show_menubar)
gtk_widget_show (menubar);
#if 0
menubar = gimp_ui_manager_ui_create (shell->menubar_manager,
"/image-menubar");
gtk_box_pack_start (GTK_BOX (main_vbox), menubar, FALSE, FALSE, 0);
gtk_widget_show (menubar);
#endif
/* make sure we can activate accels even if the menubar is invisible
* (see http://bugzilla.gnome.org/show_bug.cgi?id=137151)
*/
......
......@@ -71,6 +71,8 @@ struct _GimpDisplayShell
GimpDisplay *gdisp;
GimpItemFactory *menubar_factory;
GimpUIManager *menubar_manager;
GimpItemFactory *popup_factory;
GimpItemFactory *qmask_factory;
......
......@@ -314,7 +314,8 @@ dialogs_gradient_list_view_new (GimpDialogFactory *factory,
dialogs_edit_gradient_func,
context,
preview_size, 1,
factory->menu_factory, "<Gradients>");
factory->menu_factory, "<Gradients>",
"/gradients-popup");
return dialogs_dockable_new (view,
_("Gradients"), NULL,
......@@ -334,7 +335,8 @@ dialogs_palette_list_view_new (GimpDialogFactory *factory,
dialogs_edit_palette_func,
context,
preview_size, 1,
factory->menu_factory, "<Palettes>");
factory->menu_factory, "<Palettes>",
"/palettes-popup");
return dialogs_dockable_new (view,
_("Palettes"), NULL,
......@@ -521,7 +523,8 @@ dialogs_gradient_grid_view_new (GimpDialogFactory *factory,
dialogs_edit_gradient_func,
context,
preview_size, 1,
factory->menu_factory, "<Gradients>");
factory->menu_factory, "<Gradients>",
"/gradients-popup");
return dialogs_dockable_new (view,
_("Gradients"), NULL,
......@@ -541,7 +544,8 @@ dialogs_palette_grid_view_new (GimpDialogFactory *factory,
dialogs_edit_palette_func,
context,
preview_size, 1,
factory->menu_factory, "<Palettes>");
factory->menu_factory, "<Palettes>",
"/palettes-popup");
return dialogs_dockable_new (view,
_("Palettes"), NULL,
......@@ -647,7 +651,8 @@ dialogs_layer_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) layers_edit_layer_query,
(GimpNewItemFunc) layers_new_layer_query,
(GimpActivateItemFunc) layers_text_tool,
factory->menu_factory, "<Layers>");
factory->menu_factory, "<Layers>",
"/layers-popup");
dockable = dialogs_dockable_new (view,
_("Layers"), NULL,
......@@ -678,7 +683,8 @@ dialogs_channel_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) channels_edit_channel_query,
(GimpNewItemFunc) channels_new_channel_query,
(GimpActivateItemFunc) channels_edit_channel_query,
factory->menu_factory, "<Channels>");
factory->menu_factory, "<Channels>",
"/channels-popup");
dockable = dialogs_dockable_new (view,
_("Channels"), NULL,
......@@ -710,7 +716,8 @@ dialogs_vectors_list_view_new (GimpDialogFactory *factory,
(GimpEditItemFunc) vectors_edit_vectors_query,
(GimpNewItemFunc) vectors_new_vectors_query,
(GimpActivateItemFunc) vectors_vectors_tool,
factory->menu_factory, "<Vectors>");
factory->menu_factory, "<Vectors>",
"/vectors-popup");
vectors_view = GIMP_VECTORS_TREE_VIEW (view);
......
......@@ -137,7 +137,8 @@ gradient_select_new (Gimp *gimp,
dialogs_edit_gradient_func,
gsp->context,
GIMP_PREVIEW_SIZE_MEDIUM, 1,
global_menu_factory, "<Gradients>");
global_menu_factory, "<Gradients>",
"/gradients-popup");
gimp_container_view_set_size_request (GIMP_CONTAINER_VIEW (GIMP_CONTAINER_EDITOR (gsp->view)->view),
6 * (GIMP_PREVIEW_SIZE_MEDIUM + 2),
......
......@@ -33,6 +33,7 @@
#include "widgets/gimpdialogfactory.h"
#include "widgets/gimperrorconsole.h"
#include "widgets/gimpitemfactory.h"
#include "widgets/gimpuimanager.h"
#include "widgets/gimpwidgets-utils.h"
#include "display/gimpdisplay.h"
......@@ -199,6 +200,7 @@ gui_display_new (GimpImage *gimage,
gimp_context_set_display (gimp_get_user_context (gimage->gimp), gdisp);
gimp_item_factory_update (shell->menubar_factory, shell);
gimp_ui_manager_update (shell->menubar_manager, shell);
return GIMP_OBJECT (gdisp);
}
......
......@@ -127,9 +127,22 @@ menus_init (Gimp *gimp)
n_image_menu_entries,
image_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Image>",
"file", "edit", "select", "view",
"image", "drawable", "layers", "vectors",
"tools", "dialogs", "plug-in", NULL);
"file",
"edit",
"select",
"view",
"image",
"drawable",
"layers",
"vectors",
"tools",
"dialogs",
"plug-in",
NULL,
"/toolbox-menubar", "toolbox-menu.xml",
"/image-menubar", "image-menu.xml",
"/qmask-popup", "qmask-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Load>",
_("Open Menu"),
......@@ -152,6 +165,11 @@ menus_init (Gimp *gimp)
NULL, layers_menu_update, TRUE,
n_layers_menu_entries,
layers_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Layers>",
"layers",
NULL,
"/layers-popup", "layers-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Channels>",
_("Channels Menu"),
......@@ -159,6 +177,11 @@ menus_init (Gimp *gimp)
NULL, channels_menu_update, TRUE,
n_channels_menu_entries,
channels_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Channels>",
"channels",
NULL,
"/channels-popup", "channels-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Vectors>",
_("Paths Menu"),
......@@ -166,6 +189,11 @@ menus_init (Gimp *gimp)
NULL, vectors_menu_update, TRUE,
n_vectors_menu_entries,
vectors_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Vectors>",
"vectors",
NULL,
"/vectors-popup", "vectors-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Dialogs>",
_("Dialogs Menu"),
......@@ -173,6 +201,11 @@ menus_init (Gimp *gimp)
NULL, dialogs_menu_update, TRUE,
n_dialogs_menu_entries,
dialogs_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Dialogs>",
"dockable",
NULL,
"/dockable-popup", "dockable-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Brushes>",
_("Brushes Menu"),
......@@ -180,6 +213,11 @@ menus_init (Gimp *gimp)
NULL, brushes_menu_update, TRUE,
n_brushes_menu_entries,
brushes_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Brushes>",
"brushes",
NULL,
"/brushes-popup", "brushes-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Patterns>",
_("Patterns Menu"),
......@@ -187,6 +225,11 @@ menus_init (Gimp *gimp)
NULL, patterns_menu_update, TRUE,
n_patterns_menu_entries,
patterns_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Patterns>",
"patterns",
NULL,
"/patterns-popup", "patterns-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Gradients>",
_("Gradients Menu"),
......@@ -194,6 +237,11 @@ menus_init (Gimp *gimp)
NULL, gradients_menu_update, TRUE,
n_gradients_menu_entries,
gradients_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Gradients>",
"gradients",
NULL,
"/gradients-popup", "gradients-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Palettes>",
_("Palettes Menu"),
......@@ -201,6 +249,11 @@ menus_init (Gimp *gimp)
NULL, palettes_menu_update, TRUE,
n_palettes_menu_entries,
palettes_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Palettes>",
"palettes",
NULL,
"/palettes-popup", "palettes-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Fonts>",
_("Fonts Menu"),
......@@ -208,6 +261,11 @@ menus_init (Gimp *gimp)
NULL, fonts_menu_update, TRUE,
n_fonts_menu_entries,
fonts_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Fonts>",
"fonts",
NULL,
"/fonts-popup", "fonts-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Buffers>",
_("Buffers Menu"),
......@@ -215,6 +273,11 @@ menus_init (Gimp *gimp)
NULL, buffers_menu_update, TRUE,
n_buffers_menu_entries,
buffers_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Buffers>",
"buffers",
NULL,
"/buffers-popup", "buffers-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Documents>",
_("Documents Menu"),
......@@ -222,6 +285,11 @@ menus_init (Gimp *gimp)
NULL, documents_menu_update, TRUE,
n_documents_menu_entries,
documents_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Documents>",
"documents",
NULL,
"/documents-popup", "documents-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Templates>",
_("Templates Menu"),
......@@ -229,6 +297,11 @@ menus_init (Gimp *gimp)
NULL, templates_menu_update, TRUE,
n_templates_menu_entries,
templates_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Templates>",
"templates",
NULL,
"/templates-popup", "templates-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Images>",
_("Images Menu"),
......@@ -236,6 +309,11 @@ menus_init (Gimp *gimp)
NULL, images_menu_update, TRUE,
n_images_menu_entries,
images_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Images>",
"images",
NULL,
"/images-popup", "images-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<GradientEditor>",
_("Gradient Editor Menu"),
......@@ -243,6 +321,12 @@ menus_init (Gimp *gimp)
NULL, gradient_editor_menu_update, TRUE,
n_gradient_editor_menu_entries,
gradient_editor_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<GradientEditor>",
"gradient-editor",
NULL,
"/gradient-editor-popup",
"gradient-editor-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<PaletteEditor>",
_("Palette Editor Menu"),
......@@ -250,6 +334,12 @@ menus_init (Gimp *gimp)
NULL, palette_editor_menu_update, TRUE,
n_palette_editor_menu_entries,
palette_editor_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<PaletteEditor>",
"pelette-editor",
NULL,
"/palette-editor-popup",
"palette-editor-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<ColormapEditor>",
_("Indexed Palette Menu"),
......@@ -257,6 +347,12 @@ menus_init (Gimp *gimp)
NULL, colormap_editor_menu_update, TRUE,
n_colormap_editor_menu_entries,
colormap_editor_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<ColormapEditor>",
"colormap-editor",
NULL,
"/colormap-editor-popup",
"colormap-editor-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<QMask>",
_("QuickMask Menu"),
......@@ -264,6 +360,12 @@ menus_init (Gimp *gimp)
NULL, qmask_menu_update, TRUE,
n_qmask_menu_entries,
qmask_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<QMask>",
"qmask",
NULL,
"/qmask-popup",
"qmask-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<ErrorConsole>",
_("Error Console Menu"),
......@@ -271,6 +373,12 @@ menus_init (Gimp *gimp)
NULL, error_console_menu_update, TRUE,
n_error_console_menu_entries,
error_console_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<ErrorConsole>",
"error-console",
NULL,
"/error-console-popup",
"error-console-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<ToolOptions>",
_("Tool Options Menu"),
......@@ -279,6 +387,12 @@ menus_init (Gimp *gimp)
tool_options_menu_update, TRUE,
n_tool_options_menu_entries,
tool_options_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<ToolOptions>",
"tool-options",
NULL,
"/tool-options-popup",
"tool-options-menu.xml",
NULL);
}
void
......
......@@ -139,7 +139,8 @@ palette_select_new (Gimp *gimp,
dialogs_edit_palette_func,
psp->context,
GIMP_PREVIEW_SIZE_MEDIUM, 1,
global_menu_factory, "<Palettes>");
global_menu_factory, "<Palettes>",
"/palettes-popup");
gimp_container_view_set_size_request (GIMP_CONTAINER_VIEW (GIMP_CONTAINER_EDITOR (psp->view)->view),
5 * (GIMP_PREVIEW_SIZE_MEDIUM + 2),
......
......@@ -135,7 +135,8 @@ pattern_select_new (Gimp *gimp,
NULL,
psp->context,
GIMP_PREVIEW_SIZE_MEDIUM, 1,
global_menu_factory, "<Patterns>");
global_menu_factory, "<Patterns>",
"/patterns-popup");
gimp_container_view_set_size_request (GIMP_CONTAINER_VIEW (GIMP_CONTAINER_EDITOR (psp->view)->view),
6 * (GIMP_PREVIEW_SIZE_MEDIUM + 2),
......
......@@ -127,9 +127,22 @@ menus_init (Gimp *gimp)
n_image_menu_entries,
image_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Image>",
"file", "edit", "select", "view",
"image", "drawable", "layers", "vectors",
"tools", "dialogs", "plug-in", NULL);
"file",
"edit",
"select",
"view",
"image",
"drawable",
"layers",
"vectors",
"tools",
"dialogs",
"plug-in",
NULL,
"/toolbox-menubar", "toolbox-menu.xml",
"/image-menubar", "image-menu.xml",
"/qmask-popup", "qmask-menu.xml",
NULL);
gimp_menu_factory_menu_register (global_menu_factory, "<Load>",
_("Open Menu"),
......@@ -152,6 +165,11 @@ menus_init (Gimp *gimp)
NULL, layers_menu_update, TRUE,
n_layers_menu_entries,
layers_menu_entries);
gimp_menu_factory_manager_register (global_menu_factory, "<Layers>",
"layers",
NULL,