gimp/app/widgets/gimpmenudock.h
Michael Natterer b879840890 g_strdup() the stock_id passed to gimp_tool_info_new() because the
2002-03-14  Michael Natterer  <mitch@gimp.org>

	* app/core/gimptoolinfo.c: g_strdup() the stock_id passed to
	gimp_tool_info_new() because the caller's memory may disappear
	after registering the tool (tool modules).

	Made a GimpDock out of the toolbox:

	* app/gui/Makefile.am
	* app/gui/color-area.[ch]
	* app/gui/indicator-area.[ch]
	* app/gui/toolbox.[ch]: removed...

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimptoolbox-color-area.[ch]
	* app/widgets/gimptoolbox-indicator-area.[ch]
	* app/widgets/gimptoolbox.[ch]: ...and added here.

	* app/widgets/gimpdock.[ch]: don't set a minimal width. Added a
	"destroy_if_empty" boolean so we can prevent destruction of the
	toolbox if it's last dockable is removed. Added gimp_dock_construct()
	which is called from GimpImageDock and GimpToolbox.

	* app/widgets/gimpimagedock.[ch]: Default to not showing the image
	menu, set a minimal width here, misc. minor cleanup.

	* app/widgets/gimpdockbook.c: some more GIMP_IS_IMAGE_DOCK()
	checks, fixed dnd widget creation.

	* app/widgets/gimpdialogfactory.[ch]: changed
	gimp_dialog_factories_toggle() to take just the toolbox_factory as
	parameter. When restoring the session use the created dock's
	dialog factory to create dockables, not the the factory we
	created the dock from (for the toolbox).

	* app/display/gimpdisplayshell-callbacks.c: changed accordingly.

	* app/gui/dialogs.[ch]: create an own dialog factory for the toolbox
	and set dialogs_toolbox_new() as it's new_dock_func.

	* app/gui/dialogs-constructors.[ch]: changed dialogs_toolbox_get()
	accordingly.

	* app/gui/dialogs-commands.[ch]: added dialogs_show_toolbox(), ckeck
	if a dock is really a GimpImageDock before casting.

	* app/gui/gui.c
	* app/gui/menus.c
	* app/widgets/gimppaletteeditor.c: changed accordingly.

	* app/gui/color-notebook.c
	* app/gui/color-select.c
	* app/gui/colormap-dialog.c
	* app/gui/palette-editor-commands.c: removed useless inclusion of
	"gui/color-area.h".

	* themes/Default/gtkrc: set "gimp-dock-style" for GimpToolbox widgets.
2002-03-14 17:07:02 +00:00

71 lines
2.4 KiB
C

/* The GIMP -- an image manipulation program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* gimpimagedock.h
* Copyright (C) 2001 Michael Natterer <mitch@gimp.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __GIMP_IMAGE_DOCK_H__
#define __GIMP_IMAGE_DOCK_H__
#include "gimpdock.h"
#define GIMP_TYPE_IMAGE_DOCK (gimp_image_dock_get_type ())
#define GIMP_IMAGE_DOCK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GIMP_TYPE_IMAGE_DOCK, GimpImageDock))
#define GIMP_IMAGE_DOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GIMP_TYPE_IMAGE_DOCK, GimpImageDockClass))
#define GIMP_IS_IMAGE_DOCK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GIMP_TYPE_IMAGE_DOCK))
#define GIMP_IS_IMAGE_DOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GIMP_TYPE_IMAGE_DOCK))
#define GIMP_IMAGE_DOCK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GIMP_TYPE_IMAGE_DOCK, GimpImageDockClass))
typedef struct _GimpImageDockClass GimpImageDockClass;
struct _GimpImageDock
{
GimpDock parent_instance;
GimpContainer *image_container;
gboolean show_image_menu;
gboolean auto_follow_active;
GtkWidget *option_menu;
GtkWidget *menu;
GtkWidget *auto_button;
};
struct _GimpImageDockClass
{
GimpDockClass parent_class;
};
GType gimp_image_dock_get_type (void) G_GNUC_CONST;
GtkWidget * gimp_image_dock_new (GimpDialogFactory *dialog_factory,
GimpContainer *image_container);
void gimp_image_dock_set_auto_follow_active (GimpImageDock *image_dock,
gboolean show);
void gimp_image_dock_set_show_image_menu (GimpImageDock *image_dock,
gboolean show);
#endif /* __GIMP_IMAGE_DOCK_H__ */