gimp/app/pdb/pdb_glue.h
Michael Natterer cdf2a90b03 app/core/Makefile.am app/core/core-types.h new base class for something
2002-02-25  Michael Natterer  <mitch@gimp.org>

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpitem.[ch]: new base class for something which is a
	child of an image, has a PDB ID, a tattoo, parasites and emits
	a "removed" signal.

	* app/core/gimpdrawable.[ch]
	* app/vectors/gimpvectors.[ch]: derive from GimpItem. Removed
	lots of stuff from GimpDrawable.

	* app/core/gimp.[ch]: changed gimp->drawable_table and
	gimp->next_drawable_ID to gimp->item_table and gimp->next_item_id.

	* app/undo.[ch]: s/undo_push_drawable_parasite/undo_push_item_parasite/,
	minor cleanups.

	* app/core/gimplayer.[ch]: changed gimp_layer_new_from_tiles() and
	gimp_layer_new_from_drawable() to take the "dest_gimage" as
	second, not first parameter.

	* app/image_map.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable-blend.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-histogram.c
	* app/core/gimpdrawable-offset.c
	* app/core/gimpdrawable-preview.c
	* app/core/gimpdrawable-transform.c
	* app/core/gimpedit.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-mask.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-pick-color.c
	* app/core/gimpimage.c
	* app/core/gimplayer-floating-sel.c
	* app/display/gimpdisplayshell-dnd.c
	* app/file/file-save.c
	* app/gui/channels-commands.c
	* app/gui/file-save-dialog.c
	* app/gui/layers-commands.c
	* app/gui/offset-dialog.c
	* app/gui/paths-dialog.c
	* app/gui/toolbox.c
	* app/paint/gimpairbrush.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimperaser.c
	* app/paint/gimppaintbrush.c
	* app/paint/gimppaintcore.c
	* app/paint/gimppencil.c
	* app/paint/gimpsmudge.c
	* app/plug-in/plug-in.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpinktool.c
	* app/tools/gimppainttool.c
	* app/xcf/xcf-load.c
	* app/xcf/xcf-save.c
	* app/widgets/gimpdrawablepreview.c: changed accordingly.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpitemlistview.[ch]: new widget implementing most
	of the stuff formerly done by GimpDrawableListView.

	* app/widgets/gimpchannellistview.c
	* app/widgets/gimpdrawablelistitem.c
	* app/widgets/gimpdrawablelistview.[ch]
	* app/widgets/gimplayerlistview.c: changed accordingly.

	* app/widgets/gimpdnd.[ch]: added a vectors DND type.

	* app/gui/menus.c
	* app/gui/dialogs.c
	* app/gui/dialogs-constructors.[ch]: added a vectors dialog and
	a vectors item_factory.

	* app/gui/Makefile.am
	* app/gui/vectors-commands.[ch]: new files implementing the
	callbacks for the new vectors dialog and item_factory.

	* app/pdb/pdb_glue.h: some more ugly hacks to keep intermediate
	perl code working...

	* tools/pdbgen/pdb.pl: added a vectors type, use GimpItem for all
	ID lookups.

	* tools/pdbgen/pdb/channel.pdb
	* tools/pdbgen/pdb/color.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/misc_tools.pdb
	* tools/pdbgen/pdb/parasite.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/selection_tools.pdb: misc changes according to
	stuff above.

	* app/pdb/channel_cmds.c
	* app/pdb/color_cmds.c
	* app/pdb/drawable_cmds.c
	* app/pdb/edit_cmds.c
	* app/pdb/floating_sel_cmds.c
	* app/pdb/image_cmds.c
	* app/pdb/layer_cmds.c
	* app/pdb/misc_tools_cmds.c
	* app/pdb/paint_tools_cmds.c
	* app/pdb/parasite_cmds.c
	* app/pdb/selection_cmds.c
	* app/pdb/selection_tools_cmds.c
	* app/pdb/text_tool_cmds.c
	* app/pdb/transform_tools_cmds.c: regenerated.
2002-02-25 17:58:50 +00:00

56 lines
2.9 KiB
C

/* The GIMP -- an image manipulation program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* 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 __PDB_GLUE_H__
#define __PDB_GLUE_H__
#define gimp_drawable_layer GIMP_IS_LAYER
#define gimp_drawable_layer_mask GIMP_IS_LAYER_MASK
#define gimp_drawable_channel GIMP_IS_CHANNEL
#define gimp_layer_set_name(l,n) gimp_object_set_name(GIMP_OBJECT(l),(n))
#define gimp_layer_get_name(l) gimp_object_get_name(GIMP_OBJECT(l))
#define gimp_layer_get_visible(l) gimp_drawable_get_visible(GIMP_DRAWABLE(l))
#define gimp_layer_set_visible(l,v) gimp_drawable_set_visible(GIMP_DRAWABLE(l),(v))
#define gimp_layer_set_tattoo(l,t) gimp_item_set_tattoo(GIMP_ITEM(l),(t))
#define gimp_layer_get_tattoo(l) gimp_item_get_tattoo(GIMP_ITEM(l))
#define gimp_channel_set_name(c,n) gimp_object_set_name(GIMP_OBJECT(c),(n))
#define gimp_channel_get_name(c) gimp_object_get_name(GIMP_OBJECT(c))
#define gimp_channel_get_visible(c) gimp_drawable_get_visible(GIMP_DRAWABLE(c))
#define gimp_channel_set_visible(c,v) gimp_drawable_set_visible(GIMP_DRAWABLE(c),(v))
#define gimp_channel_set_tattoo(c,t) gimp_item_set_tattoo(GIMP_ITEM(c),(t))
#define gimp_channel_get_tattoo(c) gimp_item_get_tattoo(GIMP_ITEM(c))
#define gimp_layer_get_apply_mask(l) (l)->mask ? gimp_layer_mask_get_apply((l)->mask) : FALSE;
#define gimp_layer_get_show_mask(l) (l)->mask ? gimp_layer_mask_get_show((l)->mask) : FALSE;
#define gimp_layer_get_edit_mask(l) (l)->mask ? gimp_layer_mask_get_edit((l)->mask) : FALSE;
#define gimp_layer_set_apply_mask(l,a) { if((l)->mask) gimp_layer_mask_set_apply((l)->mask,(a)); else success = FALSE; }
#define gimp_layer_set_show_mask(l,s) { if((l)->mask) gimp_layer_mask_set_show((l)->mask,(s)); else success = FALSE; }
#define gimp_layer_set_edit_mask(l,e) { if((l)->mask) gimp_layer_mask_set_edit((l)->mask,(e)); else success = FALSE; }
#define gimp_drawable_parasite_attach(d,p) gimp_item_parasite_attach(GIMP_ITEM(d),p)
#define gimp_drawable_parasite_detach(d,p) gimp_item_parasite_detach(GIMP_ITEM(d),p)
#define gimp_drawable_parasite_list(d,c) gimp_item_parasite_list(GIMP_ITEM(d),c)
#define gimp_drawable_parasite_find(d,p) gimp_item_parasite_find(GIMP_ITEM(d),p)
#endif /* __PDB_GLUE_H__ */