Commit Graph

236 Commits

Author SHA1 Message Date
Michael Natterer b60e1779cd app: pass a GimpGradient to gimp_drawable_blend(), not a GimpBlendMode
The blend mode is now only a PDB compat enum, translate between
GimpBlendMode and the built-in gradients in the gimp-edit-blend PDB
wrapper.
2014-04-30 09:17:42 +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
Michael Natterer 0bdb74710a app: rename the value-1...value-4 actions to opacity, size, aspect, angle 2014-04-19 20:09:39 +02:00
Michael Natterer 2a9b6bf569 app: make blend's and straight line's start-line-end drawing look nicer
Use circle handles instead of crosses, and put the items into a stroke
group so they don't look ugly when drawing over each other.
2014-04-12 22:10:26 +02:00
darkraid1 ac5428787e Bug 598523 - Protect hidden layers from editing
Don't allow tool operations on invisible items, just like we do for
group layers or locked items.

Cleaned up and enhanced the patch a bit --Mitch
2013-05-13 23:29:43 +02:00
Michael Natterer 981f039053 app: don't disable the blend tool on indexed drawables 2012-05-02 17:51:21 +02:00
Michael Natterer 89d3869760 app: update GimpBlendTool's status when Alt is pressed/released 2011-10-07 01:39:53 +02:00
Michael Natterer 38b8f0596d app: use the new modifier API instead of constants in all tools
There are still many uses of literal SHIFT and MOD1 left, but all uses
of CONTROL are gone. Should work exactly as before on Win/X11, and
still has some glitches on OSX.
2011-10-06 21:59:07 +02:00
Michael Natterer 990a4bd271 app: don't forget to move the start handle in GimpBlendTool
because the tool moves both handles when Alt is pressed.
2011-10-05 23:40:44 +02:00
Michael Natterer ea34b145e8 app: some random tool cleanup 2011-04-04 00:01:30 +02:00
Michael Natterer 6de9615154 app: bail out in gimp_blend_tool_initialize() if there is no gradient 2011-04-03 00:33:41 +02:00
Michael Natterer accc12a3ca app: change GimpCanvasItem setters to take GimpCanvasItem*
not GimpCanvasLine* etc. We keep them around as items, and their
constructors return items, and it's getting more code anyway when
porting away from pause/resume, so let's keep the casting minimal at
least.
2011-03-28 12:20:36 +02:00
Michael Natterer aa5d2f8082 app: port GimpBlendTool to pause()/resume()-less drawing
Instead, keep around the created GimpCanvasItems, and update them when
the blend coordiates change. Add setters to GipmCanvasLine and
GimpCanvasHandle which take care of calling begin_change() and
end_change() on the items around the change, so thes invalidate
properly.
2011-03-28 11:08:40 +02:00
Michael Natterer 41b905baa8 app: make GimpTool implement the GimpProgress interface properly
and remove the previously added quick hack. Change the cage progress
code to standard progress code, and use the tool progress also in
blend.
2011-03-25 10:55:07 +01:00
Michael Natterer cf0402f069 app: consistent handle sizes for tool drawing
Replace a myriad of defines in different tools by three consistent
sizes defined in gimpdrawtool.h.
2010-11-08 22:37:00 +01:00
Michael Natterer 22db39afd2 app: fix incomplete earlier s/GtkAnchorType/GimpHandleAnchor/ change 2010-10-18 20:13:09 +02:00
Michael Natterer b3af235e79 app: rename all gimp_draw_tool_draw_foo() functions
to gimp_draw_tool_add_foo() because that's what they do now.
2010-09-25 19:02:22 +02:00
Michael Natterer 313f8bee1e app: remove "gboolean use_cairo" from the draw tool again
It's always TRUE now.
2010-09-24 21:14:49 +02:00
Michael Natterer 4d0c750327 app: get rid of "gboolean use_offsets" in the draw tool
and always pass image coordinates. Transform the coords manually in
the very few places which passed TRUE.
2010-09-23 19:23:27 +02:00
Michael Natterer 919b3d83b8 app: enable cairo drawing in the blend tool
and reorder drawing functions so the handles are on top of the line.
2010-09-22 22:25:37 +02:00
Michael Natterer 08f35de4ac Use gimp_display_get_image() instead of display->image 2009-10-07 19:00:42 +02:00
Michael Natterer 9e18f771c4 Replace "Group Layer" by "Layer Group" in all user visible strings 2009-09-03 14:57:18 +02:00
Michael Natterer 02903d6970 Use gimp_item_is_content_locked() instead of gimp_item_get_lock_content()
Use the new API whenever we want to determine the item's effective
lock state (whether we can write to the item's content or not). Use
gimp_item_get_lock_content() only in code that actually deals with
*this* item's locked state, which is only the PDB wrappers and GUI to
modify the flag on the item itself.
2009-08-29 15:27:04 +02:00
Michael Natterer e979c08133 Start separating the logic for "locked" and "is group" again
The idea that group layers count as locked was a bad one, start adding
separate checks for group layers, and refuse to modify them with
distinct error messages.
2009-08-28 20:07:14 +02:00
Michael Natterer 9040afc0fc Set BAD cursors if the active drawable is locked 2009-08-21 19:34:59 +02:00
Michael Natterer c9c28be9df Make the checks in GimpTool::initialize() work reliably
Set tool->display and tool->drawable to NULL in button_release()
so initialize() is actually called before each button_press().
2009-08-21 18:27:50 +02:00
Michael Natterer ec6600a0b3 Refuse to edit locked drawables
Check whether the drawable to edit is locked in GimpTool::initialize()
and bail out with an appropriate error if it is. This currently
prevents cloning from locked drawables, will fix that later.
2009-08-20 17:05:23 +02:00
Michael Natterer 1a16b48c93 Add infrastructure for sending double and triple clicks to tools
* app/tools/tools-enums.[ch]: add enum GimpButtonPressType which can
be { NORMAL, DOUBLE, TRIPLE }

* app/tools/gimptool.[ch]: add press_type paramater to GimpTool::button_press()

* app/tools/gimp*tool.c
* app/tools/tool_manager.[ch]: changed accordingly.

* app/tools/gimptoolcontrol.[ch]: add members and API so tools can choose
to receive double and triple clicks.

* app/display/gimpdisplayshell-callbacks.c (gimp_display_shell_tool_events):
dispatch double and triple clicks to tools if they want them, and if they
became active by the preceding normal button press.
2009-06-20 17:37:31 +02:00
Michael Natterer 090e06ecdd Move the stuff in tools-utils to the core so it can be used from
app/paint/ in the next step.

* app/tools/Makefile.am
* app/tools/tools-utils.[ch]: removed.

* app/core/gimp-utils.[ch]: add gimp_constrain_line() instead.

* app/tools/gimpblendtool.c
* app/tools/gimpeditselectiontool.c
* app/tools/gimpfreeselecttool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimppainttool.c: changed accordingly.
2009-04-22 21:08:42 +02:00
Michael Natterer e0f1bf375c Bug 572156 – top left pixel position/coordinate is not 0,0 but 1,1
2009-02-20  Michael Natterer  <mitch@gimp.org>

	Bug 572156 – top left pixel position/coordinate is not 0,0 but 1,1

	* app/display/gimpstatusbar.c
	(gimp_statusbar_push_coords)
	(gimp_statusbar_update_cursor): fix braino for
	GIMP_CURSOR_PRECISION_PIXEL_CENTER: going to the pixel's
	center doesn't need any rounding, it simply needs clipping
	the coordinates' fractional parts, gah...

	Review all tools' cursor precision:

	* app/tools/gimpblendtool.c (gimp_blend_tool_init): set cursor
	precision to SUBPIXEL.

	* app/tools/gimptexttool.c (gimp_text_tool_init)
	* app/tools/gimpmeasuretool.c (gimp_measure_tool_init)
	* app/tools/gimpeditselectiontool.c (gimp_edit_selection_tool_init):
	set cursor precision to PIXEL_BORDER.


svn path=/trunk/; revision=28053
2009-02-20 16:57:26 +00: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
Sven Neumann b37c8bcf0a app/core/Makefile.am added GIMP_ERROR as general error domain.
2008-11-12  Sven Neumann  <sven@gimp.org>

	* app/core/Makefile.am
	* app/core/gimperror.[ch]: added GIMP_ERROR as general error 
domain.

	* app/core/gimpchannel.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/core/gimplayermask.c
	* app/core/gimpselection.c
	* app/core/gimptooloptions.c
	* app/paint/gimpbrushcore.c
	* app/paint/gimpclone.c
	* app/paint/gimpheal.c
	* app/paint/gimppaintcore-stroke.c
	* app/paint/gimpperspectiveclone.c
	* app/paint/gimpsourcecore.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdesaturatetool.c
	* app/tools/gimpgegltool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpthresholdtool.c
	* app/vectors/gimpvectors-import.c: use GIMP_ERROR as error 
domain
	instead of 0, which is not accepted by g_set_error_literal().

	* app/gui/session.c
	* app/menus/menus.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimpdevices.c: use G_FILE_ERROR as error domain 
for
	file errors.


svn path=/trunk/; revision=27628
2008-11-12 10:56:06 +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 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 f7287be7b5 app/tools/gimptool.[ch] made all GimpCoords* in the tool API const.
2008-11-01  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimptool.[ch]
	* app/tools/tool_manager.[ch]: made all GimpCoords* in the tool
	API const.

	* app/tools/gimpaligntool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpbrushtool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcolortool.c
	* app/tools/gimpconvolvetool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdodgeburntool.c
	* app/tools/gimpeditselectiontool.[ch]
	* app/tools/gimperasertool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimpmagnifytool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpperspectiveclonetool.c
	* app/tools/gimprectangleselecttool.c
	* app/tools/gimprectangletool.[ch]
	* app/tools/gimpregionselecttool.c
	* app/tools/gimpselectiontool.[ch]
	* app/tools/gimpsourcetool.c
	* app/tools/gimptexttool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c: changed accordingly and added const
	to all GimpCoords* in utility functions too.

	* app/tools/gimptexttool.c: don't modify the passed coords. In
	fact, simply removed the code that did because it had no effect.


svn path=/trunk/; revision=27517
2008-11-01 15:17:36 +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 d51c50820f Bug 496772 – Position shown in the statusbar needs more precision (for
2008-08-20  Michael Natterer  <mitch@gimp.org>

	Bug 496772 – Position shown in the statusbar needs more
	precision (for some tools)

	* app/display/display-enums.[ch]: add enum GimpCursorPrecision
	which can be one of { PIXEL_CENTER, PIXEL_BORDER, SUBPIXEL }.

	* app/display/gimpdisplayshell-cursor.[ch]: add "precision"
	parameter to gimp_display_shell_update_cursor() and pass it
	on to the statusbar.

	* app/display/gimpstatusbar.[ch]: add "precision" parameters to
	the cursor coordinates APIs, offset the passed coords accordingly
	and display them with one decimal point if SUBPIXEL is requested
	and the display's unit is PIXEL. Keep a second floating-point
	format string around at any time.

	* app/tools/gimptoolcontrol.[ch]: add a "precision" member and API
	so tools can configure the precision they need. Defalt to
	PIXEL_CENTER since that's right for almost all tools.

	* app/display/gimpdisplayshell-callbacks.c: pass the tool's
	precision to gimp_display_shell_update_cursor().

	* app/tools/gimptool.[ch]: add "precision" parameter to
	gimp_tool_push_status_coords() and pass it on to the statusbar.

	* app/tools/gimpaligntool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpcolortool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpperspectiveclonetool.c
	* app/tools/gimprectangleselecttool.c
	* app/tools/gimprectangletool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c: set precision in init() where
	needed. Adjust the precision in the fly when needed, e.g. while
	moving guides or when toggling hard-edge on paint tools. Also pass
	an appropriate precision to gimp_tool_push_status_coords(), which
	is not always the tool's precision as used for cursor display.


svn path=/trunk/; revision=26681
2008-08-20 16:22:09 +00:00
Sven Neumann 83226c8ae5 don't draw the handles on pixel centers, we don't blend between pixel
2008-04-18  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpblendtool.c (gimp_blend_tool_draw): don't draw 
the
	handles on pixel centers, we don't blend between pixel centers.


svn path=/trunk/; revision=25498
2008-04-18 21:05:29 +00:00
Martin Nordholts 8772b0a150 Added symbolic constants for common values to the n_snap_lines parameter
2008-01-15  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/tools-utils.h: Added symbolic constants for common
	values to the n_snap_lines parameter of
	gimp_tool_motion_constrain.

	* app/tools/gimpblendtool.c:
	* app/tools/gimpeditselectiontool.c:
	* app/tools/gimpmeasuretool.c:
	* app/tools/gimppainttool.c: Use these new symbolic constants.

svn path=/trunk/; revision=24623
2008-01-15 21:05:57 +00:00
Martin Nordholts 4ef8797faa Generalized to allow a variable number of lines for snapping, and
2008-01-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/tools-utils.[ch]
	(gimp_tool_motion_constrain): Generalized to allow a variable
	number of lines for snapping, and rewritten to make snapping
	happen more intuitively; snap the shortest distance rather than
	only horizontally or vertically.
	(gimp_tool_utils_point_to_line_distance): New helper function.

	* app/tools/gimpblendtool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppainttool.c: Adjust to the new function signature.

svn path=/trunk/; revision=24609
2008-01-14 21:23:02 +00:00
Sven Neumann a5d10b2ff0 renamed gimp_image_active_drawable() to gimp_image_get_active_drawable().
2007-07-19  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimage.[ch]: renamed gimp_image_active_drawable() to
	gimp_image_get_active_drawable().

	* app/[lots of files]
	* tools/pdbgen/pdb/paths.pdb
	* tools/pdbgen/pdb/image.pdb: changed accordingly.

svn path=/trunk/; revision=22958
2007-07-19 14:59:51 +00:00
Sven Neumann e9b050d244 fixed typo spotted by Bill Skaggs.
2007-03-21  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpblendtool.c (gimp_blend_tool_button_release): fixed
	typo spotted by Bill Skaggs.

svn path=/trunk/; revision=22157
2007-03-21 16:06:11 +00:00
Michael Natterer 40718dc7e4 app/tools/gimpaligntool.c app/tools/gimpcolorpickertool.c
2007-03-15  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpaligntool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpvectortool.c: remove gimp_tool_pop_status() from
	control() implementations because GimpTool does this generically now.

	* app/tools/gimpblendtool.c
	* app/tools/gimpselectiontool.c: remove entire control()
	implementations because they were doing nothing else.


svn path=/trunk/; revision=22128
2007-03-15 17:32:50 +00:00
Michael Natterer 83d3a750d4 include "libgimpmath/gimpmathtypes.h" instead of "libgimpmath/gimpmath.h".
2007-03-09  Michael Natterer  <mitch@gimp.org>

	* app/core/core-types.h: include "libgimpmath/gimpmathtypes.h"
	instead of "libgimpmath/gimpmath.h".

	* app/core/gimpbrush.h
	* app/paint/gimppaintcore.h
	* app/paint/gimpperspectiveclone.h
	* app/text/gimptext.h
	* app/tools/gimptransformtool.h: include gimpvector.h and
	gimpmatrix.h explicitely where they are needed in public structs.

	* app/*/*.c
	* tools/pdbgen/pdb/paths.pdb: include "libgimpmath/gimpmath.h"
	where needed.

	* app/pdb/paths_cmds.c: regenerated.


svn path=/trunk/; revision=22084
2007-03-09 13:00:01 +00:00
Michael Natterer 974a74004f remove useless includes. Some minor cleanup.
2007-03-09  Michael Natterer  <mitch@gimp.org>

	* app/tools/*.c: remove useless includes. Some minor cleanup.


svn path=/trunk/; revision=22083
2007-03-09 11:10:40 +00:00
Raphael Quinet 2c1e06c107 make the new feature visible in the status bar (alas, this implies a new
2007-03-09  Raphael Quinet  <raphael@gimp.org>

	* app/tools/gimpblendtool.c (gimp_blend_tool_push_status): make
	the new feature visible in the status bar (alas, this implies a
	new translatable string).

svn path=/trunk/; revision=22078
2007-03-08 23:33:55 +00:00
Michael Natterer e9029e04e0 renamed members and added last_x and last_y to remember the last mouse
2007-03-08  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpblendtool.h (struct GimpBlendTool): renamed
	members and added last_x and last_y to remember the last mouse
	coords.

	* app/tools/gimpblendtool.c: changed accordingly. Take drawable
	offset into account in button_release() and remove offset
	calculations from all other places. Enabled using ALT for moving
	the entire line.


svn path=/trunk/; revision=22077
2007-03-08 18:07:38 +00:00
Michael Natterer d7ed63948c Step one towards enabling tool cancellation by other means than mouse
2007-02-27  Michael Natterer  <mitch@gimp.org>

	Step one towards enabling tool cancellation by other means than
	mouse button 3 and towards proper "clicked" semantics.

	* app/tools/tools-enums.[ch]: added enum GimpButtonReleaseType
	which can be one of { NORMAL, CANCEL, CLICK } (click is curently
	unused).

	* app/tools/gimptool.[ch] (GimpTool::button_release): added
	"release_type" parameter.

	(gimp_tool_button_release): if the state contains
	GDK_BUTTON3_MASK, call the tool's button_release() with CANCEL,
	use NORMAL otherwise.

	* app/tools/gimpaligntool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcolortool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimpmagnifytool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimprectangleselecttool.c
	* app/tools/gimprectangletool.[ch]
	* app/tools/gimpregionselecttool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c (button_release): added
	"release_type" parameters and get rid of own checks for
	GDK_BUTTON3_MASK.


svn path=/trunk/; revision=22015
2007-02-27 18:55:12 +00:00
Raphael Quinet 65950be141 app/display/gimpstatusbar.[ch] add optional help text at the end of the
2007-01-21  Raphael Quinet  <raphael@gimp.org>

	* app/display/gimpstatusbar.[ch]
	* app/tools/gimptool.[ch]: add optional help text at the end of
	the messages generated by gimp_statusbar_push_coords() and
	gimp_statusbar_push_length().

	* app/tools/gimpcolortool.c
	* app/tools/gimpeditselectiontool.c 
	* app/tools/gimpmovetool.c
	* app/tools/gimprectangletool.c: use the updated functions.

	* app/tools/gimpblendtool.c
	* app/tools/gimpcolorpickertool.c: added status bar messages.

svn path=/trunk/; revision=21745
2007-01-21 01:24:51 +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