Commit Graph

316 Commits

Author SHA1 Message Date
Michael Natterer 65a65947d9 app, libgimp: replace GTK_STOCK_FOO by icon names
unless it's a stock ID used for an action button, will address that
later.
2014-05-11 22:49:22 +02:00
Michael Natterer 22c222291d libgimpbase,*: clean up enum values in gimpbaseenums.h
GIMP_ADD_foo_MASK -> GIMP_ADD_MASK_foo
GIMP_foo_MODE -> GIMP_BLEND_foo
GIMP_foo_CLONE -> GIMP_CLONE_foo
GIMP_foo -> GIMP_DODGE_BURN_TYPE_foo
GIMP_foo -> GIMP_TRANSFER_foo

Add compat values for the old names and compat code to script-fu
and pygimp.
2014-04-29 20:58:30 +02:00
Jehan c7aa623a55 app: clean out a big bunch of leading tabs.
For some unknown reason, most calls to gimp_message_literal() were
indented with tabs.
2013-09-15 04:59:20 +12:00
Michael Natterer 125cf2a2a3 app: use the image instead of the projection for accessing a pickable 2013-09-13 23:29:06 +02:00
Michael Natterer 796a9474d8 app: implement "Crop Image/Layer to Content" menu items in the core
in a few lines using existing functionality, as replacement for the
autocrop plugin. Rename the existing "crop" actions to
"crop-to-selection".
2012-09-22 20:35:36 +02:00
Michael Natterer 055a52e969 app: fix signature of layers_resize_layer_callback() 2012-09-08 23:51:06 +02:00
Michael Natterer c14738806e app: use gimp_image_get_layer_format() instead of dealing with image_type 2012-05-02 17:50:57 +02:00
Michael Natterer 765c2cfea2 app: replace GimpDraable's type by a Babl format
and change gimp_drawable_new() and all gimp_layer_new() variants to
take formats instead of types.
2012-05-02 17:46:06 +02:00
Michael Natterer 88388467cc app: move the layer mask show, edit, apply API from GimpLayerMask to GimpLayer
because it would require really evil hacks to honor these properties
in the gegl projection if they were on the mask, and because they
actually belong to the layer.
2012-05-02 17:45:56 +02:00
Michael Natterer 7c3a796dfc app: added GimpPickable::get_buffer()
Add cached buffers to GimpProjection and GimpImageMap, and use
the new API where possible.
2012-05-02 17:45:50 +02:00
Martin Nordholts cc7755f876 Port stuff to gimp_item_is_text_layer()
Port stuff to gimp_item_is_text_layer() instead of
gimp_drawable_is_text_layer(). Nevermind the previous commit, it
should never have been pushed...
2010-10-05 07:39:00 +02:00
Martin Nordholts 49a0be731e app: s/gimp_drawable_is_text_layer/gimp_item_is_text_layer/g 2010-10-05 07:12:30 +02:00
Michael Natterer 3184c440b3 app: introduce GimpItem::to_selection()
Which replaces all the deparate functions to turn layers, channels,
layer masks and vectors into selections. Use the new virtual function
all over the place instead of calling the functions in
gimpchannel-select.c manually.
2010-07-20 23:09:19 +02:00
Michael Natterer 314a6ab926 app: merge the layer, channel and vectors repositioning APIs
into an API based on GimpItem.
2010-07-08 18:08:13 +02:00
Michael Natterer 3c8baf6c28 app: make sure scale and resize progress is shown in the statusbar again
The action data passed to callbacks is now a GimpImageWindow, not
a GimpDisplay, so adapt the code to take that into account.
2010-06-06 16:44:36 +02:00
Michael Natterer b7d1be96e0 Get rid of the "New" in "New Layer", "New Channel" etc.
because they are "new" only once and then never again. Instead, simply
call new stuff "Layer", "Channel" and "Path", either by passing that
string explicitely, or by passing NULL so their class' default name
will be used.
2010-02-09 22:32:40 +01:00
Michael Natterer 82f8cee292 Use the newly added get_parent() APIs
Get rid of tons of local "parent" variables and inline the
get_parent() calls. They were on separate lines only to make them
readable at all.
2010-02-07 13:46:46 +01:00
Michael Natterer 335597ce7d Bug 604508 - gimp-layer-new-from-visible should work from updated projection
Call gimp_pickable_flush(projection) before creating a new layer from it.
2009-12-14 14:01:37 +01:00
Michael Natterer ac98c2c234 Use gimp_display_get_shell() instead of directly accessing it 2009-10-04 19:56:39 +02:00
Michael Natterer 90893cea84 Add "layers-merge-group" action, callback and menu items 2009-09-21 19:17:02 +02:00
Michael Natterer a3558e3cb8 Remove GIMP_OBJECT() casts when calling gimp_object_get_name() 2009-08-31 22:47:18 +02:00
Michael Natterer d37dc64b16 Add GError reporting to gimp_image_merge_down()
- turn g_return_if_fail() of more complex conditions into errors.
- change PDB wrapper accordingly instead of adding a ton of conditions
  there.
2009-08-25 22:02:02 +02:00
Michael Natterer e8bd830f48 Add action and callback for adding a group layer (works but is not used yet) 2009-08-06 18:37:54 +02:00
Michael Natterer 6f555cc407 Make sure duplicated item groups end up at the right place
Use the actual parent item when adding to the image, not
GIMP_IMAGE_ACTIVE_PARENT because the latter would add a duplicated
group inside itself instead of above it
2009-08-03 23:19:25 +02:00
Michael Natterer a53d4566da Use GIMP_IMAGE_ACTIVE_PARENT instead of a NULL parent in all obvious places 2009-08-03 22:30:36 +02:00
Michael Natterer c4075975bf Bring parent items to the public API in the core
* app/core/gimpimage.[ch]: make the parent parameter public in
add_layer(), add_layers(), add_channel() and add_vectors().

* app/vectors/gimpvectors-import.[ch]: add parent parameters to
  the vectors import functions.

* app/core/gimpchannelundo.[ch]
* app/core/gimplayerundo.[ch]
* app/vectors/gimpvectorsundo.[ch]
* app/core/gimpimage-undo-push.[ch]: remember the parent item when
  removing layers, channels and vectors.

* app/actions/channels-commands.c
* app/actions/debug-commands.c
* app/actions/edit-commands.c
* app/actions/layers-commands.c
* app/actions/vectors-commands.c
* app/core/gimp-edit.c
* app/core/gimpimage-duplicate.c
* app/core/gimpimage-merge.c
* app/core/gimpimage-quick-mask.c
* app/core/gimplayer-floating-sel.c
* app/core/gimpselection.c
* app/core/gimptemplate.c
* app/dialogs/file-open-dialog.c
* app/display/gimpdisplayshell-dnd.c
* app/text/gimptext-compat.c
* app/tools/gimptexttool.c
* app/tools/gimpvectortool.c
* app/widgets/gimptoolbox-dnd.c
* app/xcf/xcf-load.c
* tools/pdbgen/pdb/image.pdb
* tools/pdbgen/pdb/paths.pdb
* tools/pdbgen/pdb/vectors.pdb: pass NULL as parent item to above
  functions and add FIXMEs all over the place because there is some
  more hacking needed to make adding with index = -1 (on top of the
  current item) work again.

* app/pdb/image-cmds.c
* app/pdb/paths-cmds.c
* app/pdb/vectors-cmds.c: regenerated.

* app/core/gimpimage-duplicate.c: duplicate the original image's
  tree structure in the copy.

* app/widgets/gimpitemtreeview.[ch]: add parent to GimpAddItemFunc,
  add utility function gimp_item_tree_view_get_drop_index() which
  figures where to add something dropped to an item tree.

* app/widgets/gimpchanneltreeview.c
* app/widgets/gimplayertreeview.c
* app/widgets/gimpvectorstreeview.c: changed accordingly, using above
  new GimpItemTreeView API.
2009-08-03 19:21:51 +02:00
Michael Natterer b3e0147598 Make layer selecting by actions work on the right container 2009-08-02 12:02:18 +02:00
Michael Natterer d9b5207aa2 Change licence to GPLv3 (and to LGPLv3 for libgimp).
2009-01-17  Michael Natterer  <mitch@gimp.org>

	* all files with a GPL header and all COPYING files:

	Change licence to GPLv3 (and to LGPLv3 for libgimp).

	Cleaned up some copyright headers and regenerated the parsers in
	the ImageMap plugin.


svn path=/trunk/; revision=27913
2009-01-17 22:28:01 +00:00
Michael Natterer fb1660a4ea rename gimp_image_floating_sel() to gimp_image_get_floating_selection().
2008-11-14  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage.[ch]: rename gimp_image_floating_sel() to
	gimp_image_get_floating_selection().

	* app/actions/channels-actions.c
	* app/actions/image-actions.c
	* app/actions/layers-actions.c
	* app/actions/layers-commands.c
	* app/actions/select-actions.c
	* app/core/gimpdrawable.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-quick-mask.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimpselection.c
	* app/display/gimpdisplayshell-layer-select.c
	* app/display/gimpdisplayshell.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimprectangleselecttool.c
	* app/tools/gimpregionselecttool.c
	* app/tools/gimpselectiontool.c
	* app/tools/gimptexttool.c
	* app/widgets/gimpdrawabletreeview.c
	* app/widgets/gimplayertreeview.c
	* app/xcf/xcf-save.c
	* tools/pdbgen/pdb/image.pdb: changed accordingly, replaced some
	instances of direct acces by the accessor.

	* app/pdb/image-cmds.c: regenerated.


svn path=/trunk/; revision=27649
2008-11-14 15:01:44 +00:00
Michael Natterer 1cdf6c5b7f remove floating_sel_remove() and reorder one function.
2008-11-09  Michael Natterer  <mitch@gimp.org>

	* app/core/gimplayer-floating-sel.[ch]: remove
	floating_sel_remove() and reorder one function.

	* app/core/gimpimage.c (gimp_image_remove_layer): add the single
	line of special code that needs to be done when removing a
	floating selection.

	* app/core/gimpselection.c
	* app/actions/layers-commands.c
	* tools/pdbgen/pdb/floating_sel.pdb: changed accordingly.

	* app/pdb/floating-sel-cmds.c: regenerated.

	* app/core/core-enums.[ch]
	* app/core/gimpimage-undo.c: remove enum value
	GIMP_UNDO_GROUP_FS_REMOVE.


svn path=/trunk/; revision=27583
2008-11-09 18:45:16 +00:00
Sven Neumann 4762b73403 bumped minimum required version of GLib to 2.18.0.
2008-11-04  Sven Neumann  <sven@sven>

	* configure.in: bumped minimum required version of GLib to 
2.18.0.

	* INSTALL: document the updated dependency.

	* app/core/gimp.[ch]: introduced gimp_message_literal(), a 
variant
	of gimp_message() that takes a literal string.

	* app/errors.[ch]: removed format arguments from 
gimp_fatal_error()
	and gimp_terminate() and let them take a literal string instead.

	* app/tools/gimptool.[ch]: introduced 
gimp_tool_message_literal(),
	a variant of gimp_tool_message() that takes a literal string.

	* app/actions/documents-commands.c
	* app/actions/drawable-commands.c
	* app/actions/edit-commands.c
	* app/actions/error-console-commands.c
	* app/actions/file-commands.c
	* app/actions/gradients-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/plug-in-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/config/gimprc.c
	* app/core/gimp-modules.c
	* app/core/gimp-parasites.c
	* app/core/gimp-templates.c
	* app/core/gimp-units.c
	* app/core/gimpchannel.c
	* app/core/gimpcontainer-filter.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage.c
	* app/core/gimpimagefile.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/core/gimpselection.c
	* app/dialogs/convert-dialog.c
	* app/dialogs/dialogs.c
	* app/dialogs/palette-import-dialog.c
	* app/dialogs/preferences-dialog.c
	* app/dialogs/quit-dialog.c
	* app/dialogs/stroke-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/file/file-open.c
	* app/file/file-procedure.c
	* app/file/file-save.c
	* app/file/file-utils.c
	* app/gegl/gimpcurvesconfig.c
	* app/gegl/gimplevelsconfig.c
	* app/gui/gui-message.c
	* app/gui/gui.c
	* app/gui/session.c
	* app/paint/gimpbrushcore.c
	* app/paint/gimpclone.c
	* app/paint/gimpheal.c
	* app/paint/gimpperspectiveclone.c
	* app/paint/gimpsourcecore.c
	* app/pdb/gimppdb-utils.c
	* app/pdb/gimpprocedure.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin.c
	* app/plug-in/gimppluginmanager-restore.c
	* app/plug-in/gimppluginprocedure.c
	* app/text/gimptextlayer.c
	* app/tools/gimp-tools.c
	* app/tools/gimpaligntool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdesaturatetool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpgegltool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpimagemaptool-settings.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpselectiontool.c
	* app/tools/gimpsourcetool.c
	* app/tools/gimpthresholdtool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c
	* app/widgets/gimpactionview.c
	* app/widgets/gimpcontrollerlist.c
	* app/widgets/gimpcontrollers.c
	* app/widgets/gimpdataeditor.c
	* app/widgets/gimpdevices.c
	* app/widgets/gimpdnd-xds.c
	* app/widgets/gimperrordialog.c
	* app/widgets/gimphelp.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimppdbdialog.c
	* app/widgets/gimpsettingsbox.c
	* app/widgets/gimpvectorstreeview.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf-load.c
	* tools/pdbgen/pdb/convert.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/floating_sel.pdb
	* tools/pdbgen/pdb/image.pdb: use the _literal variants for
	g_set_error(), gimp_message() and gimp_tool_message().

	* app/pdb/convert-cmds.c
	* app/pdb/edit-cmds.c
	* app/pdb/floating-sel-cmds.c
	* app/pdb/image-cmds.c: regenerated.


svn path=/trunk/; revision=27548
2008-11-04 12:33:09 +00:00
Michael Natterer 87dc343b21 remove public functions get_tiles(), get_image(), get_image_type() and
2008-11-04  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpprojection.[ch]: remove public functions
	get_tiles(), get_image(), get_image_type() and get_bytes().

	* app/actions/debug-commands.c
	* app/actions/layers-commands.c
	* app/core/gimpprojection-construct.c
	* app/display/gimpdisplayshell-render.c
	* app/paint/gimppaintcore.c
	* tools/pdbgen/pdb/layer.pdb: use the GimpPickable API insatead.

	* app/pdb/layer-cmds.c: regenerated.


svn path=/trunk/; revision=27547
2008-11-04 12:07:17 +00:00
Michael Natterer 740ab5e633 renamed gimp_item_width() to gimp_item_get_width() and gimp_item_height()
2008-11-03  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpitem.[ch]: renamed
	gimp_item_width() to gimp_item_get_width() and
	gimp_item_height() to gimp_item_get_height().

	* app/actions/channels-commands.c
	* app/actions/drawable-commands.c
	* app/actions/layers-commands.c
	* app/core/<many>.c
	* app/dialogs/offset-dialog.c
	* app/dialogs/resize-dialog.c
	* app/dialogs/scale-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/display/gimpdisplayshell.c
	* app/paint/gimpbrushcore.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimpink.c
	* app/paint/gimppaintcore.c
	* app/paint/gimpsmudge.c
	* app/text/gimptextlayer-xcf.c
	* app/text/gimptextlayer.c
	* app/tools/gimpaligntool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimprectangletool.c
	* app/tools/gimpregionselecttool.c
	* app/tools/gimptexttool.c
	* app/vectors/gimpvectors.c
	* app/vectors/gimpvectorsmodundo.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimpviewrendererdrawable.c
	* app/widgets/gimpviewrenderervectors.c
	* app/xcf/xcf-load.c
	* app/xcf/xcf-save.c
	* tools/pdbgen/pdb/drawable.pdb: changed accordingly.

	* app/pdb/drawable-cmds.c: regenerated.


svn path=/trunk/; revision=27531
2008-11-03 00:09:01 +00:00
Michael Natterer 5b68a1d0eb renamed gimp_item_offsets() to gimp_item_get_offset() and
2008-11-03  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpitem.[ch]: renamed
	gimp_item_offsets() to gimp_item_get_offset() and
	gimp_item_set_offsets() to gimp_item_set_offset().

	* app/actions/drawable-commands.c
	* app/actions/layers-commands.c
	* app/core/<many>.c
	* app/display/gimpdisplayshell-dnd.c
	* app/display/gimpdisplayshell-preview.c
	* app/display/gimpdisplayshell-transform.c
	* app/display/gimpdisplayshell.c
	* app/paint/gimppaintcore-stroke.c
	* app/paint/gimppaintcore.c
	* app/paint/gimpsourcecore.c
	* app/text/gimptextlayer-xcf.c
	* app/tools/<many>.c
	* app/widgets/gimptoolbox-dnd.c
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/drawable_transform.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/transform_tools.pdb
	* tools/pdbgen/pdb/vectors.pdb: changed accordingly.

	* app/pdb/drawable-cmds.c
	* app/pdb/drawable-transform-cmds.c
	* app/pdb/selection-cmds.c
	* app/pdb/vectors-cmds.c
	* app/pdb/transform-tools-cmds.c: regenerated.


svn path=/trunk/; revision=27529
2008-11-02 23:03:29 +00:00
Michael Natterer 5503e6a055 Add GEGL_CFLAGS and #includes as if gimpdrawable.h and gimpimage.h had a
2008-10-09  Michael Natterer  <mitch@gimp.org>

	Add GEGL_CFLAGS and #includes as if gimpdrawable.h and gimpimage.h
	had a GEGL dependency (they will have in the next commit, but I
	wanted to keep the commit separate).

	* app/dialogs/Makefile.am
	* app/file/Makefile.am
	* app/gui/Makefile.am
	* app/menus/Makefile.am
	* app/paint/Makefile.am
	* app/plug-in/Makefile.am
	* app/text/Makefile.am
	* app/vectors/Makefile.am
	* app/widgets/Makefile.am
	* app/xcf/Makefile.am: add GEGL_CFLAGS.

	* app/actions/*.c
	* app/core/*.c
	* app/dialogs/*.c
	* app/display/*.c
	* app/file/*.c
	* app/gui/*.c
	* app/menus/*.c
	* app/paint/*.c
	* app/pdb/gimppdb-utils.c
	* app/pdb/gimpprocedure.c
	* app/plug-in/*.c
	* app/text/*.c
	* app/tools/*.c
	* app/vectors/*.c
	* app/widgets/*.c
	* app/xcf/*.c: add <gegl.h> or replace <glib-object.h> by <gegl.h>
	to all files which include a drawable subclass or gimpimage.h

	* tools/pdbgen/app.pl: include <gegl.h> instead of <glib-object.h>
	in all generated files.

	* app/pdb/*-cmds.c: regenerated.

	* data/images/gimp-splash.png: the goat is still sleeping.
	By Aurore Derriennic.


svn path=/trunk/; revision=27202
2008-10-09 20:24:04 +00:00
Michael Natterer 0e4a35a2d8 Remove the last code duplication from the undo system (or if not the last
2008-10-09  Michael Natterer  <mitch@gimp.org>

	Remove the last code duplication from the undo system (or if not
	the last then at least the most ugly):

	* app/core/gimpimage.[ch] (gimp_image_add_layer,channel,vectors):
	add "gboolean push_undo" parameter and add the item without
	touching undo if it's TRUE. Changed assertions from
	g_object_is_floating() to !gimp_item_is_attached() so they also
	take items from the undo stack and not only newly created ones.

	(gimp_image_remove_layer,channel,vectors): add "push_undo"
	parameter here too. Also add a "new_active" parameter where an
	optional new active item can be passed.

	(gimp_image_remove_layer,channel): these functions must not be
	called with push_undo=FALSE and a floating selection attached to
	the layer/channel. This can't currently happen; added warnings in
	case other code is changed and makes it happen anyway.

	* app/core/gimpchannelundo.c
	* app/core/gimplayerundo.c
	* app/vectors/gimpvectorsundo.c: use above functions to add/remove
	items instead of duplicating (parts of) their code. Pass
	push_undo=FALSE and the previously active item to the remove()
	functions.

	* app/actions/channels-commands.c
	* app/actions/edit-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimp-edit.c
	* app/core/gimpchannelundo.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-quick-mask.c
	* app/core/gimpimage-scale.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayerundo.c
	* app/core/gimpselection.c
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-dnd.c
	* app/text/gimptext-compat.c
	* app/tools/gimptexttool.c
	* app/tools/gimpvectortool.c
	* app/vectors/gimpvectors-import.c
	* app/vectors/gimpvectorsundo.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpitemtreeview.[ch]
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimpvectorstreeview.c
	* app/xcf/xcf-load.c
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/paths.pdb: changed accordingly (pass TRUE
	unless it's a new image like when loading and XCF file).

	* app/pdb/image-cmds.c
	* app/pdb/paths-cmds.c: regenerated.


svn path=/trunk/; revision=27200
2008-10-09 19:40:41 +00:00
Michael Natterer 68c21b49e9 Revert the change which adds GError parameters to
2008-09-17  Michael Natterer  <mitch@gimp.org>

	Revert the change which adds GError parameters to
	gimp_image_add_{channel,layer,vectors}():

	* app/actions/channels-commands.c
	* app/actions/edit-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimp-edit.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-quick-mask.c
	* app/core/gimpimage.[ch]
	* app/core/gimplayer-floating-sel.c
	* app/core/gimpselection.c
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-dnd.c
	* app/text/gimptext-compat.c
	* app/tools/gimptexttool.c
	* app/tools/gimpvectortool.c
	* app/vectors/gimpvectors-import.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpitemtreeview.[ch]
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimpvectorstreeview.c
	* app/xcf/xcf-load.c: revert.

	Instead, fix it at the PDB level:

	* app/core/gimpimage.c: turn the "added to wrong image" warning
	into a g_return_val_if_fail() assertion.

	* app/pdb/gimppdb-utils.[ch] (gimp_pdb_item_is_floating): add a
	"dest_image" parameter and fail if the passed item is not for this
	image.

	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/paths.pdb: pass the dest image to
	gimp_pdb_item_is_floating().

	* app/pdb/image-cmds.c
	* app/pdb/layer-cmds.c
	* app/pdb/paths-cmds.c: regenerated.


svn path=/trunk/; revision=26970
2008-09-17 11:41:54 +00:00
Michael Natterer b0dab70de8 add GError parameter to gimp_image_add_{channel,layer,vectors}() and
2008-09-17  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage.[ch]: add GError parameter to
	gimp_image_add_{channel,layer,vectors}() and remove calls to
	g_warning(). Changed checks to be possible failures at all.

	* app/widgets/gimpitemtreeview.h (GimpAddItemFunc): add the GError
	here too.

	* app/actions/channels-commands.c
	* app/actions/edit-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimp-edit.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-quick-mask.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimpselection.c
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-dnd.c
	* app/text/gimptext-compat.c
	* app/tools/gimptexttool.c
	* app/tools/gimpvectortool.c
	* app/vectors/gimpvectors-import.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimpvectorstreeview.c
	* app/xcf/xcf-load.c: pass a NULL error.

	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/paths.pdb: pass the error.

	* app/pdb/image-cmds.c
	* app/pdb/paths-cmds.c: regenerated.


svn path=/trunk/; revision=26963
2008-09-17 08:27:35 +00:00
Sven Neumann b2ad06a19f added GError parameter to gimp_image_{raise,lower}_{channel,layer,vectors}
2008-09-16  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimage.[ch]: added GError parameter to
	gimp_image_{raise,lower}_{channel,layer,vectors} functions and
	removed calls to g_message().

	* app/actions/channels-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c: pass NULL for the GError
	parameter as these actions are insensitive if they would fail.

	* tools/pdbgen/pdb/image.pdb: changed accordingly. Corrected the
	documentation.

	* app/pdb/image-cmds.c
	* libgimp/gimpimage_pdb.c: regenerated.


svn path=/trunk/; revision=26953
2008-09-16 20:56:41 +00:00
Michael Natterer d2307c1bf6 add GError parameter and replace g_message() by g_set_error().
2008-09-15  Michael Natterer  <mitch@gimp.org>

	* app/core/gimplayer.[ch] (gimp_layer_add_mask): add GError
	parameter and replace g_message() by g_set_error().

	* app/core/gimplayermaskundo.c
	* app/xcf/xcf-load.c
	* app/actions/layers-commands.c: pass NULL errors since these
	places know what they are doing. Ha ha...

	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/image.pdb: pass the error so we get more real
	error messages for failed PDB calls.

	* app/pdb/image-cmds.c
	* app/pdb/layer-cmds.c: regenerated.


svn path=/trunk/; revision=26948
2008-09-15 21:05:01 +00:00
Sven Neumann 60fcaa9629 app/core/gimplayer.c app/actions/edit-commands.c
2008-08-07  Sven Neumann  <sven@gimp.org>

	* app/core/gimplayer.c
	* app/actions/edit-commands.c
	* app/actions/layers-commands.c
	* tools/pdbgen/pdb/layer.pdb: corrected the GimpImageType passed
	to gimp_layer_new_from_tiles().

	* app/pdb/layer-cmds.c: regenerated.


svn path=/trunk/; revision=26425
2008-08-07 17:19:32 +00:00
Sven Neumann 1c7a427e61 app/actions/layers-actions.c added new action "layers-new-from-visible".
2008-08-07  Sven Neumann  <sven@gimp.org>

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]: added new action
	"layers-new-from-visible".

	* app/widgets/gimphelp-ids.h: added new help-id.

	* menus/layers-menu.xml
	* menus/image-menu.xml.in: added the new action.

	* app/actions/edit-actions.c: improved the blurb for
	"edit-copy-visible".


svn path=/trunk/; revision=26421
2008-08-07 15:53:15 +00:00
Michael Natterer 8c66ea4b19 app/actions/layers-commands.c app/actions/view-actions.c
2008-06-28  Michael Natterer  <mitch@gimp.org>

	* app/actions/layers-commands.c
	* app/actions/view-actions.c
	* app/dialogs/about-dialog.c
	* app/dialogs/layer-options-dialog.c
	* app/dialogs/preferences-dialog.c
	* app/display/gimpcanvas.c
	* app/display/gimpdisplayshell-appearance.c
	* app/display/gimpnavigationeditor.c
	* modules/colorsel_water.c: use accessors instead of accessing
	members of GTK+ widgets directly.


svn path=/trunk/; revision=26006
2008-06-28 15:12:13 +00:00
Martin Nordholts 368c855c90 Add keyboard shortcut support for reseting to default value of e.g. brush
2008-05-31  Martin Nordholts  <martinn@svn.gnome.org>

	Add keyboard shortcut support for reseting to default value of
	e.g. brush scale. Fixes bug #493030.

	* app/actions/actions.[ch]: Make action_select_value() take a
	default-parameter and add support for it. Also use default_value
	from gint and gdouble param specs.

	* app/actions/actions-types.h: Added
	GIMP_ACTION_SELECT_SET_TO_DEFAULT.

	* app/actions/tools-actions.c: Add _SET_TO_DEFAULT actions.

	* app/actions/view-commands.c:
	* app/actions/layers-commands.c:
	* app/actions/context-commands.c: Pass defaults to
	action_select_property().

svn path=/trunk/; revision=25874
2008-05-31 20:05:03 +00:00
Sven Neumann 4aa7e67c67 removed "add_alpha" parameter from gimp_item_duplicate() and
2008-01-08  Sven Neumann  <sven@gimp.org>

	* app/core/gimpitem.[ch]: removed "add_alpha" parameter from
	gimp_item_duplicate() and gimp_item_convert(). This is a relict
	from the time when only the bottom layer was allowed to have no
	alpha channel.

	* app/actions/channels-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-quick-mask.c
	* app/core/gimplayer.c
	* app/core/gimplayermask.c
	* app/core/gimpselection.c
	* app/display/gimpdisplayshell-dnd.c
	* app/file/file-open.c
	* app/pdb/channel_cmds.c
	* app/pdb/layer_cmds.c
	* app/text/gimptextlayer.c
	* app/vectors/gimpvectors.c
	* app/vectors/gimpvectorsmodundo.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* tools/pdbgen/pdb/channel.pdb
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

svn path=/trunk/; revision=24570
2008-01-08 11:46:15 +00:00
Michael Natterer ecb2c46dc8 app/actions/layers-commands.c app/core/gimpchannel-combine.c
2007-12-23  Michael Natterer  <mitch@gimp.org>

	* app/actions/layers-commands.c
	* app/core/gimpchannel-combine.c
	* app/core/gimpchannel-select.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable-convert.c
	* app/core/gimpdrawable.c
	* app/core/gimpdrawablemodundo.c
	* app/core/gimpfloatingselundo.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-resize.c
	* app/core/gimpimage.c
	* app/core/gimpitem-preview.c
	* app/core/gimpitem.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/core/gimplayermask.c
	* app/core/gimplayerundo.c
	* app/core/gimpmaskundo.c
	* app/core/gimppalette-import.c
	* app/core/gimpprojection-construct.c
	* app/core/gimpselection.c
	* app/dialogs/offset-dialog.c
	* app/text/gimptextlayer-xcf.c
	* app/text/gimptextlayer.c
	* app/vectors/gimpvectors-compat.c
	* app/vectors/gimpvectors.c
	* app/vectors/gimpvectorsmodundo.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpviewrendererdrawable.c
	* app/widgets/gimpviewrenderervectors.c: use accessors for item,
	layer, channel and mask attributes.


svn path=/trunk/; revision=24429
2007-12-23 16:58:41 +00:00
Michael Natterer dfaf761dc0 added GError to GimpItem::rename().
2007-12-12  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpitem.[ch]: added GError to GimpItem::rename().

	* app/core/gimplayer.c
	* app/core/gimplayermask.c: set errors when renaming is impossible.

	* app/text/gimptextlayer.c
	* app/core/gimpimage-quick-mask.c: changed accordingly.

	* app/actions/channels-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c
	* app/widgets/gimpitemtreeview.c: handle the returned errors.

	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/vectors.pdb: pass the error.

	* app/pdb/drawable_cmds.c
	* app/pdb/vectors_cmds.c: regenerated.


svn path=/trunk/; revision=24338
2007-12-12 13:57:11 +00:00
Michael Natterer 543302f551 Move some gimp_message() calls where they belong:
2007-12-06  Michael Natterer  <mitch@gimp.org>

	Move some gimp_message() calls where they belong:

	* app/core/gimplayer-floating-sel.[ch]: removed unreachable
	gimp_message() in floating_sel_anchor() and added GError parameter
	to floating_sel_to_layer().

	* app/core/gimplayer.c
	* app/core/gimpimage-quick-mask.c
	* app/actions/layers-commands.c: pass NULL or an error as
	appropriate and show the error message.

	* tools/pdbgen/pdb/floating_sel.pdb: set the error when the passed
	layer was no floating selection.

	* app/pdb/floating_sel_cmds.c: regenerated.


svn path=/trunk/; revision=24272
2007-12-06 18:00:10 +00:00
Michael Natterer 08d38cea82 Make layer masks work consistently on layers without alpha. Fixes bug
2007-09-15  Michael Natterer  <mitch@gimp.org>

	Make layer masks work consistently on layers without alpha.
	Fixes bug #475548.

	* app/core/gimplayer.c (gimp_layer_apply_mask): changed to work
	on layers without alpha.

	* app/actions/layers-commands.c (layers_add_mask_response): don't
	automatically add an alpha channel when adding a layer mask.


svn path=/trunk/; revision=23555
2007-09-15 19:23:20 +00:00
Sven Neumann 41237259c9 In all files, changed the standard copyright notice to say "GIMP - The GNU
2006-12-09  Sven Neumann  <sven@gimp.org>

        * In all files, changed the standard copyright notice to say
        "GIMP - The GNU Image Manipulation Program".
2006-12-09 21:33:38 +00:00
Michael Natterer 8354a78177 Applied slightly modified patch from Martin Nordholts which implements
2006-10-15  Michael Natterer  <mitch@gimp.org>

	Applied slightly modified patch from Martin Nordholts which
	implements more fine-grained steps for actions. Fixes bug #165612.

	* app/actions/actions-types.h: add additional values to
	enum GimpActionSelectType.

	* app/actions/actions.[ch] (action_select_value)
	(action_select_property): handle them here and added "small_inc"
	and "delta_factor" parameters.

	* app/actions/context-actions.c: added small and percent actions
	for the brush radius.

	* app/actions/context-commands.c
	* app/actions/layers-commands.c
	* app/actions/tools-commands.c
	* app/actions/view-commands.c: pass small and percent increase
	values to the action_select_foo() functions.

	* app/actions/context-commands.c (context_brush_radius_cmd_callback):
	make sure we don't end up with 1.1, 2.1 etc brush radius values.
2006-10-15 16:51:30 +00:00
Michael Natterer 76ba5de16a Remember the settings in the scale and resize dialogs for images and
2006-10-14  Michael Natterer  <mitch@gimp.org>

	Remember the settings in the scale and resize dialogs for images
	and layers. Fixes bug #164995, bug #316392, and bug #357424.

	* app/dialogs/scale-dialog.h: removed GimpScaleCallback typedef.

	* app/dialogs/dialogs-types.h: added it here.

	* app/dialogs/image-scale-dialog.[ch]: made the ImageScaleDialog
	struct private, return a GtkWidget* from image_scale_dialog_new()
	and use a GimpScaleCallback in the public API.

	* app/actions/actions-types.h: #include "dialogs/dialogs-types.h"

	* app/actions/image-commands.c: changed according to image scale
	dialog changes. Remember the scale dialog's unit (if it is
	"percent") and interpolation type across dialog invocations. Also
	remember the resize dialog's unit (if it is "percent").

	* app/actions/layers-commands.c: remember scale and resize dialog
	stuff as in image-commands.c
2006-10-14 16:51:30 +00:00
Michael Natterer 1ed8dd4f53 app/actions/data-commands.c app/actions/documents-commands.c
2006-10-09  Michael Natterer  <mitch@gimp.org>

	* app/actions/data-commands.c
	* app/actions/documents-commands.c
	* app/actions/drawable-commands.c
	* app/actions/gradients-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimp-contexts.c
	* app/core/gimp-documents.c
	* app/core/gimp-edit.c
	* app/core/gimp-modules.c
	* app/core/gimp-parasites.c
	* app/core/gimp-templates.c
	* app/core/gimp-units.c
	* app/core/gimpchannel.c
	* app/core/gimpdatafactory.[ch]
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimagefile.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimppdbprogress.c
	* app/core/gimpselection.c
	* app/dialogs/palette-import-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/session.c
	* app/gui/themes.c
	* app/pdb/gimpprocedure.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin.c
	* app/plug-in/gimppluginmanager-file.c
	* app/plug-in/gimppluginmanager.c
	* app/text/gimptextlayer-xcf.c
	* app/text/gimptextlayer.c
	* app/widgets/gimpcontrollers.c
	* app/widgets/gimpdataeditor.c
	* app/widgets/gimpdevices.c
	* app/widgets/gimpdnd-xds.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimpuimanager.c
	* app/widgets/gimpvectorstreeview.c
	* tools/pdbgen/pdb/brush.pdb
	* tools/pdbgen/pdb/gradient.pdb
	* tools/pdbgen/pdb/palette.pdb: convert lots of g_message() to
	gimp_message(). Make sure we never pass unknown strings (like
	error->message) to printf-like functions directly; run them
	thorugh "%s" instead. Don't translate some messages which should
	never happen.

	* app/pdb/brush_cmds.c
	* app/pdb/gradient_cmds.c
	* app/pdb/palette_cmds.c: regenerated.
2006-10-09 18:49:15 +00:00
Sven Neumann 2426755ba9 added function gimp_get_tool_info().
2006-09-08  Sven Neumann  <sven@gimp.org>

	* app/core/gimp.[ch]: added function gimp_get_tool_info().

	* app/actions/tools-commands.c
	* app/actions/vectors-commands.c
	* app/tools/gimppainttool.c
	* app/widgets/gimpdrawabletreeview.c
	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimptoolbox.c: use the new function instead of poking
	into gimp->tool_info_list.

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.[ch]: moved code that deals with
	the space key into separate functions. Added space_shaded_tool
	to GimpDisplayShell instead of using a static variable for it.

	* app/tools/tool_manager.c: removed unused include.
2006-09-08 13:42:00 +00:00
Michael Natterer a6dbb78dfa added GimpContext parameters and create the GimpView with that context.
2006-09-01  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpviewabledialog.[ch]: added GimpContext
	parameters and create the GimpView with that context.

	* app/widgets/gimpcolordialog.[ch]
	* app/dialogs/convert-dialog.[ch]
	* app/dialogs/desaturate-dialog.[ch]
	* app/dialogs/grid-dialog.[ch]
	* app/dialogs/image-properties-dialog.[ch]
	* app/dialogs/layer-add-mask-dialog.[ch]
	* app/dialogs/offset-dialog.[ch]
	* app/dialogs/print-size-dialog.[ch]
	* app/dialogs/resize-dialog.[ch]
	* app/dialogs/scale-dialog.[ch]
	* app/dialogs/stroke-dialog.[ch]
	* app/dialogs/template-options-dialog.[ch]
	* app/dialogs/vectors-options-dialog.[ch]: added GimpContext
	parameters here too and pass them to gimp_viewable_dialog_new().

	* app/actions/colormap-editor-commands.c
	* app/actions/drawable-commands.c
	* app/actions/gradient-editor-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palette-editor-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/actions/view-commands.c
	* app/dialogs/channel-options-dialog.c
	* app/dialogs/dialogs-constructors.c
	* app/dialogs/image-merge-layers-dialog.c
	* app/dialogs/image-scale-dialog.c
	* app/dialogs/layer-options-dialog.c
	* app/display/gimpdisplayshell-filter-dialog.c
	* app/display/gimpdisplayshell-scale.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimptexttool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c
	* app/widgets/gimpcolorpanel.c
	* app/widgets/gimpcontrollereditor.c
	* app/widgets/gimpcontrollerlist.c
	* app/widgets/gimptoolbox-color-area.c: pass contexts to above
	dialog constructors.
2006-09-01 11:26:54 +00:00
Sven Neumann 48d054e8d4 added new function gimp_message() as a replacement for g_message(). Part
2006-08-08  Sven Neumann  <sven@gimp.org>

	* app/core/gimp.[ch]: added new function gimp_message() as a
	replacement for g_message(). Part of the fix for bug #347214.

	* app/actions/data-commands.c
	* app/actions/documents-commands.c
	* app/actions/file-commands.c
	* app/actions/layers-commands.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimagefile.c
	* app/core/gimpitem.c
	* app/core/gimplayer.c
	* app/dialogs/file-open-dialog.c
	* app/dialogs/file-open-location-dialog.c
	* app/dialogs/file-save-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/pdb/gimppdb.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpthresholdtool.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf-load.c
	* app/xcf/xcf-private.h
	* app/xcf/xcf-save.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/brush.pdb
	* tools/pdbgen/pdb/gradient.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/palette.pdb: use gimp_message() instead of
	gimp_message() whenever we have a GimpProgress.

	* app/pdb/brush_cmds.c
	* app/pdb/gradient_cmds.c
	* app/pdb/image_cmds.c
	* app/pdb/palette_cmds.c: regenerated.
2006-08-08 21:06:36 +00:00
Michael Natterer 42ff7f4920 remove enum GimpItemLinkedMask...
2006-05-19  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpitem-linked.h: remove enum GimpItemLinkedMask...

	* app/core/core-enums.[ch]: ...and add it here as GimpItemTypeMask.
	Renamed enum GimpImageResizeLayers to GimpItemSet.

	* app/core/gimpitem-linked.[ch]
	* app/core/gimpimage-resize.[ch]
	* app/dialogs/resize-dialog.[ch]
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/tools/gimpeditselectiontool.c: changed accordingly.
2006-05-19 14:50:46 +00:00
Michael Natterer 1217dc8d07 Allow to initialize a new layer mask with any of the image's channels.
2006-05-14  Michael Natterer  <mitch@gimp.org>

	Allow to initialize a new layer mask with any of the image's
	channels. Fixes bug #310207.

	* libgimpbase/gimpbaseenums.h (enum GimpAddMaskType): added
	value GIMP_ADD_CHANNEL_MASK.

	* libgimpbase/gimpbaseenums.c
	* tools/pdbgen/enums.pl: regenerated.

	* app/core/gimplayer.[ch] (gimp_layer_create_mask): added
	GimpChannel* parameter. Hacked the GIMP_ADD_SELECTION_MASK code a
	bit so it can handle GIMP_ADD_CHANNEL_MASK too. Cleaned up the
	function a bit.

	* app/dialogs/layer-add-mask-dialog.[ch]: added a menu of the
	image's channels.

	* app/actions/layers-commands.c (layers_add_mask_response): pass
	the channel selected in the menu to gimp_layer_create_mask().

	* tools/pdbgen/pdb/layer.pdb (layer_create_mask): use the image's
	active channel when GIMP_ADD_CHANNEL_MASK is passed. Fail if there
	is no active channel.

	* app/pdb/layer_cmds.c: regenerated.
2006-05-14 16:24:31 +00:00
Michael Natterer 875af9c5cd Added some new text layer actions and menu items (bug #316299).
2006-05-13  Michael Natterer  <mitch@gimp.org>

	Added some new text layer actions and menu items (bug #316299).

	* app/actions/layers-actions.c: added actions for "Text to Path",
	"Text along Path" and "Text to Selection" (use the alpha to
	selection callback for text to selection)

	* app/actions/layers-commands.[ch]: added
	layers_text_to_vectors_cmd_callback() and
	layers_text_along_vectors_cmd_callback().

	* app/widgets/gimphelp-ids.h: help IDs for the new actions.

	* menus/image-menu.xml.in
	* menus/layers-menu.xml: added them to the layers menus in the
	image window and the layers dialog.
2006-05-13 19:48:18 +00:00
Sven Neumann 049872b361 app/*.[ch] converted tabs to spaces.
2006-04-12  Sven Neumann  <sven@gimp.org>

	* app/*.[ch]
	* app/*/*.[ch]: converted tabs to spaces.
2006-04-12 12:49:29 +00:00
Sven Neumann 5439aa4995 did a global gdisp -> display substitution.
2006-03-28  Sven Neumann  <sven@gimp.org>

	* app/*: did a global gdisp -> display substitution.
2006-03-28 17:55:52 +00:00
Sven Neumann 905fdfcbed did a global gimage -> image substitution.
2006-03-28  Sven Neumann  <sven@gimp.org>

	* app/*: did a global gimage -> image substitution.
2006-03-28 17:08:36 +00:00
Michael Natterer e7e2296fe5 app/actions/image-commands.c app/actions/layers-commands.c
2005-09-30  Michael Natterer  <mitch@gimp.org>

	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/view-actions.c
	* app/core/gimpdrawable-foreground-extract.c
	* app/core/gimpimagefile.c
	* app/core/gimpprogress.c
	* app/dialogs/convert-dialog.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpperspectivetool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/tools/gimpsheartool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimpthumbbox.c
	* tools/pdbgen/pdb/drawable_transform.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/transform_tools.pdb: removed '...' from
	progress messages. Removed spaces between the text and the '...'
	in some other places.

	* app/pdb/drawable_transform_cmds.c
	* app/pdb/edit_cmds.c
	* app/pdb/transform_tools_cmds.c: regenerated.
2005-09-30 17:50:50 +00:00
Sven Neumann 3b28167dd2 use GTK_STOCK_FILE for File actions.
2005-09-19  Sven Neumann  <sven@gimp.org>

	* app/actions/actions.c: use GTK_STOCK_FILE for File actions.

	* app/actions/dialogs-actions.c
	* plug-ins/gimpressionist/gimpressionist.c
	* plug-ins/print/gimp_main_window.c: use GTK_STOCK_ABOUT for About
	dialogs.

	* app/actions/actions.c
	* app/actions/brushes-actions.c
	* app/actions/channels-actions.c
	* app/actions/channels-commands.c
	* app/actions/colormap-editor-actions.c
	* app/actions/gradients-actions.c
	* app/actions/layers-actions.c
	* app/actions/layers-commands.c
	* app/actions/palette-editor-actions.c
	* app/actions/palettes-actions.c
	* app/actions/patterns-actions.c
	* app/actions/templates-actions.c
	* app/actions/templates-commands.c
	* app/actions/text-editor-actions.c
	* app/actions/tool-options-actions.c
	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.c
	* app/tools/gimptexttool.c
	* app/widgets/gimpcontrollereditor.c
	* app/widgets/gimpcontrollerlist.c
	* plug-ins/flame/flame.c
	* plug-ins/gflare/gflare.c
	* plug-ins/gimpressionist/orientation.c
	* plug-ins/gimpressionist/size.c
	* plug-ins/metadata/interface.c: s/GIMP_STOCK_EDIT/GTK_STOCK_EDIT/
2005-09-19 13:07:24 +00:00
Sven Neumann ad5287c3ba app/actions/image-commands.c app/actions/layers-commands.c
2005-08-24  Sven Neumann  <sven@gimp.org>

	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/dialogs/image-scale-dialog.c
	* app/dialogs/resize-dialog.[ch]: remember the selected unit for
	scale and resize dialogs on a per-image basis (bug #312950).
2005-08-24 17:22:07 +00:00
Michael Natterer 4c6d9ddd78 new function.
2005-08-07  Michael Natterer  <mitch@gimp.org>

	* app/core/gimplayer.[ch] (gimp_layer_flatten): new function.

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]
	* app/widgets/gimphelp-ids.h
	* menus/image-menu.xml.in
	* menus/layers-menu.xml: added "Remove Alpha Channel" action,
	action callback, help ID and menu items. Fixes bug #309762.
2005-08-07 16:38:35 +00:00
Michael Natterer 20b4769cf5 app/actions/layers-actions.c app/actions/layers-commands.[ch]
2005-07-10  Michael Natterer  <mitch@gimp.org>

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]
	* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.[ch]
	* app/text/gimptextlayer-xcf.c
	* app/widgets/gimphelp-ids.h
	* app/widgets/gimplayertreeview.[ch]
	* app/xcf/xcf-load.c
	* app/xcf/xcf-private.h
	* app/xcf/xcf-save.c
	* tools/pdbgen/pdb/layer.pdb
	* menus/image-menu.xml.in
	* libgimp/gimp.def: did a global s/preserve_trans/lock_alpha/ in
	preparation for more layer locking flags.

	* app/pdb/procedural_db.c
	* libgimp/gimplayer.[ch]: added compat stuff for preserve_trans.

	* app/pdb/layer_cmds.c
	* libgimp/gimplayer_pdb.[ch]: regenerated.

	* plug-ins/common/colortoalpha.c
	* plug-ins/common/iwarp.c
	* plug-ins/common/psd.c
	* plug-ins/common/psd_save.c
	* plug-ins/common/psp.c
	* plug-ins/common/rotate.c
	* plug-ins/common/threshold_alpha.c
	* plug-ins/common/vpropagate.c
	* plug-ins/script-fu/scripts/3d-outline.scm
	* plug-ins/script-fu/scripts/alien-glow-bar.scm
	* plug-ins/script-fu/scripts/alien-glow-bullet.scm
	* plug-ins/script-fu/scripts/alien-glow-logo.scm
	* plug-ins/script-fu/scripts/basic1-logo.scm
	* plug-ins/script-fu/scripts/basic2-logo.scm
	* plug-ins/script-fu/scripts/beveled-pattern-button.scm
	* plug-ins/script-fu/scripts/blend-anim.scm
	* plug-ins/script-fu/scripts/blended-logo.scm
	* plug-ins/script-fu/scripts/bovinated-logo.scm
	* plug-ins/script-fu/scripts/burn-in-anim.scm
	* plug-ins/script-fu/scripts/carved-logo.scm
	* plug-ins/script-fu/scripts/chalk.scm
	* plug-ins/script-fu/scripts/chip-away.scm
	* plug-ins/script-fu/scripts/comic-logo.scm
	* plug-ins/script-fu/scripts/coolmetal-logo.scm
	* plug-ins/script-fu/scripts/crystal-logo.scm
	* plug-ins/script-fu/scripts/drop-shadow.scm
	* plug-ins/script-fu/scripts/gimp-headers.scm
	* plug-ins/script-fu/scripts/gimp-labels.scm
	* plug-ins/script-fu/scripts/glowing-logo.scm
	* plug-ins/script-fu/scripts/gradient-bevel-logo.scm
	* plug-ins/script-fu/scripts/image-structure.scm
	* plug-ins/script-fu/scripts/neon-logo.scm
	* plug-ins/script-fu/scripts/perspective-shadow.scm
	* plug-ins/script-fu/scripts/starburst-logo.scm
	* plug-ins/script-fu/scripts/starscape-logo.scm
	* plug-ins/script-fu/scripts/textured-logo.scm
	* plug-ins/script-fu/scripts/title-header.scm
	* plug-ins/script-fu/scripts/waves-anim.scm
	* plug-ins/xjt/xjt.c: changed accordingly.
2005-07-10 21:17:22 +00:00
Michael Natterer 46a25c2c60 app/core/core-enums.[ch] app/core/gimpimage-undo-push.[ch] eek, my
2005-03-24  Michael Natterer  <mitch@gimp.org>

	* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]
	* app/core/gimplayermask.[ch]: eek, my fault... removed
	GIMP_UNDO_LAYER_MASK_EDIT stuff again because that just determines
	the active drawable, which must not affect undo.

	* app/pdb/pdb_glue.h
	* app/actions/layers-commands.c (layers_mask_edit_cmd_callback):
	changed accordingly.

	(layers_mask_disable_cmd_callback): reverted last change. the old
	code was correct.
2005-03-24 22:34:36 +00:00
William Skaggs b5f1ae88e2 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]
	* app/core/gimplayermask.[ch]:
	* app/pdb/pdb_glue.h
	* app/actions/layers-commands.c: try again from clean tree;
	hopefully will work this time.  (bug #148852)
2005-03-24 17:10:03 +00:00
Sven Neumann 4314dca031 app/actions/layers-commands.c app/core/core-enums.[ch]
2005-03-24  Sven Neumann  <sven@gimp.org>

	* app/actions/layers-commands.c
	* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]
	* app/pdb/pdb_glue.h: reverted Bill's changes to fix the build.
2005-03-24 10:34:41 +00:00
William Skaggs 72241e5ed2 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]
	* app/pdb/pdb_glue.h
	* app/actions/layers-commands.c: make layer mask property changes
	undoable, should fix bug #148852.  Note that a little shape-layer
	stuff is in core-enums, will be needed shortly.
2005-03-24 02:16:40 +00:00
Michael Natterer 03182eba8d Allow to resize layers with the image. Fixes bug #87789.
2005-02-24  Michael Natterer  <mitch@gimp.org>

	Allow to resize layers with the image. Fixes bug #87789.

	* app/core/core-enums.[ch]: added enum GimpImageResizeLayers which
	can be one of { NONE, MATCHING, ALL }.

	* app/core/gimpimage-resize.[ch]: added new function
	gimp_image_resize_with_layers().

	* app/dialogs/resize-dialog.[ch]: added a "Layers" frame
	containing a "Resize Layers" combo box offering the choices above.
	Changed GimpResizeCallback signature accordingly.

	* app/actions/image-commands.c
	* app/actions/layers-commands.c: changed accordingly.
2005-02-24 16:39:12 +00:00
Sven Neumann 279d901051 do not set the "layers-mask-add" action insensitive if there's no alpha
2004-10-28  Sven Neumann  <sven@gimp.org>

	* app/actions/layers-actions.c (layers_actions_update): do not set
	the "layers-mask-add" action insensitive if there's no alpha channel.

	* app/actions/layers-commands.c (layers_add_mask_response): add an
	alpha channel if there isn't one already. Fixes bug #156676.
2004-10-28 10:53:44 +00:00
Sven Neumann 52252cf0d6 started to redo the Resize dialog in the style of the new Scale dialog.
2004-10-27  Sven Neumann  <sven@gimp.org>

	* app/dialogs/resize-dialog.[ch]: started to redo the Resize
	dialog in the style of the new Scale dialog. Only halfway done but
	at least the new API is there.

	* app/actions/image-commands.c
	* app/actions/layers-commands.c: changed accordingly.

	* app/dialogs/image-scale-dialog.c: cosmetics.
2004-10-27 10:33:08 +00:00
Sven Neumann fffebe8ec2 app/dialogs/Makefile.am a wrapper around the scale dialog that takes care
2004-10-27  Sven Neumann  <sven@gimp.org>

	* app/dialogs/Makefile.am
	* app/dialogs/image-scale-dialog.[ch]: a wrapper around the scale
	dialog that takes care verifying the user input and optionally
	asking for confirmation. Most of this moved out of image-commands.c.

	* app/actions/image-commands.c: use the new image scale dialog
	even though it doesn't allow to edit the resolution yet. That's a
	temporary regression that will get fixed soon.

	* app/actions/layers-commands.c: cosmetics.

	* app/dialogs/scale-dialog.c (scale_dialog_reset): also reset the
	resolution.

	* app/widgets/gimpsizebox.c: fixed cut'n'paste error.
2004-10-27 01:20:07 +00:00
Sven Neumann b0330f95d4 added a resolution label similar to one in the template editor. Prepared
2004-10-27  Sven Neumann  <sven@gimp.org>

	* app/widgets/gimpsizebox.[ch]: added a resolution label similar
	to one in the template editor. Prepared for editable resolution,
	work in progress...

	* app/dialogs/scale-dialog.[ch]: added resolution and resolution
	unit parameters to ScaleDialogCallback.

	* app/actions/layers-commands.c: changed accordingly.
2004-10-26 23:31:34 +00:00
Michael Natterer fa79ae2844 don't g_return_if_fail() if there is no active drawable, just silently
2004-10-23  Michael Natterer  <mitch@gimp.org>

	* app/actions/file-commands.c (file_save_cmd_callback): don't
	g_return_if_fail() if there is no active drawable, just silently
	return.

	* app/actions/image-commands.c: remember the last merge_type of
	the "Merge Visible Layers" dialog.

	* app/actions/layers-commands.c: remeber the last values of the
	"Add Layer Mask" dialog.

	* app/actions/select-commands.c: renamed a bunch of static
	variables to be consistent with other variables used to remember
	dialog values.

	* app/actions/view-commands.c (view_fullscreen_cmd_callback): it's
	useless to update the "view-fullscreen" actions here because the
	"fullscreen" state of the shell changes asynchronously
2004-10-23 19:13:17 +00:00
Michael Natterer cbaf441fb4 app/dialogs/Makefile.am one more dialog split out of actions/.
2004-10-23  Michael Natterer  <mitch@gimp.org>

	* app/dialogs/Makefile.am
	* app/dialogs/layer-add-mask-dialog.[ch]: one more dialog split
	out of actions/.

	* app/actions/layers-commands.c: removed it here. Some cleanup.
2004-10-23 14:02:53 +00:00
Michael Natterer fd6d30fd30 When there are variants of actions with and without dialog, let the
2004-10-23  Michael Natterer  <mitch@gimp.org>

	When there are variants of actions with and without dialog, let
	the dialog-less actions try to use the values from the last dialog
	invocation:

	* app/actions/channels-actions.c
	* app/actions/channels-commands.[ch]
	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]
	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.[ch]: renamed the foo-new-defaults
	actions to foo-new-last-values and use the last values entered in
	the dialogs.

	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpvectorstreeview.c: changed accordingly. Show
	the dialog on clicking "New" and call the last-values action on
	<shift>+click.

	* app/actions/select-actions.c
	* app/actions/vectors-commands.c: renamed the foo-stroke-last-vals
	to -last-values.

	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimpvectorstreeview.c: stroke with last values on
	<shift> clicking the stroke buttons.
2004-10-23 00:53:48 +00:00
Michael Natterer 5346f26bea app/dialogs/Makefile.am the new/edit layer dialog.
2004-10-23  Michael Natterer  <mitch@gimp.org>

	* app/dialogs/Makefile.am
	* app/dialogs/layer-options-dialog.[ch]: the new/edit layer dialog.

	* app/actions/layers-commands.c: use it here.
2004-10-22 22:28:45 +00:00
Michael Natterer c49df22eef Action code review and pre-release consistency cleanup:
2004-10-18  Michael Natterer  <mitch@gimp.org>

	Action code review and pre-release consistency cleanup:

	* app/actions/*-actions.c: added some missing and resolved
	conflicting mnemonics, added missing help IDs. Cleaned up the
	*_actions_update() functions.

	* app/actions/channels-actions.c
	* app/actions/layers-actions.c
	* app/actions/vectors-actions.c (*_actions_update): simplified
	the code that figures the prev and next channel,layer,vectors.

	* app/actions/qmask-actions.c: use the same accelerator for
	"qmask-active" and "qmask-toggle". Fixed action sensitivity.

	* app/actions/channels-commands.c
	* app/actions/dockable-commands.c
	* app/actions/documents-commands.c
	* app/actions/gradients-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/image-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c: folded tons of private utility
	functions into their only callers (they used to be public and
	called from outside before the switch to action based menus).
	Renamed functions and variables saying "query" or "qbox" to
	"dialog". Moved static functions to the end of the files. Misc
	minor cleanups.

	* app/actions/drawable-actions.c
	* app/actions/drawable-commands.c: made the "drawable-visible" and
	"drawable-linked" actions affect the layer if the active drawable
	is a layer mask.

	* app/actions/select-commands.c: added action to stroke with the
	last values used in an attempt to address bug #135746 but #if 0'ed
	it because the approach is too ugly.

	* app/tools/gimpiscissorstool.c: changed mnemonic from I to S.

	* menus/image-menu-xml.in: added more stuff to the (commented out)
	"context" menu.
2004-10-18 11:29:58 +00:00
Michael Natterer 8effb0cfaf Ported the layers, channels and paths dialogs from
2004-10-16  Michael Natterer  <mitch@gimp.org>

	Ported the layers, channels and paths dialogs from
	gimp_editor_add_button() to gimp_editor_add_action_button(),
	removing a massive amount of duplicated code, sensitivity logic
	and confusing utility functions.

	* app/actions/channels-actions.c
	* app/actions/channels-commands.[ch]
	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]
	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.[ch]: added "foo-new-default"
	actions and callbacks which create items without a dialog,
	optionally using default values from a passed template. Removed
	all public utility function that were passed as function pointers
	to widget construtors. Added tooltips to all actions which are now
	used for dialog buttons.

	* app/widgets/gimpeditor.c (gimp_editor_add_action_button):
	automatically create multi-line tooltips showing the modifiers for
	extended action buttons. Removes the need for lots of insane
	format strings that need to be translated correctly.

	* app/widgets/gimpitemtreeview.[ch] (struct GimpItemTreeViewClass):
	replaced tooltip and help_id strings by action names.

	(struct GimpItemTreeView)
	(gimp_item_tree_view_new): removed "edit", "new" and "activate"
	function pointers.

	(gimp_item_tree_view_constructor): create all buttons
	with gimp_editor_add_action_button(), using the action names
	from GimpItemTreeViewClass.

	Removed tons of "clicked" callbacks and all code which sets the
	buttons' sensitivity. They are not needed any longer.

	Require all subclasses to implement GimpItemTreeView::new_item(),
	a new virtual function which creates a plain new item without
	showing a dialog.

	* app/widgets/gimpdrawabletreeview.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpvectorstreeview.c: fill in the action names and
	implement GimpItemTreeView::new_item(). Removed all button
	sensitivity logic.

	* app/dialogs/dialogs-constructors.c: changed accordingly. Doesn't
	include anything from actions/ any more.
2004-10-16 15:48:23 +00:00
Michael Natterer 27c2be7cea libgimpwidgets/gimpwidgets.c app/widgets/gimpenumwidgets.[ch]
2004-10-14  Michael Natterer  <mitch@gimp.org>

	* libgimpwidgets/gimpwidgets.c
	* app/widgets/gimpenumwidgets.[ch]
	* app/widgets/gimppropwidgets.c
	* app/actions/layers-commands.c
	* app/dialogs/convert-dialog.c
	* app/tools/gimpblendoptions.c
	* app/tools/gimpbucketfilloptions.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimpcoloroptions.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpinkoptions-gui.c
	* app/tools/gimplevelstool.c
	* app/tools/gimppaintoptions-gui.c
	* app/tools/gimpselectionoptions.c
	* app/tools/gimptransformoptions.c: the child of a GimpFrame must
	not have any border width. Fixes many subtle misalignments.
2004-10-14 15:44:13 +00:00
Sven Neumann 22a1384b5a app/widgets/Makefile.am app/widgets/widgets-types.h added new widget
2004-10-12  Sven Neumann  <sven@gimp.org>

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpsizebox.[ch]: added new widget GimpSizeBox.

	* app/widgets/gimppropwidgets.c: the order of setting the X and Y
	properties does matter.

	* app/dialogs/Makefile.am
	* app/dialogs/scale-dialog.[ch]: added first version of a new
	Scale dialog in an attempt to address bug #151022.

	* app/actions/layers-commands.c: use the new scale dialog.
2004-10-12 14:59:14 +00:00
Michael Natterer 49b9c1d80e app/actions/buffers-commands.c app/actions/file-commands.c
2004-09-20  Michael Natterer  <mitch@gimp.org>

	* app/actions/buffers-commands.c
	* app/actions/file-commands.c
	* app/actions/layers-commands.c
	* app/actions/plug-in-actions.c
	* app/actions/tools-actions.c: removed useless #includes, cleanup.
2004-09-20 14:43:46 +00:00
Michael Natterer b9800e449f app/actions/channels-commands.c removed massive code duplication by
2004-09-20  Michael Natterer  <mitch@gimp.org>

	* app/actions/channels-commands.c
	* app/actions/vectors-commands.c: removed massive code duplication
	by factoring out the code that creates the "New Channel/Path" and
	"Edit Channel/Path Attributes" dialogs out to utility functions.
	GUI spacing and Code cleanup.

	* app/actions/layers-commands.c: minor GUI spacing and code
	cleanup.
2004-09-19 22:26:41 +00:00
Sven Neumann c3ef897b10 Try to make floating selections more obvious:
2004-09-19  Sven Neumann  <sven@gimp.org>

	Try to make floating selections more obvious:

	* app/widgets/gimplayertreeview.c
	(gimp_layer_tree_view_floating_selection_changed): always display
	"Floating Selection" as the name for a floating selection.

	* app/core/gimpselection.c (gimp_selection_float): call the new
	layer "Selection" instead of "Floating Selection". This is what
	will be displayed if the FS is turned into a layer.

	* app/actions/layers-commands.c (layers_edit_layer_query): don't
	special case floating selections here.

	* app/core/gimplayer-floating-sel.c: cosmetics.
2004-09-19 16:56:03 +00:00
Michael Natterer 186b590844 added help IDs for the drawable- and vectors-visible and -liked actions as
2004-09-15  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimphelp-ids.h: added help IDs for the drawable- and
	vectors-visible and -liked actions as well as for the layer mask
	property action.

	* app/actions/drawable-actions.c
	* app/actions/vectors-actions.c: use them.

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]: ditto. Use
	GIMP_STOCK_TRANSPARENCY for all layer opacity actions. Replaced
	"paint_mode" by "mode" in all action and function/variable names
	because this is the layer mode, not a paint mode.

	* app/actions/channels-commands.c
	* app/actions/layers-commands.c
	* app/actions/vectors-commands.c: set the "activates-default"
	property on the name entry in all "New Foo" and "Edit Foo
	Attributes" dialogs except in the "New Layer" dialog.
	Addresses bug #148026.

	* menus/image-menu.xml.in: added a (commented out) layer
	properties menu containing all the new actions.
2004-09-15 15:06:08 +00:00
Michael Natterer 6a723efc4b app/actions/layers-actions.c added actions and callbacks
2004-09-15  Michael Natterer  <mitch@gimp.org>

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]: added actions and callbacks
	"layers-preserve-transparency" and
	"layers-paint-mode-first,last,previous,next". Update the "active"
	state of the recently added layer mask property actions in
	layers_actions_update().

	* app/actions/drawable-actions.c
	* app/actions/drawable-commands.[ch]: added actions and callbacks
	for "drawable-visible" and "drawable-linked". Fixes bug #152597.

	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.[ch]: same here ("vectors-visible"
	and "vectors-linked").

	* app/widgets/gimplayertreeview.c
	(gimp_layer_tree_view_preserve_button_toggled): flush the image
	so the new actions are updated. Compress preserve_trans undos.

	* menus/image-menu.xml.in: added the layer mask property actions
	to the Layers/Mask submenu.

	* menus/layers-menu.xml: reordered the mask property actions
	to have the same order as in the image menu.
2004-09-15 13:24:45 +00:00
Michael Natterer 7d065360c7 configure.in added new directory app/dialogs and link libappdialogs.c into
2004-09-13  Michael Natterer  <mitch@gimp.org>

	* configure.in
	* app/Makefile.am: added new directory app/dialogs and link
	libappdialogs.c into the gimp binary.

	* app/gui/Makefile.am
	* app/gui/gui-types.h
	* app/gui/gui-vtable.c
	* app/gui/gui.c

	* app/gui/about-dialog.[ch]
	* app/gui/authors.h
	* app/gui/color-notebook.[ch]
	* app/gui/convert-dialog.[ch]
	* app/gui/dialogs-constructors.[ch]
	* app/gui/dialogs.[ch]
	* app/gui/file-dialog-utils.[ch]
	* app/gui/file-new-dialog.[ch]
	* app/gui/file-open-dialog.[ch]
	* app/gui/file-open-location-dialog.[ch]
	* app/gui/file-save-dialog.[ch]
	* app/gui/grid-dialog.[ch]
	* app/gui/info-dialog.[ch]
	* app/gui/info-window.[ch]
	* app/gui/module-browser.[ch]
	* app/gui/offset-dialog.[ch]
	* app/gui/palette-import-dialog.[ch]
	* app/gui/preferences-dialog.[ch]
	* app/gui/quit-dialog.[ch]
	* app/gui/resize-dialog.[ch]
	* app/gui/resolution-calibrate-dialog.[ch]
	* app/gui/stroke-dialog.[ch]
	* app/gui/tips-dialog.[ch]
	* app/gui/tips-parser.[ch]
	* app/gui/user-install-dialog.[ch]: removed these files...

	* app/dialogs/Makefile.am
	* app/dialogs/dialogs-types.h

	* app/dialogs/*.[ch]: ...and added them here. Changed some
	filenames like module-browser -> module-dialog.

	* app/app_procs.c
	* app/actions/actions-types.h
	* app/actions/actions.c
	* app/actions/dialogs-actions.c
	* app/actions/dialogs-commands.c
	* app/actions/dockable-commands.c
	* app/actions/drawable-commands.c
	* app/actions/edit-commands.c
	* app/actions/file-commands.c
	* app/actions/gradient-editor-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/select-commands.c
	* app/actions/templates-commands.c
	* app/actions/templates-commands.h
	* app/actions/vectors-commands.c
	* app/actions/view-commands.c
	* app/display/gimpdisplayshell-cursor.c
	* app/display/gimpdisplayshell-title.c
	* app/display/gimpdisplayshell.[ch]
	* app/tools/gimpcroptool.c
	* app/tools/gimpperspectivetool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/tools/gimpsheartool.c
	* app/tools/gimptransformtool.[ch]
	* app/tools/gimpvectortool.c
	* app/widgets/gimpcolormapeditor.[ch]
	* app/widgets/gimpcolorpanel.c
	* app/widgets/gimpgradienteditor.[ch]
	* app/widgets/gimppaletteeditor.[ch]
	* app/widgets/gimptoolbox-color-area.c
	* menus/toolbox-menu.xml.in
	* tools/authorsgen/authorsgen.pl: changed accordingly.
2004-09-13 15:15:23 +00:00
Sven Neumann c9ef65d045 formatting fixups 2004-08-20 23:01:18 +00:00
Sven Neumann c04ddea85e app/actions/layers-actions.[ch] app/actions/layers-commands.[ch] added
2004-08-21  Sven Neumann  <sven@gimp.org>

	* app/actions/layers-actions.[ch]
	* app/actions/layers-commands.[ch]
	* app/widgets/gimplayertreeview.c: added actions to handle layer
	masks as suggested in bug #150446.

	* menus/layers-menu.xml: added menu entries for new actions,
	commented out raise/lower menu entries.
2004-08-20 22:32:14 +00:00
Michael Natterer 02d2b990f5 Redid the whole internal progress stuff: don't pass around
2004-08-10  Michael Natterer  <mitch@gimp.org>

	Redid the whole internal progress stuff: don't pass around
	progress_callback and progress_data; instead, provide a
	pointer to a GimpProgressInterface which can be implemented
	by a variety of backends.

	Addresses (but not yet fixes) bugs #6010, #97266 and #135185.

	* app/display/Makefile.am
	* app/display/gimpprogress.[ch]: removed the old progress hack.

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpprogress.[ch]: implement GimpProgressInterface.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpprogressdialog.[ch]: the standalone progress
	dialog as widget implementing GimpProgressInterface.

	* app/display/gimpdisplay.c
	* app/display/gimpstatusbar.[ch]
	* app/widgets/gimpfiledialog.[ch]
	* app/widgets/gimpthumbbox.[ch]: added GimpProgressInterface
	implementation to these classes.

	* app/core/gimp-gui.[ch]
	* app/gui/gui-vtable.c: replaced the old progress vtable entries
	by two new to create and destroy a GimpProgressDialog in case
	no other progress is available.

	* app/pdb/procedural_db.[ch]
	* app/plug-in/plug-in-run.[ch]
	* tools/pdbgen/app.pl: pass a GimpProgress to all PDB wrappers and
	all plug-ins.

	* app/plug-in/plug-in.[ch]
	* app/plug-in/plug-ins.c
	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-in-progress.c: handle the case there the
	plug-in was crated with a progress as well as the case where it
	wasn't.

	* app/app_procs.c
	* app/batch.c
	* app/xcf/xcf.c
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/widgets/gimphelp.c
	* app/widgets/gimpbrushselect.c
	* app/widgets/gimpfontselect.c
	* app/widgets/gimpgradientselect.c
	* app/widgets/gimppaletteselect.c
	* app/widgets/gimppatternselect.c: changed accordingly.

	* app/core/gimpimagefile.[ch]
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/file-open-dialog.c
	* app/gui/file-open-location-dialog.c
	* app/gui/file-save-dialog.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c: pass a GimpProgress to all file
	related functions. Embed the progress in the file dialog where
	possible.

	* app/core/gimpdrawable-blend.[ch]
	* app/core/gimpdrawable-transform.[ch]
	* app/core/gimpimage-convert.[ch]
	* app/core/gimpimage-flip.[ch]
	* app/core/gimpimage-resize.[ch]
	* app/core/gimpimage-rotate.[ch]
	* app/core/gimpimage-scale.[ch]
	* app/core/gimpitem-linked.[ch]
	* app/core/gimpitem.[ch]
	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/core/gimplayer.c
	* app/core/gimpselection.c
	* app/vectors/gimpvectors.c: replaced callback/data by GimpProgress.

	* app/tools/gimpblendtool.c
	* app/tools/gimptransformtool.c
	* app/gui/convert-dialog.c
	* app/actions/documents-commands.c
	* app/actions/file-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/plug-in-commands.c
	* app/actions/vectors-commands.c
	* tools/pdbgen/pdb/convert.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb: changed callers accordingly.

	* app/pdb/*_cmds.c: regenerated.
2004-08-10 18:47:21 +00:00
Michael Natterer b909c2b2ee new function which checks if undo compression is possible:
2004-08-03  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage-undo.[ch] (gimp_image_undo_can_compress):
	new function which checks if undo compression is possible:

	(1) is the image dirty? Fixes bug #148853.
	(2) is redo stack empty?
	(3) do both the passed undo object_type and undo_type
	    match the top undo item?

	Consistently name the GType and GimpUndoType passed to undo
	functions "object_type" and "undo_type" to avoid confusion.

	* app/actions/layers-commands.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimptexttool.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimplayertreeview.c: use the new utility function
	instead of checking the above conditions manually.
2004-08-03 14:09:49 +00:00
Michael Natterer d88f23ddba removed enum GimpContextSelectType.
2004-06-23  Michael Natterer  <mitch@gimp.org>

	* app/actions/context-commands.h: removed enum GimpContextSelectType.

	* app/actions/actions-types.h: added enum GimpActionSelectType.

	* app/actions/actions.[ch]: added utility functions
	action_select_value() and action_select_object().

	* app/actions/context-actions.c
	* app/actions/context-commands.c: changed accordingly.

	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]: merged the layer select
	callbacks into one using the GimpActionSelectType functions. Added
	actions and callbacks for modifying the active layer's opacity.

	* app/menus/menus-types.h: #incude "actions/action-types.h".

	* app/gui/gui-types.h: #incude "menus/menus-types.h".

	* app/gui/preferences-dialog.c: allow to enable/disable input
	controllers.
2004-06-23 00:23:25 +00:00
Michael Natterer 63e5c04716 app/actions/image-actions.c app/actions/image-commands.[ch]
2004-06-10  Michael Natterer  <mitch@gimp.org>

	* app/actions/image-actions.c
	* app/actions/image-commands.[ch]
	* app/actions/layers-actions.c
	* app/actions/layers-commands.[ch]: made the
	"image-convert-rgb/grayscale/indexed" and the
	"layers-mask-apply/delete" actions GimpEnumActions and merged
	their callbacks.
2004-06-10 14:25:04 +00:00
Sven Neumann c509204b7d tools/pdbgen/pdb/image.pdb app/pdb/image_cmds.c reverted changes I did to
2004-06-01  Sven Neumann  <sven@gimp.org>

	* tools/pdbgen/pdb/image.pdb
	* app/pdb/image_cmds.c
	* app/core/gimpimage.[ch]: reverted changes I did to the image
	unit earlier. As in 2.0, it will continue to not accept pixels.
	This makes the PDB API and the XCF format compatible again and
	fixes bug #142961 (and to some extent bug #137704).

	* app/core/Makefile.am
	* app/core/gimpimage-unit.[ch]: removed these files. The
	convenience accessors defined here aren't commonly used any
	longer.

	* app/display/gimpdisplay.[ch]
	* app/display/gimpdisplayshell.[ch]: added a unit parameter to
	gimp_display_new(). Made "unit" and "scale" properties of
	GimpDisplayShell.

	* app/actions/image-commands.c
	* app/actions/images-commands.c
	* app/actions/layers-commands.c
	* app/actions/select-commands.c
	* app/actions/view-commands.c
	* app/core/gimp-edit.c
	* app/core/gimp.[ch]
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-handlers.c
	* app/display/gimpdisplayshell-scale.c
	* app/display/gimpdisplayshell-title.c
	* app/display/gimpstatusbar.c
	* app/file/file-open.c
	* app/gui/gui-vtable.c
	* app/gui/info-window.c
	* app/gui/offset-dialog.c
	* app/gui/resize-dialog.[ch]
	* app/pdb/display_cmds.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppainttool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimptoolbox-dnd.c
	* tools/pdbgen/pdb/display.pdb: changed accordingly. Use the
	display unit where the image unit was used before.
2004-06-01 22:04:20 +00:00
Michael Natterer 18d2d499b5 added GimpContext parameters to GimpActivateItemFunc, GimpNewItemFunc and
2004-05-25  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpitemtreeview.h: added GimpContext parameters
	to GimpActivateItemFunc, GimpNewItemFunc and GimpEditItemFunc.

	* app/widgets/gimpdrawabletreeview.c
	* app/widgets/gimpitemtreeview.c: pass the view's context to
	the functions.

	* app/actions/actions.c (action_data_get_context): return
	gimp_get_user_context() if "data" is a Gimp.

	* app/actions/channels-commands.[ch]
	* app/actions/layers-commands.[ch]
	* app/actions/vectors-commands.[ch]: added GimpContext parameters
	to the resp. activate, new and edit functions and use the passed
	context instead of gimp_get_user_context().

	* app/actions/layers-commands.[ch]: removed the merge and flatten
	callbacks.

	* app/actions/image-commands.[ch]: made public layer merge utility
	function private and cleaned the whole file up a lot.

	* app/actions/layers-actions.c: use the callbacks from
	image-commands.c for merge and flatten.

	* app/actions/edit-commands.c
	* app/actions/file-commands.c
	* app/actions/select-commands.c: use action_data_get_context()
	instead of gimp_get_user_context().

	* app/actions/edit-actions.c: some cleanup.
2004-05-25 14:37:02 +00:00
Michael Natterer 2632cd8f64 app/actions/documents-actions.c app/actions/documents-commands.c
2004-05-12  Michael Natterer  <mitch@gimp.org>

	* app/actions/documents-actions.c
	* app/actions/documents-commands.c
	* app/actions/edit-actions.c
	* app/actions/edit-commands.[ch]
	* app/actions/layers-actions.c
	* app/actions/layers-commands.c
	* app/actions/select-actions.c
	* app/actions/select-commands.[ch]
	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.[ch]: added tooltips for actions
	which are now used for dialog buttons, added callback
	implementations which formerly lived in various widgets, moved
	some actions around and did some general cleanups.

	* menus/image-menu.xml.in: s/edit-stroke/select-stroke/

	* menus/Makefile.am
	* menus/selection-editor-menu.xml: new popup menu.

	* app/menus/menus.c: register <SelectionEditor> and <UndoEditor>
	UI managers.

	* app/widgets/gimpeditor.[ch]: added construct properties
	"menu-factory", "menu-identifier", "ui-path" and "popup-data".
	Implement GObject::constructor() and create the UI manager
	if all needed properties were set. Enables creating action
	buttons at widget construction time because they need a
	UI manager.

	(gimp_editor_add_action_button): changed to take a va_list of
	"extended" actions which are invoked if the resp. button emits
	"extended_clicked". Store the actions and their modifier masks in
	a list attached to the button.

	* app/widgets/gimpcontainerview.c
	(gimp_container_view_item_selected): if the view has container
	*and* context, simply change the context and return.

	(gimp_container_view_context_changed): don't emit "select_item"
	manually but simply call gimp_container_view_select_item().

	(gimp_container_view_viewable_dropped): use
	gimp_container_view_item_selected() instead of changing the
	context directly.

	* app/widgets/gimpcontainereditor.c
	(gimp_container_editor_select_item): update the UI manager.

	* app/widgets/gimpdockable.c: don't try to fiddle with the
	dialog's menu if it doesn't have a ui_path (happens if the UI
	manager is just a collection of actions for the dialog buttons and
	has no menu registered).

	* app/widgets/gimpimageeditor.c: connect to the image's "flush"
	signal and update the UI manager in the callback.

	* app/widgets/gimpitemtreeview.c: use GimpEditor's construct
	properties to create the UI manager so GimpItemTreeView subclasses
	can have action buttons. Update the UI manager in
	gimp_item_tree_view_select_item().

	* app/widgets/gimpbufferview.c
	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpdatafactoryview.c
	* app/widgets/gimpfontview.c
	* app/widgets/gimpimageview.c
	* app/widgets/gimptemplateview.c
	* app/widgets/gimptoolview.c: changed calls to
	gimp_editor_add_action_button() accordingly and removed some
	unneeded select_item() implementations.

	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpvectorstreeview.[ch]
	* app/widgets/gimpdocumentview.[ch]
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpselectioneditor.[ch]
	* app/widgets/gimpundoeditor.[ch]: use action buttons and removed
	lots of callbacks which went to the resp. action callbacks.

	* app/widgets/widgets-types.h: removed some now unneeded function
	prototypes.

	* app/gui/dialogs-constructors.c: changed (simplified) many dialog
	constructors accordingly.
2004-05-12 18:36:33 +00:00
Sven Neumann 6750667d87 libgimpwidgets/gimpwidgets.c (gimp_scale_entry_new_internal) left-align
2004-05-12  Sven Neumann  <sven@gimp.org>

	* libgimpwidgets/gimpwidgets.c (gimp_scale_entry_new_internal)
	* app/widgets/gimpwidgets-utils.c (gimp_table_attach_stock):
	left-align the label.

	* app/actions/channels-commands.c
	* app/actions/layers-commands.c
	* app/actions/qmask-commands.c
	* app/actions/vectors-commands.c
	* app/display/gimpdisplayshell-scale.c
	* app/gui/brush-select.c
	* app/gui/file-new-dialog.c
	* app/gui/info-dialog.c
	* app/gui/info-window.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/preferences-dialog.c
	* app/gui/resize-dialog.c
	* app/tools/gimpblendoptions.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppaintoptions-gui.c
	* app/tools/gimpscaletool.c
	* app/tools/gimpselectionoptions.c
	* app/tools/gimpsheartool.c
	* app/tools/gimptextoptions.c
	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpgrideditor.c
	* app/widgets/gimphistogrameditor.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpstrokeeditor.c
	* app/widgets/gimpwidgets-utils.c: left-align labels as suggested
	by the HIG.
2004-05-12 11:37:21 +00:00
Sven Neumann 0582f559a8 ooops, should recompile before committing 2004-05-06 13:43:03 +00:00
Sven Neumann 8008d532e1 cleaned up variable names and external API. Still quite a mess.
2004-05-06  Sven Neumann  <sven@gimp.org>

	* app/gui/resize-dialog.[ch]: cleaned up variable names and
	external API. Still quite a mess.

	* app/Makefile.am
	* app/actions/image-commands.c
	* app/actions/layers-commands.c: changed accordingly.
2004-05-06 13:17:49 +00:00
Sven Neumann 122e2c78db app/actions/channels-commands.c app/actions/gradient-editor-commands.c
2004-05-04  Sven Neumann  <sven@gimp.org>

	* app/actions/channels-commands.c
	* app/actions/gradient-editor-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/qmask-commands.c
	* app/actions/templates-commands.c
	* app/actions/vectors-commands.c
	* app/display/gimpdisplayshell-filter-dialog.c
	* app/gui/convert-dialog.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/resize-dialog.c
	* app/gui/resolution-calibrate-dialog.c
	* app/gui/tips-dialog.c
	* app/gui/user-install-dialog.c
	* app/widgets/gimpwidgets-utils.c
	* libgimpwidgets/gimpquerybox.c: set dialog border spacing to 12.
2004-05-04 14:21:13 +00:00
Michael Natterer 3590757d2a app/actions/actions.h. added the various return_if_no_foo() macros here.
2004-05-03  Michael Natterer  <mitch@gimp.org>

	* app/actions/actions.h. added the various return_if_no_foo()
	macros here.

	* app/actions/channels-commands.c
	* app/actions/dialogs-commands.c
	* app/actions/drawable-commands.c
	* app/actions/edit-commands.c
	* app/actions/file-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/qmask-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/actions/view-commands.c: removed them here. Some cleanup.
2004-05-03 14:46:29 +00:00
Michael Natterer d745841e4d added some utility functions to get a Gimp, GimpImage, GimpDisplay and
2004-05-03  Michael Natterer  <mitch@gimp.org>

	* app/actions/actions.[ch]: added some utility functions to get a
	Gimp, GimpImage, GimpDisplay and GtkWidget from the "data" pointer
	passed to action callbacks.

	* app/actions/channels-actions.c
	* app/actions/channels-commands.c
	* app/actions/drawable-actions.c
	* app/actions/drawable-commands.c
	* app/actions/edit-actions.c
	* app/actions/edit-commands.c
	* app/actions/file-actions.c
	* app/actions/file-commands.c
	* app/actions/help-commands.c
	* app/actions/image-actions.c
	* app/actions/image-commands.c
	* app/actions/layers-actions.c
	* app/actions/layers-commands.c
	* app/actions/plug-in-actions.c
	* app/actions/plug-in-commands.c
	* app/actions/qmask-actions.c
	* app/actions/qmask-commands.c
	* app/actions/select-actions.c
	* app/actions/select-commands.c
	* app/actions/tools-commands.c
	* app/actions/vectors-actions.c
	* app/actions/vectors-commands.c
	* app/actions/view-commands.c: use the new functions instead of
	duplicating insane macros and if() constructs over and over again.
2004-05-03 14:03:51 +00:00
Michael Natterer 4654280114 Switch from GtkItemFactory to GtkUIManager. The migration is almost
2004-04-29  Michael Natterer  <mitch@gimp.org>

	Switch from GtkItemFactory to GtkUIManager. The migration is
	almost complete, still stuff missing/incomplete, definitely added
	a bunch of new bugs...

	* app/actions/*-commands.[ch]: converted all callback from
	GtkItemFactory callbacks to GtkAction callbacks.

	* app/actions/debug-actions.c
	* app/actions/gradient-editor-actions.c
	* app/actions/help-actions.c
	* app/actions/plug-in-actions.c
	* app/actions/qmask-actions.c
	* app/actions/tool-options-actions.c: various fixes.

	* app/display/gimpdisplay.[ch]
	* app/display/gimpdisplayshell-appearance.[ch]
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.[ch]: move everything from
	GtkItemFactory to GtkUIManager.

	* app/gui/dialogs.[ch]: added new function dialogs_get_toolbox().
	Needed because the action callbacks don't have a widget parameter
	and sometimes we need a parent window for showing dialogs.

	* app/gui/Makefile.am
	* app/gui/brushes-menu.[ch]
	* app/gui/buffers-menu.[ch]
	* app/gui/channels-menu.[ch]
	* app/gui/colormap-editor-menu.[ch]
	* app/gui/dialogs-menu.[ch]
	* app/gui/documents-menu.[ch]
	* app/gui/error-console-menu.[ch]
	* app/gui/fonts-menu.[ch]
	* app/gui/gradient-editor-menu.[ch]
	* app/gui/gradients-menu.[ch]
	* app/gui/images-menu.[ch]
	* app/gui/layers-menu.[ch]
	* app/gui/palette-editor-menu.[ch]
	* app/gui/palettes-menu.[ch]
	* app/gui/patterns-menu.[ch]
	* app/gui/qmask-menu.[ch]
	* app/gui/templates-menu.[ch]
	* app/gui/vectors-menu.[ch]: removed these files.

	* app/gui/gui.c: create a global UI manager for the image popup
	menu and the toolbox menubar.

	* app/gui/menus.[ch]: removed all GtkItemFactory code.

	* app/gui/image-menu.[ch]
	* app/gui/toolbox-menu.[ch]: removed everything except the trivial
	setup_funcs.

	* app/gui/file-open-menu.c
	* app/gui/file-save-menu.c
	* app/gui/tool-options-menu.c: don't use the macros from menus.h
	any more, they are gone.

	* app/gui/gui-vtable.c
	* app/gui/plug-in-menus.[ch]: create/destroy the dynamic plug-in
	menu entries.

	* app/tools/gimpimagemaptool.c: s/gimp_item_factory_update/
	gimp_ui_manager_update/g

	* app/widgets/gimpuimanager.[ch]: added API to get an action
	group by name.

	* app/widgets/gimpmenufactory.c: don't choke on the item_factory
	entries being NULL.

	* app/widgets/gimpactiongroup.c: make sure booleans set using
	g_object_set() only have TRUE or FALSE values.

	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcomponenteditor.c
	* app/widgets/gimpcontainereditor.[ch]
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimpdockable.[ch]
	* app/widgets/gimpdocked.[ch]
	* app/widgets/gimpeditor.[ch]
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimptooloptionseditor.c: removed all GtkItemFactory
	code and enable the #if 0'ed UI manager stuff.

	* menus/gradient-editor-menu.xml: fixed typos.

	* menus/image-menu.xml: duplicate everything so we have both
	an image menubar and an image popup menu. Badly cries for an
	XSL processor.

	* menus/toolbox-menu.xml: added an "Extensions" placeholder.
2004-04-29 12:52:29 +00:00
Michael Natterer 661f6ddeb8 removed...
2004-04-20  Michael Natterer  <mitch@gimp.org>

	* app/gui/*-commands.[ch]: removed...

	* app/actions/*-commands.[ch]: ...and added here.

	* app/gui/Makefile.am
	* app/gui/*-menu.c
	* app/gui/dialogs-constructors.c
	* app/gui/gui.c
	* app/gui/menus.c
	* app/actions/Makefile.am
	* app/actions/*-actions.c: changed accordingly.

	* app/actions/plug-in-actions.[ch]
	* app/actions/tools-actions.[ch]: new files.

	* app/Makefile.am: had to add more -u evilness because gui/
	and actions/ have cyclic dependencies.

	* menus/image-menu.xml: added some more items.
2004-04-20 13:25:55 +00:00
Sven Neumann 89cf45541a app/widgets/Makefile.am app/widgets/widgets-types.h removed GimpEnumMenu.
2004-04-18  Sven Neumann  <sven@gimp.org>

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpenummenu.[ch]: removed GimpEnumMenu.

	* app/widgets/gimpenumwidgets.[ch]: moved widget constructors that
	don't use GimpEnumMenu from gimpenummenu.[ch] to these new files.

	* app/widgets/gimpenumcombobox.[ch]: added a GtkComboBox widget
	using GimpEnumStore; replaces GimpEnumMenu.

	* app/widgets/gimpenumstore.[ch]: added new function
	gimp_enum_store_lookup_by_value().

	* app/widgets/gimppropwidgets.[ch]: replaced
	gimp_prop_enum_option_menu_new() with gimp_prop_enum_combo_box_new().

	* app/gui/brush-select.[ch]
	* app/gui/convert-dialog.c
	* app/gui/layers-commands.c
	* app/gui/preferences-dialog.c
	* app/gui/resize-dialog.c
	* app/tools/gimpblendoptions.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpmagnifytool.c
	* app/tools/gimppaintoptions-gui.c
	* app/tools/gimpselectionoptions.c
	* app/tools/gimptransformoptions.c
	* app/widgets/gimpcolorframe.c
	* app/widgets/gimpeditor.c
	* app/widgets/gimpgrideditor.c
	* app/widgets/gimphistogrameditor.c
	* app/widgets/gimpstrokeeditor.c
	* app/widgets/gimptemplateeditor.c
	* app/widgets/gimptexteditor.c: ported to GimpEnumComboBox.
2004-04-18 15:12:42 +00:00
Michael Natterer 18d9161eea Get rid of the "current_context" which was in fact just a bunch of global
2004-04-15  Michael Natterer  <mitch@gimp.org>

	Get rid of the "current_context" which was in fact just a bunch of
	global variables. Instead, pass the needed context all the way
	from the GUI and the PDB to the core. This is a prerequisite for
	macro recording and generally helps separating the various
	subsystems from each other. Work in progress...

	* app/core/gimp.[ch]: removed member "current_context" and
	gimp_[get|set]_current_context().

	* app/core/gimp-edit.[ch]
	* app/core/gimpdrawable-blend.[ch]
	* app/core/gimpdrawable-bucket-fill.[ch]
	* app/core/gimpdrawable-offset.[ch]
	* app/core/gimpdrawable-transform.[ch]
	* app/core/gimpimage-crop.[ch]
	* app/core/gimpimage-flip.[ch]
	* app/core/gimpimage-merge.[ch]
	* app/core/gimpimage-resize.[ch]
	* app/core/gimpimage-rotate.[ch]
	* app/core/gimpimage.[ch]
	* app/core/gimpimagefile.[ch]
	* app/core/gimpitem-linked.[ch]
	* app/core/gimpitem.[ch]
	* app/core/gimplayer.[ch]
	* app/core/gimpselection.[ch]
	* app/core/gimptemplate.[ch]
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/pdb/procedural_db.[ch]
	* app/text/gimptext-compat.[ch]
	* app/text/gimptextlayer-transform.[ch]
	* app/gui/brush-select.[ch]
	* app/gui/font-select.[ch]
	* app/gui/gradient-select.[ch]
	* app/gui/palette-select.[ch]
	* app/gui/pattern-select.[ch]: added tons of "GimpContext *context"
	parameters and use the passed context instead of
	gimp_get_current_context().

	* app/app_procs.c
	* app/batch.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/paint/gimperaser.c
	* app/paint/gimppaintbrush.c
	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-ins.c
	* app/text/gimptextlayer.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpinktool.c
	* app/tools/gimptransformtool.c
	* app/vectors/gimpvectors.c
	* app/gui/convert-dialog.c
	* app/gui/drawable-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/offset-dialog.c
	* app/gui/select-commands.c
	* app/gui/vectors-commands.c
	* app/widgets/gimpdnd.c
	* app/widgets/gimpdocumentview.c
	* app/widgets/gimphelp.c
	* app/widgets/gimpthumbbox.c: pass gimp_get_user_context() or
	GIMP_CONTEXT(tool_options) or whatever is the right context
	to the changed core functions.

	* tools/pdbgen/app.pl: pass "GimpContext *context" to all
	generated PDB invokers.

	* tools/pdbgen/pdb/brush_select.pdb
	* tools/pdbgen/pdb/brushes.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/font_select.pdb
	* tools/pdbgen/pdb/gradient_select.pdb
	* tools/pdbgen/pdb/gradients.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/paint_tools.pdb
	* tools/pdbgen/pdb/palette.pdb
	* tools/pdbgen/pdb/palette_select.pdb
	* tools/pdbgen/pdb/palettes.pdb
	* tools/pdbgen/pdb/paths.pdb
	* tools/pdbgen/pdb/pattern_select.pdb
	* tools/pdbgen/pdb/patterns.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/text_tool.pdb
	* tools/pdbgen/pdb/transform_tools.pdb: pass the new context
	parameter to the changed core functions.

	* app/pdb/*_cmds.c: regenerated.
2004-04-14 23:37:34 +00:00
Michael Natterer 2e61d12ed4 Moved the calls to floating_sel_relax()/rigor() from various places to two
2004-04-13  Michael Natterer  <mitch@gimp.org>

	Moved the calls to floating_sel_relax()/rigor() from various
	places to two single spots in the core where they are actually
	needed. Fixes bug #138356 (which was caused by the projection
	being triggered in the middle of changing the floating selection's
	size or the size of the drawable it is attached to). This commit
	effectively removes floating selection fiddling from the core's
	public API.

	* app/core/gimpdrawable.[ch] (gimp_drawable_has_floating_sel): new
	function which returns TRUE if there is a floating selection
	attached to the drawable.

	* app/core/gimpdrawable.c (gimp_drawable_translate)
	(gimp_drawable_set_tiles_full): if the drawable *has* a floating
	selection, relax/rigor it before/after modifying the drawable.

	* app/core/gimplayer.c (gimp_layer_translate)
	(gimp_layer_set_tiles): if the layer *is* the floating selection,
	relax/rigor it before/after modifying it.

	* app/core/gimpdrawable-transform.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-flip.c
	* app/core/gimpimage-resize.c
	* app/core/gimpimage-rotate.c
	* app/core/gimpimage-scale.c
	* app/gui/layers-commands.c
	* app/tools/gimpeditselectiontool.c
	* tools/pdbgen/pdb/layer.pdb: removed calls to
	floating_sel_rigor()/relax() all over the place. Also removed
	lots of undo groups which are obsolete now.

	* app/pdb/layer_cmds.c: regenerated.
2004-04-13 13:54:54 +00:00
Michael Natterer 069489fb71 GimpItem undo group cleanup in preparation of fixing bug #138356:
2004-04-13  Michael Natterer  <mitch@gimp.org>

	GimpItem undo group cleanup in preparation of fixing bug #138356:

	* app/core/core-enums.[c]: renamed LAYER_SCALE and LAYER_RESIZE
	undo groups to ITEM_SCALE and ITEM_RESIZE.

	* app/core/gimpitem.[ch]: always push undo groups around
	GimpItem::translate(), scale(), resize(), flip(), rotate() and
	transform(). Added the resp. undo_desc strings to GimpItemClass.

	* app/core/gimpchannel.[ch]
	* app/core/gimpdrawable.[ch]
	* app/core/gimplayer.c: removed all undo groups from
	implementations of the above methods. Removed the undo_desc
	strings which were moved to GimpItemClass.

	* app/core/gimpimage-crop.c
	* app/core/gimpselection.c
	* app/gui/layers-commands.c
	* app/vectors/gimpvectors.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

	* app/pdb/layer_cmds.c: regenerated.
2004-04-13 11:43:27 +00:00
Sven Neumann 2ce9ca7320 app/gui/layers-commands.c (layers_text_tool) treat modified text layers
2004-03-18  Sven Neumann  <sven@gimp.org>

	* app/gui/layers-commands.c (layers_text_tool)
	* app/gui/layers-menu.c (layers_menu_update): treat modified text
	layers like normal layers.

	* app/gui/layers-commands.c (layers_edit_layer_query): added a
	check button that gives access to the "auto-rename" property of a
	text layer.

	* app/text/gimptextlayer.c: typo.

	* app/widgets/gimppreviewrendererlayer.c
	(gimp_preview_renderer_layer_render): show the text layer icon for
	unmodified text layers only.
2004-03-18 18:00:38 +00:00
Simon Budig def801b3c3 Initialize a new layer unconditionally. Spotted by Roman Joost.
2004-03-18  Simon Budig  <simon@gimp.org>

	* app/gui/layers-commands.c: Initialize a new layer
	unconditionally. Spotted by Roman Joost.
2004-03-18 14:18:56 +00:00
Simon Budig e2d5ed6244 app/gui/channels-commands.c app/gui/layers-commands.c
2004-03-17  Simon Budig  <simon@gimp.org>

	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/gui/vectors-commands.c
	* app/widgets/gimpitemtreeview.c: shuffled some
	gimp_image_flush()'es around.
2004-03-17 16:45:18 +00:00
Simon Budig 23711e13d3 app/gui/channels-commands.c app/gui/layers-commands.c Make sure that
2004-03-17  Simon Budig  <simon@gimp.org>

	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/gui/vectors-commands.c: Make sure that non-dialog creation
	of layer/channels/vectors properly updates the image. Also
	clear the new channel unconditionally.

	Change the name of the newly created item to not include the "Copy".
	It isn't a copy.

	* app/widgets/gimpitemtreeview.c: Don't try to assemble translated
	strings.

	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimpvectorstreeview.c: properly overwrite the
	tooltip for the "New" button.

	Sorry, some real string changes ahere, but they were necessary.
2004-03-17 16:12:21 +00:00
Michael Natterer 49238237dc ref new tiles before unrefing the old ones.
2004-03-16  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpdrawable.c (gimp_drawable_set_tiles): ref new
	tiles before unrefing the old ones.

	* app/core/gimpimage-undo-push.c: keep undo memsize exact by
	adjusting undo->size when the stored data changes.

	* app/core/gimpchannel.[ch] (gimp_channel_new_from_alpha)
	* app/core/gimpchannel-select.[ch] (gimp_channel_select_alpha):
	replaced "layer" parameter by "drawable".

	* app/gui/layers-commands.c
	* tools/pdbgen/pdb/selection.pdb: changed accordingly.

	* app/pdb/selection_cmds.c: regenerated.

	* app/core/gimpchannel.c
	* app/core/gimplayer.c
	* app/core/gimplayermask.[ch]
	* app/core/gimpselection.c: remdom cleanup & code review.
2004-03-16 16:23:06 +00:00
Sven Neumann 07a92fe591 keep a pointer on the active text layer and let the tool follow the active
2004-03-13  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptexttool.[ch]: keep a pointer on the active text
	layer and let the tool follow the active layer. Fixes bug #124970.

	* app/gui/layers-commands.c: changed accordingly.
2004-03-13 00:47:31 +00:00
Michael Natterer d928919200 Make sure each GimpItem emits "removed" when it is removed from the image
2004-02-17  Michael Natterer  <mitch@gimp.org>

	Make sure each GimpItem emits "removed" when it is removed from
	the image so dialogs have a chance to close themselves:

	* app/core/gimplayer.c (gimp_layer_apply_mask): emit "removed"
	from the mask.

	(gimp_layer_removed): new function which emits "removed" from
	the layer's mask when the layer gets removed from the image.

	* app/core/gimpimage.c (gimp_image_dispose): emit "removed"
	from all layers, channels and vectors.

	* app/gui/layers-commands.c (layers_scale_layer_query)
	(layers_resize_layer_query): removed recently added connections to
	"removed" because GimpViewableDialog does this automatically.
2004-02-17 11:45:46 +00:00
Sven Neumann 1359960a56 added progress callback pointers to gimp_item_scale() and its variants.
2004-02-09  Sven Neumann  <sven@gimp.org>

	* app/core/gimpitem.[ch]: added progress callback pointers to
	gimp_item_scale() and its variants.

	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/core/gimpimage-scale.c
	* app/core/gimplayer.c
	* app/core/gimpselection.c
	* app/gui/layers-commands.c97999
	* app/paint-funcs/paint-funcs.[ch]
	* app/vectors/gimpvectors.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly. Fixes bug #97999.

	* app/pdb/layer_cmds.c: regenerated.
2004-02-09 00:09:20 +00:00
Michael Natterer 3781c7fb51 Use the global <Image> accel_group in all docks except the toolbox (the
2004-01-31  Michael Natterer  <mitch@gimp.org>

	Use the global <Image> accel_group in all docks except the
	toolbox (the latter needs GTK+ 2.4's new menu features).
	Addresses bug #119878:

	* app/gui/buffers-commands.c
	* app/gui/channels-commands.c
	* app/gui/data-commands.c
	* app/gui/documents-commands.c
	* app/gui/drawable-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/gradients-commands.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/plug-in-commands.c
	* app/gui/select-commands.c
	* app/gui/tool-options-commands.c
	* app/gui/tools-commands.c
	* app/gui/vectors-commands.c
	* app/gui/view-commands.c: changed the various return_if_no_foo()
	macros to also accept a GimpDock as user_data.

	* app/gui/image-menu.c (image_menu_update): don't update the
	display related menu items if they don't exist (see below).

	* app/gui/gui.c (gui_display_changed): simplified.

	* app/widgets/gimpimagedock.[ch]: create an "<Image>" item_factory
	and attach its accel_group to the dock. Destroy all display
	related menu items. Destroy the layer stack navigation items
	because their default shortcuts interfere with tree and grid view
	keybindings. Connect to "image_changed" of the dock's private
	context and to "flush" of the image container to update the
	item_factory's state.
2004-01-31 20:23:53 +00:00
Michael Natterer 402c5533cf use the new GIMP_STOCK_LAYER_MASK icon for "Add Layer Mask" dialog.
2004-01-27  Michael Natterer  <mitch@gimp.org>

	* app/gui/layers-commands.c (layers_add_mask_query): use the
	new GIMP_STOCK_LAYER_MASK icon for "Add Layer Mask" dialog.
2004-01-27 18:39:46 +00:00
Michael Natterer 3bee156b6e Allow invoking the text tool by double clicking a text layer in the layers
2004-01-13  Michael Natterer  <mitch@gimp.org>

	Allow invoking the text tool by double clicking a text layer in
	the layers dialog, just like the path tool is invoked when double
	clicking a path.

	* app/tools/gimptexttool.[ch]: added empty
	gimp_text_tool_set_layer() stub. Sven, your turn...

	* app/gui/layers-commands.[ch]: added layers_text_tool() which
	invokes the text tool on text layers and falls back to
	layers_edit_layer_query() otherwise.
	Added layers_text_tool_cmd_callback() for the layers menu.

	* app/gui/layers-menu.c: added "Text Tool" menu item and hide
	it for layers which are no text layers.

	* app/gui/dialogs-constructors.c (dialogs_layer_list_view_new):
	use layers_text_tool() as "activate" function.
2004-01-13 19:08:16 +00:00
Michael Natterer 15cf8858e0 no need to check if the layer has an alpha channel because
2004-01-10  Michael Natterer  <mitch@gimp.org>

	* app/gui/layers-commands.c (layers_alpha_to_selection_cmd_callback):
	no need to check if the layer has an alpha channel because
	gimp_channel_select_alpha() handles layers without alpha fine: it
	selects everything that is opaque, which is the entire layer.

	* app/gui/image-menu.c (image_menu_update)
	* app/gui/layers-menu.c (layers_menu_update): don't make the
	"Alpha to Selection" items insensitive for layers without alpha.
2004-01-10 15:32:51 +00:00
Sven Neumann 3451c82f4f added GIMP_UNDO_TEXT_LAYER to GimpUndoType enum.
2004-01-05  Sven Neumann  <sven@gimp.org>

	* app/core/core-enums.[ch]: added GIMP_UNDO_TEXT_LAYER to
	GimpUndoType enum.

	* app/core/gimpimage-undo-push.[ch]: added new undo function
	gimp_image_undo_push_text_layer().

	* app/text/gimptextlayer.[ch]: renamed gimp_text_layer_render() to
	gimp_layer_text_layer_flush().
	Added new function gimp_text_layer_discard().

	* app/text/gimptextlayer-transform.c: changed accordingly.

	* app/gui/image-menu.c
	* app/gui/layers-commands.[ch]
	* app/gui/layers-menu.c: added menu entries that allow to discard
	the text information of a text layer (bug #118547).

	* app/widgets/gimppreviewrendererlayer.c
	(gimp_preview_renderer_layer_render): treat text layers without a
	text object like ordinary layers.

	* app/widgets/gimppreviewrenderer-utils.c: include gimplayer.h
	instead of gimptextlayer.h.
2004-01-05 00:28:12 +00:00
Michael Natterer 1cc434fa6e Fixed memory management of layers and channels which were created using
2003-12-09  Michael Natterer  <mitch@gimp.org>

	Fixed memory management of layers and channels which were created
	using the PDB:

	* app/core/gimpitem.[ch]: added "gboolean floating" flag to
	GimpItem. Items are created with floating == TRUE. Added
	gimp_item_sink() which resets the floating flag and unrefs the
	item if it was TRUE.  Added gimp_item_is_floating() accessor.

	* app/core/gimpimage.c (gimp_image_add_layer,channel,vectors):
	g_object_ref()/gimp_item_sink() added items to take ownership of
	them.

	* app/core/gimplayer.c (gimp_layer_add_mask):
	g_object_ref()/gimp_item_sink() the mask.

	* app/gui/layers-commands.c
	* app/xcf/xcf-load.c: don't unref layer masks after adding them to
	the layer.

	* tools/pdbgen/pdb/drawable.pdb (drawable_delete):
	gimp_item_sink() the drawable if it's floating and fail if it's
	not. Fixes bug #128881.

	* tools/pdbgen/pdb/layer.pdb (layer_create_mask): fixed docs.

	* app/pdb/drawable_cmds.c
	* app/pdb/layer_cmds.c
	* libgimp/gimplayer_pdb.c: regenerated.
2003-12-09 18:59:35 +00:00
Michael Natterer e0e8a34f31 added enum values GIMP_ADD_ALPHA_MASK_TRANSFER and
2003-11-26  Michael Natterer  <mitch@gimp.org>

	* app/core/core-enums.[ch]: added enum values
	GIMP_ADD_ALPHA_MASK_TRANSFER and GIMP_UNDO_GROUP_LAYER_ADD_MASK.

	* app/core/gimplayer.c (gimp_layer_create_mask): applied patch
	from Pedro Gimeno which implements the new ADD_MASK type and
	added undo. Fixes bug #127930.

	* app/gui/layers-commands.c: push an undo group around layer mask
	creation & adding since the creation may change the layer now.

	* app/pdb/layer_cmds.c
	* libgimp/gimpenums.h
	* plug-ins/pygimp/gimpenums.py
	* plug-ins/script-fu/script-fu-constants.c
	* tools/pdbgen/enums.pl: regenerated.
2003-11-26 15:48:50 +00:00
Manish Singh ee2bfb69b5 add gimp_int_option_menu_set_sensitive and
2003-11-14  Manish Singh  <yosh@gimp.org>

        * libgimpwidgets/gimpwidgets.[ch]: add
        gimp_int_option_menu_set_sensitive and gimp_int_radio_group_set_active,
        tweak docs.

        * app/gui/convert-dialog.c
        * app/gui/layers-commands.c
        * app/tools/gimpcolorbalancetool.c
        * app/tools/gimpcurvestool.c
        * app/tools/gimplevelstool.c
        * app/widgets/gimpcontainerpopup.c
        * app/widgets/gimphistogrameditor.c
        * app/widgets/gimppropwidgets.c
        * app/widgets/gimptemplateeditor.c
        * app/widgets/gimptexteditor.c: use them.
2003-11-14 23:17:38 +00:00
Michael Natterer 6eb772946b libgimpwidgets/gimpquerybox.c configure the labels in the message dialog
2003-11-14  Michael Natterer  <mitch@gimp.org>

	* libgimpwidgets/gimpquerybox.c
	* app/widgets/gimpwidgets-utils.c: configure the labels in the
	message dialog and the query boxes to do automatic word wrapping
	to be HIG compliant.

	* app/app_procs.c
	* app/batch.c
	* app/config/gimpconfig-deserialize.c
	* app/config/gimpconfig-path.c
	* app/config/gimpconfig-utils.c
	* app/config/gimpconfigwriter.c
	* app/config/gimpscanner.c
	* app/core/gimpbrush.c
	* app/core/gimpbrushgenerated.c
	* app/core/gimpbrushpipe.c
	* app/core/gimpdatafactory.c
	* app/core/gimpgradient.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage.c
	* app/core/gimpimagefile.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimppalette.c
	* app/core/gimppattern.c
	* app/core/gimpselection.c
	* app/display/gimpdisplayshell.c
	* app/file/file-utils.c
	* app/gui/brush-select.c
	* app/gui/dialogs-commands.c
	* app/gui/drawable-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/font-select.c
	* app/gui/gradient-select.c
	* app/gui/gui.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/palette-select.c
	* app/gui/palettes-commands.c
	* app/gui/pattern-select.c
	* app/gui/preferences-dialog.c
	* app/gui/select-commands.c
	* app/gui/stroke-dialog.c
	* app/gui/tool-options-menu.c
	* app/gui/vectors-commands.c
	* app/gui/view-commands.c
	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-in.c
	* app/plug-in/plug-ins.c
	* app/text/gimptextlayer-xcf.c
	* app/text/gimptextlayer.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimptransformtool.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimpdatafactoryview.c
	* app/widgets/gimphelp.c
	* app/widgets/gimptemplateview.c
	* app/widgets/gimptooloptionseditor.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/image.pdb: removed explicit newlines from
	messages. Reduced number of translatable strings by making many
	file error messages the same. Quote single words and filenames
	with 'foo', not "foo". Replaced some more "drawable" by "layer".
	General message cleanup and consistency check.

	* app/pdb/image_cmds.c: regenerated.
2003-11-14 15:33:40 +00:00
Michael Natterer bcd9794a99 To be multihead safe, each new window or menu needs to be associated with
2003-11-08  Michael Natterer  <mitch@gimp.org>

	To be multihead safe, each new window or menu needs to be
	associated with a GdkScreen or it will pop up on the default
	screen.

	* libgimpwidgets/gimpquerybox.[ch]
	* app/display/gimpdisplayshell-layer-select.[ch]
	* app/widgets/widgets-types.h
	* app/widgets/gimpitemfactory.[ch]
	* app/widgets/gimpitemtreeview.[ch]
	* app/widgets/gimptemplateview.[ch]
	* app/widgets/gimptooldialog.[ch]
	* app/widgets/gimpviewabledialog.[ch]
	* app/gui/channels-commands.[ch]
	* app/gui/color-notebook.[ch]
	* app/gui/convert-dialog.[ch]
	* app/gui/edit-commands.[ch]
	* app/gui/grid-dialog.[ch]
	* app/gui/image-commands.[ch]
	* app/gui/info-dialog.[ch]
	* app/gui/layers-commands.[ch]
	* app/gui/offset-dialog.[ch]
	* app/gui/resize-dialog.[ch]
	* app/gui/stroke-dialog.[ch]
	* app/gui/templates-commands.[ch]
	* app/gui/vectors-commands.[ch]: added "GtkWidget *parent"
	paramaters to all functions which create menus, popups or windows
	and pass "parent" to gimp_dialog_new() or one of the various
	wrappers around it. As a side effect, this fixes bug #61092.

	* app/widgets/gimpdialogfactory.[ch]: added "GdkScreen *screen"
	instead of "parent" here since there are no possible parent
	windows on startup.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_origin_button_press): added a quick hack to
	send a display to another screen: click the origin button with the
	middle mouse button.

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_screen_changed): don't chain up
	undonditionally (don't crash).

	* libgimpwidgets/gimpdialog.c (gimp_dialog_new_valist): set the
	dialog's screen from a non-GtkWidget parent widget. The rest of
	non-window parent widget handling is still unimplemented.

	* libgimpwidgets/gimpcolorbutton.c
	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcolorpanel.c
	* app/widgets/gimpcomponenteditor.c
	* app/widgets/gimpcontainereditor.c
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpcontainerpopup.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimpdatafactoryview.c
	* app/widgets/gimpdevicestatus.c
	* app/widgets/gimpdockable.c
	* app/widgets/gimpdrawabletreeview.c
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimphelp.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimppreview-popup.c
	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimpsessioninfo.c
	* app/widgets/gimptoolbox-color-area.c
	* app/widgets/gimptoolbox-indicator-area.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimptooloptionseditor.c
	* app/widgets/gimpvectorstreeview.c
	* app/widgets/gimpwidgets-utils.c
	* app/display/gimpdisplayshell-scale.c
	* app/display/gimpnavigationview.c
	* app/gui/module-browser.c
	* app/gui/dialogs-commands.c
	* app/gui/dialogs-constructors.c
	* app/gui/drawable-commands.c
	* app/gui/file-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/gradient-editor-commands.c
	* app/gui/gui-vtable.c
	* app/gui/gui.c
	* app/gui/info-window.c
	* app/gui/palette-import-dialog.c
	* app/gui/palettes-commands.c
	* app/gui/qmask-commands.c
	* app/gui/select-commands.c
	* app/gui/tool-options-commands.c
	* app/gui/view-commands.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimptransformtool.c
	* plug-ins/FractalExplorer/FractalExplorer.c
	* plug-ins/gfig/gfig.c
	* plug-ins/gflare/gflare.c: changed addordingly. Changed all
	menu_position funcs to place the menu on the right screen.
2003-11-08 15:29:47 +00:00
Michael Natterer efd9a3e14a added "wm_name", "wm_class", "display_name" and "monitor_number" to the
2003-11-07  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/gimpprotocol.[ch]: added "wm_name", "wm_class",
	"display_name" and "monitor_number" to the GPConfig message.
	Increased protocol version number.

	* libgimp/gimp.[ch] (gimp_config): read them from the GPConfig
	message and remember them.
	Added public accessors for the new config values.

	* libgimp/gimpui.c (gimp_ui_init): pass wm_name and wm_class to
	gtk_init() and export the display/screen to use to the
	environment.

	* app/core/gimp.[ch]: added vtable entries to get the values
	from the GUI.

	* app/gui/gui-vtable.c: implement the vtable entries.

	* app/plug-in/plug-in-run.c: fill in the GPConfig values using
	the new Gimp vtable functions.

	* app/display/gimpdisplayshell-layer-select.c
	* app/display/gimpdisplayshell.c
	* app/gui/about-dialog.c
	* app/gui/channels-commands.c
	* app/gui/color-notebook.c
	* app/gui/convert-dialog.c
	* app/gui/file-dialog-utils.[ch]
	* app/gui/file-new-dialog.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/gradient-editor-commands.c
	* app/gui/gradients-commands.c
	* app/gui/grid-dialog.c
	* app/gui/image-commands.c
	* app/gui/info-dialog.[ch]
	* app/gui/info-window.c
	* app/gui/layers-commands.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/qmask-commands.c
	* app/gui/resize-dialog.c
	* app/gui/splash.c
	* app/gui/stroke-dialog.c
	* app/gui/templates-commands.c
	* app/gui/tips-dialog.c
	* app/gui/vectors-commands.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimplevelstool.c
	* app/widgets/gimpdock.c
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimptexteditor.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimpviewabledialog.[ch]
	* libgimpwidgets/gimpfileselection.c
	* libgimpwidgets/gimpquerybox.c
	* libgimpwidgets/gimpunitmenu.c
	* plug-ins/helpbrowser/dialog.c
	* plug-ins/ifscompose/ifscompose.c: replaced all calls to
	gtk_window_set_wmclass() by gtk_window_set_role() and all
	"const gchar *wmclass_name" parameters by "const gchar *role".
	Cleaned up the window role strings.
2003-11-07 17:29:02 +00:00
Michael Natterer 66c5dd8772 removed our own action_area API and use GtkDialog's one. Create all
2003-11-06  Michael Natterer  <mitch@gimp.org>

	* libgimpwidgets/gimpdialog.[ch]: removed our own action_area API
	and use GtkDialog's one. Create all dialogs without separator.
	Changed almost everything else too. Fixes bug #125143.

	* libgimpwidgets/gimpquerybox.c
	* libgimpwidgets/gimpunitmenu.c: changed accordingly.

	* libgimp/gimpexport.[ch]: ditto. Renamed enum GimpExportReturnType
	to GimpExportReturn.

	* libgimp/gimpcompat.h: added a #define for the old name.

	* themes/Default/gtkrc: increased action_area border to 6 pixels.

	* app/display/gimpdisplayshell-filter-dialog.c
	* app/display/gimpdisplayshell-scale.c
	* app/display/gimpprogress.c
	* app/gui/brush-select.c
	* app/gui/channels-commands.c
	* app/gui/color-notebook.c
	* app/gui/convert-dialog.c
	* app/gui/file-new-dialog.c
	* app/gui/font-select.c
	* app/gui/gradient-editor-commands.c
	* app/gui/gradient-select.c
	* app/gui/grid-dialog.c
	* app/gui/image-commands.c
	* app/gui/info-window.c
	* app/gui/layers-commands.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/palette-select.c
	* app/gui/pattern-select.c
	* app/gui/preferences-dialog.c
	* app/gui/qmask-commands.c
	* app/gui/resize-dialog.c
	* app/gui/resolution-calibrate-dialog.c
	* app/gui/stroke-dialog.c
	* app/gui/templates-commands.c
	* app/gui/user-install-dialog.c
	* app/gui/vectors-commands.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimptexteditor.c
	* app/widgets/gimptooldialog.[ch]
	* app/widgets/gimpviewabledialog.[ch]
	* app/widgets/gimpwidgets-utils.c: changed accordingly and increased
	the dialogs' outer borders to 6 pixels all over the place.

	* plug-ins/*/*.c: changed accordingly. The plug-ins may be
	arbitrarily broken, I tested none of them.
2003-11-06 15:27:05 +00:00
Michael Natterer f0372cad0f Treat changes to the selection like changes to any other drawable:
2003-10-06  Michael Natterer  <mitch@gimp.org>

	Treat changes to the selection like changes to any other drawable:

	* app/core/gimpchannel.c
	* app/core/gimpchannel-combine.c: call gimp_drawable_update() after
	changing the channel.

	* app/core/gimpimage.[ch]: added struct GimpImageFlushAccumulator
	with one member "gboolean mask_changed". Connect to "update" of
	the selection and set accum.mask_changed to TRUE in the callback.
	Added default implementation for GimpImage::flush() and emit
	"mask_changed" there.

	Unrelated:
	* app/core/gimpimage.h: removed GimpGuide struct...
	* app/core/gimpimage-guides.h: ...and added it here.

	* app/core/gimpimage-undo-push.c (undo_pop_mask)
	(undo_pop_channel_mod): don't distinguish between selection and
	non-selection channels and just call gimp_drawable_update().

	* app/core/gimpundo.h
	* app/core/gimpimage-undo.c: removed "gboolean mask_changed" from
	the GimpUndoAccumulator struct since we don't have to care about
	that signal explicitly any more.

	* app/display/gimpdisplay-foreach.[ch]: removed gimp_displays_flush().

	* tools/pdbgen/pdb/display.pdb (displays_flush_invoker): call
	gimp_image_flush() on all images so the flush accumulator is
	honored.

	This generalization enables the removal of more special purpose
	code which was needed to treat the selection different:

	* app/core/gimpimage-mask-select.[ch]: removed...

	* app/core/gimpchannel-select.[ch]: ...and added under a new name
	because it's not selection specific any more.

	* app/core/gimpimage-mask.[ch]: removed...

	* app/core/gimpselection.[ch]: ...added the two remaining
	functions here. Removed all calls to gimp_image_mask_changed().

	* app/core/Makefile.am
	* app/core/gimp-edit.c
	* app/core/gimpdrawable-transform.c
	* app/core/gimpimage-scale.c
	* app/core/gimpimage-snap.c
	* app/display/gimpdisplayshell.c
	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/gui/select-commands.c
	* app/gui/vectors-commands.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpellipseselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimpchanneltreeview.c
	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimpvectorstreeview.c
	* app/xcf/xcf-save.c
	* tools/pdbgen/pdb/paths.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/selection_tools.pdb: changed accordingly.

	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-colormap.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/gui/image-menu.c
	* app/paint/gimppaintcore.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpinkoptions.c
	* app/tools/gimpvectortool.c: removed useless and/or obsolete
	#includes.

	* app/pdb/display_cmds.c
	* app/pdb/paths_cmds.c
	* app/pdb/selection_cmds.c
	* app/pdb/selection_tools_cmds.c: regenerated.
2003-10-06 12:17:11 +00:00
Michael Natterer 008e3e208c removed the _bounds() and _boundary() wrappers.
2003-09-03  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage-mask.[ch]: removed the _bounds() and
	_boundary() wrappers.

	* app/core/gimpdrawable.c
	* app/display/gimpdisplayshell-selection.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimptransformtool.c
	* app/xcf/xcf-save.c: changed accordingly.
2003-09-03 17:17:18 +00:00
Sven Neumann 7c542ea775 app/gui/layers-commands.[ch] added "Merge Visible Layers..." and "Flatten
2003-08-31  Sven Neumann  <sven@gimp.org>

	* app/gui/layers-commands.[ch]
	* app/gui/layers-menu.c: added "Merge Visible Layers..." and
	"Flatten Image" menu entries as suggested in bug #120959.

	* app/text/gimptext-vectors.c: fixed function declaration; we are
	passing a PangoGlyph here, not a (PangoGlyph*).
2003-08-31 18:10:15 +00:00
Michael Natterer a7b2c160b4 Cleaned up my "To Selection" cleanup:
2003-08-27  Michael Natterer  <mitch@gimp.org>

	Cleaned up my "To Selection" cleanup:

	* app/gui/channels-commands.[ch]
	* app/gui/layers-commands.[ch]
	* app/gui/vectors-commands.[ch]: removed the separate
	cmd_callbacks for REPLACE,ADD,SUBTRACT,INTERSECT and pass the
	operation as "guint action" to the callback.

	* app/gui/channels-menu.c
	* app/gui/image-menu.c
	* app/gui/layers-menu.c
	* app/gui/vectors-menu.c: changed accordingly.
2003-08-27 00:52:00 +00:00
Michael Natterer a319c455d9 app/widgets/Makefile.am new file defining the available help topics. Work
2003-08-21  Michael Natterer  <mitch@gimp.org>

	* app/widgets/Makefile.am
	* app/widgets/gimphelp-ids.h: new file defining the available help
	topics. Work in progress and totally unusable for matching to the
	help system. Stay tuned...

	* app/gui/about-dialog.c
	* app/gui/brushes-menu.c
	* app/gui/buffers-menu.c
	* app/gui/channels-commands.[ch]
	* app/gui/channels-menu.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/gradients-commands.c
	* app/gui/gradients-menu.c
	* app/gui/image-menu.c
	* app/gui/layers-commands.[ch]
	* app/gui/layers-menu.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palettes-menu.c
	* app/gui/patterns-menu.c
	* app/gui/resize-dialog.c
	* app/gui/select-commands.c
	* app/gui/templates-menu.c
	* app/gui/tips-dialog.c
	* app/gui/toolbox-menu.c
	* app/gui/vectors-commands.[ch]
	* app/gui/vectors-menu.c: replaced literal HTML file paths by help
	IDs from gimphelp-ids.h. Renamed some menu callbacks to be
	consistent with similar ones. This is just an intermediate commit
	and not finished.

	While browsing all the menus, I noticed that our "x to selection"
	functions are not consistent at all. They should all offer the
	REPLACE,ADD,SUBTRACT,INTERSECT options:

	* app/core/gimpchannel.[ch]: added new function
	gimp_channel_new_from_alpha(). Removed gimp_channel_layer_alpha()
	and gimp_channel_layer_mask().

	* app/core/gimpimage-mask.[ch]: added
	gimp_image_mask_select_alpha() and
	gimp_image_mask_select_component() which offer the full set of
	operation, feather and feather_radius parameters as the other
	selection functions.

	* app/core/gimpimage-mask-select.[ch]: removed
	gimp_image_mask_layer_alpha() and gimp_image_mask_layer_mask().

	* app/gui/channels-commands.c (channels_channel_to_selection): use
	gimp_image_mask_select_component() instead of implementing it
	here.

	* app/gui/image-menu.c
	* app/gui/layers-commands.[ch]: offer the full choice of
	REPLACE,ADD,SUBTRACT,INTERSECT with "Alpha to Selection" and "Mask
	to Selection".

	* tools/pdbgen/pdb/selection.pdb: changed accordingly.

	* app/pdb/selection_cmds.c: regenerated.
2003-08-21 15:54:47 +00:00
Michael Natterer 2c95877093 use gtk_label_set_text_with_mnemonic() instead of just
2003-06-06  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpitemfactory.c (gimp_item_factory_set_label):
	use gtk_label_set_text_with_mnemonic() instead of just
	gtk_label_set_text().

	* app/gui/image-menu.c
	* app/gui/toolbox-menu.c: added mnemonics for all sub-menus.
	Fixes bug #106991.

	* app/gui/image-menu.c: cleaned up the "Layers" menu: moved
	sub-menus together. Changed the "Stack" menu's labels and
	accelerators and added "Select Top/Bottom Layer" for consistency
	(bound to Home/End).

	* app/gui/layers-commands.[ch]: changed accordingly. Added the
	new select top/bottom callbacks.
2003-06-06 10:30:14 +00:00
Michael Natterer 129c78d271 added gimp_item_translate() and virtual function GimpItem::translate().
2003-05-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpitem.[ch]: added gimp_item_translate() and
	virtual function GimpItem::translate().

	* app/core/gimplayer.[ch]: removed public function
	gimp_layer_translate() and implement GimpItem::translate()
	instead.

	* app/core/core-enums.[ch]
	* app/core/gimpimage-undo-push.[ch]: changed layer_displace undo
	types and functions to be item_displace ones.

	* app/core/gimpimage-crop.c
	* app/core/gimpimage-resize.c
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/layers-commands.c
	* app/tools/gimpeditselectiontool.c
	* app/widgets/gimptoolbox.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

	* app/pdb/layer_cmds.c: regenerated.
2003-05-08 19:11:17 +00:00
Michael Natterer ab0ac8472f removed the remaining layer scale API.
2003-05-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimplayer.[ch]: removed the remaining layer scale API.

	* app/core/gimpitem.[ch]: added the same functions here.

	* app/core/gimpimage-scale.c
	* app/gui/layers-commands.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

	* app/pdb/layer_cmds.c: regenerated.
2003-05-08 14:54:04 +00:00
Michael Natterer c1ab39a5e8 removed gimp_drawable_offsets().
2003-05-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpdrawable.[ch]: removed gimp_drawable_offsets().

	* app/core/gimpitem.[ch]: added gimp_item_offsets().

	* app/core/gimpdrawable-blend.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-histogram.c
	* app/core/gimpedit.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-mask-select.c
	* app/core/gimpimage-mask.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-pick-color.c
	* app/core/gimpimage-preview.c
	* app/core/gimpimage-projection.c
	* app/core/gimpimage-undo-push.c
	* app/core/gimpimage.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/display/gimpdisplay.c
	* app/display/gimpdisplayshell-transform.c
	* app/display/gimpdisplayshell.c
	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/paint/gimppaintcore.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpclonetool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimpinktool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimppainttool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimptoolbox.c
	* tools/pdbgen/pdb/color.pdb
	* tools/pdbgen/pdb/drawable.pdb: changed accordingly.

	* app/pdb/color_cmds.c
	* app/pdb/drawable_cmds.c: regenerated.
2003-05-08 14:06:03 +00:00
Michael Natterer 54878b79ce removed gimp_drawable_width,height().
2003-05-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpdrawable.[ch]: removed gimp_drawable_width,height().

	* app/core/gimpitem.[ch]: added gimp_item_width,height().

	* app/core/gimpchannel.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-offset.c
	* app/core/gimpdrawable-preview.c
	* app/core/gimpdrawable-transform.c
	* app/core/gimpimage-contiguous-region.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-mask.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-preview.c
	* app/core/gimpimage-projection.c
	* app/core/gimpimage-undo-push.c
	* app/core/gimpimage.c
	* app/core/gimpimagemap.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/core/gimplayermask.c
	* app/core/gimpscanconvert.c
	* app/display/gimpdisplay.c
	* app/display/gimpdisplayshell-dnd.c
	* app/display/gimpdisplayshell.c
	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimppaintcore.c
	* app/paint/gimpsmudge.c
	* app/text/gimptextlayer.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpclonetool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimphistogramtool.c
	* app/tools/gimpinktool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimpselectioneditor.c
	* app/widgets/gimptoolbox.c
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/selection.pdb: changed accordingly.

	* app/pdb/drawable_cmds.c
	* app/pdb/selection_cmds.c: regenerated.
2003-05-08 13:12:46 +00:00
Michael Natterer 323ed50c99 More transform stuff virtualization:
2003-05-07  Michael Natterer  <mitch@gimp.org>

	More transform stuff virtualization:

	* app/core/gimpitem.[ch]: added new virtual function
	GimpItem::resize().

	* app/core/gimpchannel.[ch]
	* app/core/gimplayer.[ch]: removed public resize functions
	and implement resize() instead.

	* app/core/gimpdrawable.c: implement resize() which contains
	the common parts of layer/channel resizing.

	* app/vectors/gimpvectors.c: added empty resize() implementation.

	* app/core/gimpimage-crop.c
	* app/core/gimpimage-resize.c
	* app/gui/layers-commands.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

	* app/pdb/layer_cmds.c: regenerated.
2003-05-07 13:01:17 +00:00
Michael Natterer 2a17435e7e Started to abstract item transformation so we can easily transform
2003-05-07  Michael Natterer  <mitch@gimp.org>

	Started to abstract item transformation so we can easily
	transform multiple linked items later:

	* app/core/gimpitem.[ch]: added new virtual function
	GimpItem::scale() with the same signature as the former
	gimp_layer_scale_lowlevel().

	* app/core/gimpdrawable.c: implement scale() and do the
	common parts of layer/channel scaling here.

	* app/core/gimpchannel.[ch]
	* app/core/gimplayer.[ch]: implement scale() for the
	channel/layer specific parts of scaling.

	* app/core/gimplayer.[ch]: renamed gimp_layer_scale() to
	gimp_layer_scale_by_origin().

	* app/vectors/gimpvectors.c: added empty scale() implementation.

	* app/core/gimpimage-scale.c
	* app/core/gimpimage-undo-push.c
	* app/gui/layers-commands.c
	* tools/pdbgen/pdb/layer.pdb: changed accordingly.

	* app/pdb/layer_cmds.c: regenerated.

	Unrelated:

	* app/core/gimpimage-undo-push.c: fixed item rename undo to
	take the size of the saved name into account. Removed old
	path_undo stuff.
2003-05-07 11:09:00 +00:00
Michael Natterer 4305341d49 app/gui/channels-commands.c app/gui/file-new-dialog.c
2003-03-27  Michael Natterer  <mitch@gimp.org>

	* app/gui/channels-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/layers-commands.c
	* app/gui/vectors-commands.c: use layer, channel, ... icons for
	the new layer, channel, ... dialogs.
2003-03-27 14:25:18 +00:00
Sven Neumann 28fddfd554 Makefile.am removed this header file.
2003-03-25  Sven Neumann  <sven@gimp.org>

	* Makefile.am
	* gimpintl.h: removed this header file.

	* gimpmiscui.c: include libgimp-intl.h.

	* gimp.c (gimp_main): call setlocale() and bind to the libgimp
	textdomain so that plug-ins don't need to do that explicitely.

	* libgimp/stdplugins-intl.h: added the functionality that used to
	live in gimpintl.h and removed the libgimp related stuff. Got rid
	of the INIT_I18N_UI() macro.

	* plug-ins/*/*.c: removed all occurances of INIT_I18N_UI().
	Plug-ins simply call INIT_I18N() once in their run() function.

	* plug-ins/script-fu/script-fu-intl.h: added the functionality
	that used to live in gimpintl.h and removed the libgimp related
	stuff.

	* app/Makefile.am
	* app/gimp-intl.h: new file that defines the gettext macros for
	the GIMP core.

	* app/*/*.c: include gimp-intl.h instead of libgimp/gimpintl.h.

	* plug-ins/script-fu/scripts/test-sphere.scm: fixed typos.
2003-03-25 16:38:19 +00:00
Sven Neumann b455d0c84c always flush the image when applying or discarding a layer mask. The
2003-03-22  Sven Neumann  <sven@gimp.org>

	* app/gui/layers-commands.c: always flush the image when applying
	or discarding a layer mask. The active drawable may change and
	make a menu update necessary (fixes bug #108958).

	* app/widgets/gimplayertreeview.c: call gimp_image_flush() when
	switching between layer and mask editing so the menus get updated.
2003-03-22 20:30:30 +00:00
Michael Natterer c1dffc05e0 Removed deprecated and broken list views based on GtkList[Item] (fixes bug
2003-03-20  Michael Natterer  <mitch@gimp.org>

	Removed deprecated and broken list views
	based on GtkList[Item] (fixes bug #90965):

	* app/widgets/gimpchannellistitem.[ch]
	* app/widgets/gimpchannellistview.[ch]
	* app/widgets/gimpcontainerlistview.[ch]
	* app/widgets/gimpdrawablelistitem.[ch]
	* app/widgets/gimpdrawablelistview.[ch]
	* app/widgets/gimpitemlistitem.[ch]
	* app/widgets/gimpitemlistview.[ch]
	* app/widgets/gimplayerlistitem.[ch]
	* app/widgets/gimplayerlistview.[ch]
	* app/widgets/gimplistitem.[ch]
	* app/widgets/gimpvectorslistview.[ch]: removed.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/widgets-enums.h
	* app/widgets/gimpcontainereditor.c
	* app/widgets/gimpcontainerview-utils.c
	* app/widgets/gimpdatafactoryview.c
	* app/gui/channels-commands.c
	* app/gui/channels-menu.c
	* app/gui/drawable-commands.c
	* app/gui/layers-commands.c
	* app/gui/layers-menu.c
	* app/gui/palettes-commands.c
	* app/gui/test-commands.c
	* app/gui/vectors-commands.c
	* app/gui/vectors-menu.c: changed accordingly.

	* app/gui/dialogs-commands.c
	* app/gui/dialogs-constructors.[ch]
	* app/gui/dialogs-menu.c
	* app/gui/dialogs.c: removed the term "tree" from all user visible
	places and create tree views when lists are requested.

2003-03-20  Michael Natterer  <mitch@gimp.org>

	* POTFILES.in: app/widgets/*list* -> *tree*
2003-03-20 13:05:52 +00:00
Michael Natterer 1329e016d2 app/core/gimpimage-mask.[ch] (gimp_image_mask_translate) added "gboolean
2003-03-18  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimage-mask.[ch] (gimp_image_mask_translate)
	* app/core/gimplayer.[ch] (gimp_layer_translate): added
	"gboolean push_undo" parameters.

	* app/core/gimpimage-crop.c
	* app/core/gimpimage-resize.c
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/layers-commands.c
	* app/widgets/gimptoolbox.c
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/selection.pdb: changed accordingly.

	* app/pdb/layer_cmds.c
	* app/pdb/selection_cmds.c: regenerated.

	* app/core/gimpimage-undo-push.c (undo_pop_layer_displace): call
	gimp_layer_translate() with "push_undo == FALSE" instead of
	duplicating gimp_layer_translate()'s code. Use GimpItemUndo for
	GIMP_UNDO_MASK.

	* app/tools/gimpeditselectiontool.c
	(gimp_edit_selection_tool_cursor_key): check if the top undo on
	the stack is of exactly the same type as the undo we would push
	and just don't push it then (compresses layer translate undos and
	fixes bug #86362). Changed stuff work with CAPS_LOCK or other
	modifiers pressed.
2003-03-18 16:42:45 +00:00
Michael Natterer b417203a62 added GIMP_UNDO_CHANNEL_COLOR.
2003-03-17  Michael Natterer  <mitch@gimp.org>

	* app/core/core-enums.[ch]: added GIMP_UNDO_CHANNEL_COLOR.

	* app/core/gimpchannel.[ch]: added "gboolean push_undo" to
	gimp_channel_set_color().

	* app/core/gimpimage-undo-push.[ch]: added
	gimp_image_undo_push_channel_color().

	* app/core/gimpimage-qmask.c
	* app/gui/qmask-commands.c
	* app/widgets/gimpchannellistitem.c
	* tools/pdbgen/pdb/channel.pdb: changed accordingly.

	* app/gui/channels-commands.c
	* app/gui/layers-commands.c
	* app/gui/vectors-commands.c: ditto. Use gimp_item_rename().

	* app/pdb/channel_cmds.c: regenerated.
2003-03-17 02:25:39 +00:00
Michael Natterer 205cdf1353 Added GtkTreeView versions of layers/channels/vectors:
2003-03-16  Michael Natterer  <mitch@gimp.org>

	Added GtkTreeView versions of layers/channels/vectors:

	* app/core/core-enums.[ch]: renamed GIMP_UNDO_GROUP_LAYER_PROPERTIES
	to GIMP_UNDO_GROUP_ITEM_PROPERTIES.

	* app/core/gimpcontainer.c (gimp_container_reorder): don't try
	to reorder containers with num_children == 1.

	* app/core/gimpmarshal.list: added VOID: STRING, UINT marshaller.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpchanneltreeview.[ch]
	* app/widgets/gimpdrawabletreeview.[ch]
	* app/widgets/gimpitemtreeview.[ch]
	* app/widgets/gimplayertreeview.[ch]
	* app/widgets/gimpvectorstreeview.[ch]: new widgets.

	* app/widgets/gimpcellrenderertoggle.c: draw the frame only if the
	cell is prelit.

	* app/widgets/gimpcellrendererviewable.[ch]: added "clicked"
	signal, unref the renderer in finalize(). Set the renderer's
	border color to black if the cell is not selected (a hack that
	saves tons of code in GimpLayerTreeView).

	* app/widgets/gimpcomponenteditor.c: no need to gtk_list_store_set()
	stuff we just got from the store.

	* app/widgets/gimpcontainertreeview.[ch]: added lots of state used
	by the new subclasses to the GimpContainerTreeView struct.  Create
	the GtkListStore/GtkTreeView in GObject::constructor() and only
	collect parameters in init() so subclasses can modify store/view
	creation. Do most of the button_press_event stuff manually and
	return TRUE from the handler.

	* app/widgets/gimpcontainerview.c: cleanup.

	* app/widgets/gimpitemlistview.h
	* app/widgets/gimpvectorslistview.h: temp hacks before they die.

	* app/widgets/gimppreviewrenderer.[ch]: added
	gimp_preview_renderer_update_idle() which idle-emits "update"
	without invalidating.

	* app/gui/dialogs-constructors.[ch]
	* app/gui/dialogs.c: added constructors for the new dialogs.

	* app/gui/channels-commands.c
	* app/gui/channels-menu.c
	* app/gui/layers-commands.c
	* app/gui/layers-menu.c
	* app/gui/vectors-commands.c
	* app/gui/vectors-menu.c: accept tree views as callback data.
2003-03-16 11:14:29 +00:00