Commit Graph

2910 Commits

Author SHA1 Message Date
Michael Natterer 52c61f6b5f keep a "default_config" object around and use it to reset the tool if it
2008-09-30  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.[ch]: keep a "default_config" object
	around and use it to reset the tool if it exists.

	(gimp_image_map_tool_edit_as): set the default_config on the new
	tool so "reset" goes back to the values the tool was started with.

	* app/tools/gimpcolorbalencetool.c (gimp_color_balance_tool_reset)
	* app/tools/gimpcurvestool.c (gimp_curves_tool_reset)
	* app/tools/gimphuesaturationtool.c (gimp_hue_saturation_tool_reset)
	* app/tools/gimplevelstool.c (gimp_levels_tool_reset): use the
	default config to reset the tool here too if it exists.


svn path=/trunk/; revision=27090
2008-09-30 13:46:08 +00:00
Martin Nordholts 63ca4578b9 Bug 549925 – incorrect math: adding/substracting empty selection
deselects selection

* app/tools/gimprectangleselecttool.c
(gimp_rectangle_select_tool_execute): Be more intuitive when
clicking outside the current selection for the selection modes Add
and Subtract. More specifically, don't alter the selection mask at
all.

svn path=/trunk/; revision=27048
2008-09-24 21:15:54 +00:00
Martin Nordholts f08e322809 Added new utility function gimp_rectangle_select_tool_get_operation(), and
* app/tools/gimprectangleselecttool.c: Added new utility function
gimp_rectangle_select_tool_get_operation(), and started using it.

svn path=/trunk/; revision=27047
2008-09-24 20:55:55 +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
Michael Natterer 3827523fe7 Bug 551306 – Color picker for text tool does not show selected palette
2008-09-08  Michael Natterer  <mitch@gimp.org>

	Bug 551306 – Color picker for text tool does not show selected
	palette

	* app/tools/gimptexttool.c (gimp_text_tool_register): add
	GIMP_CONTEXT_PALETTE_MASK to the tool option's context mask so the
	color popup's palette follows the globally selected palette.


svn path=/trunk/; revision=26899
2008-09-08 12:50:41 +00:00
Sven Neumann ec789594af also blacklist the "stress" operations
svn path=/trunk/; revision=26880
2008-09-05 17:41:29 +00:00
Sven Neumann de8671671f blacklist "color-convert" and all GIMP operations.
2008-09-05  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpgegltool.c: blacklist "color-convert" and all 
GIMP
	operations.


svn path=/trunk/; revision=26879
2008-09-05 17:37:17 +00:00
Sven Neumann 39ed2677f6 added a blacklist of operations that should not be shown. We may want to
2008-09-05  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpgegltool.c: added a blacklist of operations that
	should not be shown. We may want to add more operations here.


svn path=/trunk/; revision=26878
2008-09-05 17:11:48 +00:00
Michael Natterer 941310a309 Bug 550983 – The size displayed in the status bar isn't correct
2008-09-05  Michael Natterer  <mitch@gimp.org>

	Bug 550983 – The size displayed in the status bar isn't correct

	* app/tools/gimprectangletool.c: use the right precision when
	pushing the rectangle's size as coordinates to the statusbar.


svn path=/trunk/; revision=26872
2008-09-05 12:15:24 +00:00
Sven Neumann 66a3aedea6 expose the preview when the tool is initialized. Fixes missing redraws
2008-09-04  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptransformtool.c 
(gimp_transform_tool_initialize):
	expose the preview when the tool is initialized. Fixes missing
	redraws when the tool is selected from the menus (bug #550911).

	(gimp_transform_tool_motion): expose the preview after
	recalculating the transformation matrix.


svn path=/trunk/; revision=26868
2008-09-04 21:34:38 +00:00
Sven Neumann 8ec1d65a4a removed trailing whitespace
svn path=/trunk/; revision=26852
2008-09-04 08:37:32 +00:00
Michael Natterer b19d4b85c3 some tiny formatting fixes.
2008-08-28  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimprectangletool.c: some tiny formatting fixes.


svn path=/trunk/; revision=26799
2008-08-28 12:54:14 +00:00
Sven Neumann 26645c5549 moved hiding the dialog from gimp_transform_tool_real_transform() to
2008-08-27  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptransformtool.c: moved hiding the dialog from 
	gimp_transform_tool_real_transform() to 
gimp_transform_tool_doit().
	Delay undrawing the preview in doit() until the transformation 
is
	done. This removes the annoying flicker at the end.


svn path=/trunk/; revision=26789
2008-08-27 09:56:46 +00:00
Sven Neumann 915803cfa9 fixed compilation
svn path=/trunk/; revision=26788
2008-08-27 08:21:34 +00:00
Sven Neumann 28cdc4d9a0 hide the tool dialog before starting to perform the transformation.
2008-08-27  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptransformtool.c 
(gimp_transform_tool_real_transform):
	hide the tool dialog before starting to perform the 
transformation.


svn path=/trunk/; revision=26787
2008-08-27 07:42:28 +00:00
Martin Nordholts b5b51b475f libgimpwidgets/gimpwidgets.c
2008-08-26  Martin Nordholts  <martinn@svn.gnome.org>

	* libgimpwidgets/gimpwidgets.c

	* plug-ins/common/file-xbm.c
	* plug-ins/common/file-wmf.c
	* plug-ins/common/file-svg.c
	* plug-ins/common/file-gih.c
	* plug-ins/common/blur-motion.c
	* plug-ins/file-jpeg/jpeg-save.c
	* plug-ins/lighting/lighting-ui.c
	* plug-ins/map-object/map-object-ui.c

	* app/tools/gimpsheartool.c
	* app/tools/gimpaligntool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimplevelstool.c
	* app/dialogs/resize-dialog.c
	* app/dialogs/offset-dialog.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimpcolormapeditor.c
	* app/dialogs/layer-options-dialog.c
	* app/display/gimpdisplayshell-scale-dialog.c: Pass page_size = 0
	to gimp_spin_button_new() to adapt to new and correct value
	clamping in GTK+.

svn path=/trunk/; revision=26778
2008-08-26 19:32:14 +00:00
Michael Natterer 92cbcd03b2 don't hardcode the attach coords for the fixed containing the dynamics
2008-08-26  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c (gimp_paint_options_gui): don't
	hardcode the attach coords for the fixed containing the dynamics
	labels but use the table's real width instead. Fixes broken table
	layout in the airbrush options.


svn path=/trunk/; revision=26771
2008-08-26 14:50:05 +00:00
Martin Nordholts ee44ab3d32 Set page_size for the Ouput/Input Levels lower/upper adjustments to 0 to
2008-08-24  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimplevelstool.c (gimp_levels_tool_dialog): Set
	page_size for the Ouput/Input Levels lower/upper adjustments to 0
	to adapt to new and more correct value clamping in GTK+.

svn path=/trunk/; revision=26743
2008-08-24 13:57:42 +00:00
Michael Natterer 9fc779f44f set precision back to PIXEL_CENTER because it's set to SUBPIXEL by the
2008-08-21  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpforegroundselecttool.c
	(gimp_foreground_select_tool_init): set precision back to
	PIXEL_CENTER because it's set to SUBPIXEL by the parent class.


svn path=/trunk/; revision=26687
2008-08-21 08:19:54 +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
Michael Natterer 4c356fe42b make gimp_perspective_clone_get_matrix() static and add
2008-08-20  Michael Natterer  <mitch@gimp.org>

	* app/paint/gimpperspectiveclone.[ch]: make
	gimp_perspective_clone_get_matrix() static and add
	gimp_perspective_clone_set_transform().

	* app/tools/gimpperspectiveclonetool.c
	(gimp_perspective_clone_tool_mode_notify): use above set_transform()
	API instead of poking into the object.

	(gimp_perspective_clone_tool_constructor): call
	gimp_perspective_clone_tool_mode_notify() to set up things instead
	of duplicating code.


svn path=/trunk/; revision=26673
2008-08-20 09:49:40 +00:00
Michael Natterer e650b579a7 formatting.
2008-08-20  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpperspectiveclonetool.[ch]: formatting.


svn path=/trunk/; revision=26672
2008-08-20 08:57:01 +00:00
Michael Natterer 8ed8670d01 formatting.
2008-08-19  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c (gimp_gegl_tool_dialog): formatting.


svn path=/trunk/; revision=26664
2008-08-19 15:42:31 +00:00
Michael Natterer 46c7d2518a remove #include "core/gimpguide.h"
2008-08-16  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpdrawtool.c: remove #include "core/gimpguide.h"


svn path=/trunk/; revision=26597
2008-08-16 15:36:17 +00:00
Sven Neumann 659b1f727f app/tools/gimpfreeselecttool.c formatting.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpfreeselecttool.c
	* app/tools/gimprectangletool.c: formatting.


svn path=/trunk/; revision=26588
2008-08-16 10:07:43 +00:00
Sven Neumann b25e6c0612 another minor coding style cleanup
svn path=/trunk/; revision=26493
2008-08-11 09:54:13 +00:00
Sven Neumann 7de9d15a8a make it compile again
svn path=/trunk/; revision=26492
2008-08-11 09:47:30 +00:00
Sven Neumann 2b68234259 another minor coding style cleanup
svn path=/trunk/; revision=26491
2008-08-11 09:44:38 +00:00
Sven Neumann b060070182 minor coding style cleanups.
2008-08-11  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptexttool.c: minor coding style cleanups.


svn path=/trunk/; revision=26490
2008-08-11 09:41:12 +00:00
Martin Nordholts a81790d789 Oops, forgot to commit gimp_display_shell_get_scaled_viewport() -> gimp_display_shell_scroll_get_scaled_viewport() for gimprectangletool.c
svn path=/trunk/; revision=26478
2008-08-10 10:51:56 +00:00
Sven Neumann 3b067cba23 added gimp_image_get_projection().
2008-08-07  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimage.[ch]: added gimp_image_get_projection().

	* app/display/gimpdisplay-handlers.c
	* app/display/gimpdisplayshell-render.c
	* app/display/gimpdisplayshell-scroll.c
	* app/paint/gimppaintcore.c
	* app/paint/gimpsourcecore.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimppainttool.c
	* app/widgets/gimpsamplepointeditor.c
	* tools/pdbgen/pdb/image.pdb: use the new accessor function.

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


svn path=/trunk/; revision=26413
2008-08-07 09:17:46 +00:00
Sven Neumann 8f2c6c0df5 fixed comment.
2008-08-07  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpcurvestool.h: fixed comment.


svn path=/trunk/; revision=26412
2008-08-07 08:37:58 +00:00
Sven Neumann b8ce815e54 draw the guide all across the canvas, not limiting it to the image.
2008-08-05  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-draw.c 
(gimp_display_shell_draw_guide):
	draw the guide all across the canvas, not limiting it to the 
image.

	* app/tools/gimpdrawtool.[ch]: added new function
	gimp_draw_tool_draw_guide_line().

	* app/tools/gimpmovetool.c (gimp_move_tool_draw): use it.


svn path=/trunk/; revision=26375
2008-08-05 10:11:07 +00:00
Martin Nordholts 0a40def09c Bail out if there is no pending rectangle to synthesize a motion on. Fixes
2008-07-27  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_synthesize_motion): Bail out if there is no
	pending rectangle to synthesize a motion on. Fixes bug #544181.

svn path=/trunk/; revision=26322
2008-07-27 19:06:10 +00:00
Sven Neumann d77ee21b8c app/core/gimpguideundo.c app/core/gimpitemundo.c
2008-07-23  Sven Neumann  <sven@gimp.org>

	* app/core/gimpguideundo.c
	* app/core/gimpitemundo.c
	* app/core/gimplayermaskundo.c
	* app/core/gimppdbprogress.c
	* app/core/gimpstrokedesc.c
	* app/core/gimptooloptions.c
	* app/core/gimptoolpresets.c
	* app/paint/gimppaintoptions.c
	* app/text/gimpfont.c
	* app/tools/gimptool.c
	* app/widgets/gimpaction.c
	* app/widgets/gimpcontrollereditor.c: no need to cast the return
	value of g_value_dup_object().


svn path=/trunk/; revision=26289
2008-07-23 06:47:23 +00:00
Michael Natterer 7750d317c8 set scroll_lock to TRUE while moving or creating sample points so the
2008-07-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpcolortool.c: set scroll_lock to TRUE while moving
	or creating sample points so the image doesn't scroll while a new
	sample point is dragged from the rulers and sample points can be
	deleted by dragging them out of image without scrolling at the
	same time.


svn path=/trunk/; revision=26276
2008-07-22 14:43:52 +00:00
Sven Neumann a00579917a only use the position from the event coordinates when creating or
2008-07-22  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpvectortool.c: only use the position from the 
event
	coordinates when creating or modifying strokes. Initialize all
	other GimpCoords fields with default values.


svn path=/trunk/; revision=26275
2008-07-22 12:33:15 +00:00
Sven Neumann 9fa59a22fd formatting
2008-07-22  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpvectortool.c: formatting

svn path=/trunk/; revision=26274
2008-07-22 11:12:16 +00:00
Sven Neumann 488f656cd2 plugged a not so small memory leak.
2008-07-21  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpdrawtool.c (gimp_draw_tool_on_vectors_handle):
	plugged a not so small memory leak.


svn path=/trunk/; revision=26260
2008-07-21 19:22:27 +00:00
Sven Neumann 7cd338205c fixed typo pointed out by Žygimantas Beručka.
2008-07-17  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpcolorizetool.c: fixed typo pointed out by
	Žygimantas Beručka.


svn path=/trunk/; revision=26226
2008-07-17 19:13:12 +00:00
Sven Neumann caa4c529f5 removed 'use_pressure' field from GimpPaintCore.
2008-07-17  Sven Neumann  <sven@gimp.org>

	* app/paint/gimppaintcore.[ch]: removed 'use_pressure' field 
from
	GimpPaintCore.
	
	* app/paint/gimppaintoptions.[ch]: removed 'use_pressure' 
parameter.

	* app/paint/gimpairbrush.c
	* app/paint/gimpbrushcore.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimperaser.c
	* app/paint/gimpheal.c
	* app/paint/gimppaintbrush.c
	* app/paint/gimpsmudge.c
	* app/tools/gimppainttool.c: changed accordingly.


svn path=/trunk/; revision=26225
2008-07-17 19:00:13 +00:00
Sven Neumann 70cb604509 formatting.
2008-07-12  Sven Neumann  <sven@gimp.org>

	* app/tools/gimprectangletool.c: formatting.


svn path=/trunk/; revision=26151
2008-07-12 09:07:04 +00:00
Sven Neumann 00ef6ab9ec simplified.
2008-07-11  Sven Neumann  <sven@gimp.org>

	* app/tools/gimprotatetool.c (gimp_rotate_tool_key_press): 
simplified.


svn path=/trunk/; revision=26139
2008-07-11 19:38:28 +00:00
Martin Nordholts 19325009fa Extend the interface with this function
2008-07-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scroll.c
	(gimp_display_shell_get_scaled_viewport): Extend the interface
	with this function

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_update_handle_sizes): Forget anything we knew
	about how to interpret the icky GimpDisplayShell offset variables

svn path=/trunk/; revision=26111
2008-07-10 20:19:17 +00:00
Sven Neumann fa9ca40d25 changed expander title to "Brush Dynamics".
2008-07-10  Sven Neumann  <sven@gimp.org>

	* app/tools/gimppaintoptions-gui.c (gimp_paint_options_gui):
	changed expander title to "Brush Dynamics".


svn path=/trunk/; revision=26105
2008-07-10 10:33:49 +00:00
Sven Neumann 462d7c18b9 don't paint while the Shift key is pressed for line drawing (bug #529434).
2008-07-09  Sven Neumann  <sven@gimp.org>

	* app/tools/gimppainttool.c (gimp_paint_tool_motion): don't 
paint
	while the Shift key is pressed for line drawing (bug #529434).


svn path=/trunk/; revision=26090
2008-07-09 06:45:47 +00:00
Sven Neumann 055ca896b9 check for tools derived from GimpPaintBrushTool just as we do in
2008-07-07  Sven Neumann  <sven@gimp.org>

	* app/tools/gimppaintoptions-gui.c (tool_has_size_dynamics): 
check
	for tools derived from GimpPaintBrushTool just as we do in
	tool_has_opacity_dynamics().
	(tool_has_hardness_dynamics): enable hardness dynamics for the
	eraser tool (bug #541691).


svn path=/trunk/; revision=26083
2008-07-07 17:58:16 +00:00
Martin Nordholts ac19e7deb8 Simplify math.
2008-07-05  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c: 
	* app/tools/gimpeditselectiontool.c: Simplify math.

svn path=/trunk/; revision=26066
2008-07-05 11:01:20 +00:00
Martin Nordholts 995a944ca8 Mark the center of rectangles/bounding rectangles so that it is easier to
2008-07-05  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c:
	* app/tools/gimpeditselectiontool.c: Mark the center of
	rectangles/bounding rectangles so that it is easier to predict and
	see where snapping occurs. Completes the fix for bug #527659.

svn path=/trunk/; revision=26065
2008-07-05 09:47:39 +00:00
Martin Nordholts 161c5e9131 Don't expose the icky implementation details.
2008-07-05  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpeditselectiontool.[ch]: Don't expose the icky
	implementation details.

svn path=/trunk/; revision=26064
2008-07-05 08:51:03 +00:00
Michael Natterer 341cec52dc remove size group code because the size group doesn't exist if there is no
2008-06-29  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c (gimp_gegl_tool_dialog): remove size
	group code because the size group doesn't exist if there is no
	settings box.


svn path=/trunk/; revision=26020
2008-06-29 13:54:01 +00:00
Michael Natterer 6aa62a907b app/dialogs/channel-options-dialog.c app/dialogs/palette-import-dialog.c
2008-06-29  Michael Natterer  <mitch@gimp.org>

	* app/dialogs/channel-options-dialog.c
	* app/dialogs/palette-import-dialog.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpnavigationeditor.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpposterizetool.c
	* app/widgets/gimpbrusheditor.c
	* app/widgets/gimpbrushfactoryview.c
	* app/widgets/gimpbrushselect.c
	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcontainertreeview-dnd.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimphistogrambox.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimpscalebutton.c: replace adjustment->value by
	gtk_adjustment_get_value (adjustment).


svn path=/trunk/; revision=26019
2008-06-29 13:41:24 +00:00
Michael Natterer f36cfc0bf2 swap the angles of the dynamics matrix' labels in RTL and LTR mode so the
2008-06-27  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c (gimp_paint_options_gui): swap
	the angles of the dynamics matrix' labels in RTL and LTR mode so
	the beginning of the words are aligned and on bottom.


svn path=/trunk/; revision=25995
2008-06-27 20:26:57 +00:00
Michael Natterer 4bdf9a6d2a add marshaller BOOLEAN__STRING for the change below.
2008-06-25  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpmarshal.list: add marshaller BOOLEAN__STRING for
	the change below.

	* app/widgets/gimpsettingsbox.[ch]: add the import/export dialogs
	here. Add a bunch of parameters to new() to be used by the
	dialogs, they are not properties yet. Changed import() and
	export() signals to pass the selected filename and return a
	boolean indicating success.

	* app/tools/gimpimagemaptool-settings.c: remove the dialog code
	here and connect the import/export functions directly to above
	GimpSettingsBox signals.

	* app/tools/gimpimagemaptool.[ch]: remove file dialog member.


svn path=/trunk/; revision=25991
2008-06-25 14:25:32 +00:00
Michael Natterer 7df6950e19 parse the first line of the file manually and detect whether we are
2008-06-25  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpcurvestool.c (gimp_curves_tool_settings_import):
	parse the first line of the file manually and detect whether we
	are importing an old curves file or a GimpConfig one.


svn path=/trunk/; revision=25988
2008-06-25 08:16:48 +00:00
Martin Nordholts 57e9c9943e Make switching selection mode through modifier keys work again.
2008-06-23  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_modifier_key): Make switching selection
	mode through modifier keys work again.

svn path=/trunk/; revision=25978
2008-06-23 18:41:53 +00:00
Martin Nordholts e068c051f1 When applying angle constraints on the first segment vertex, base on the
2008-06-21  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_update_motion): When applying angle
	constraints on the first segment vertex, base on the last segment
	vertex rather than not applying any constraint at all.

svn path=/trunk/; revision=25972
2008-06-21 09:39:49 +00:00
Martin Nordholts 3c339adacb Make angle constraints with the Free Select Tool by using Ctrl work also
2008-06-20  Martin Nordholts  <martinn@svn.gnome.org>

	Make angle constraints with the Free Select Tool by using Ctrl
	work also when moving vertices, not only when creating new ones.

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_active_modifier_key): Implement.

	(gimp_free_select_tool_update_motion): Put motion logic here so we
	can apply it from both _motion and _active_modifier_key.

	(gimp_free_select_tool_modifier_key): Ignore key presses from
	another display.

svn path=/trunk/; revision=25969
2008-06-20 12:34:37 +00:00
Martin Nordholts 13a102551a Don't alloc/free saved_points_(lower|higher)_segment on each move, instead
* app/tools/gimpfreeselecttool.c: Don't alloc/free
	saved_points_(lower|higher)_segment on each move, instead realloc
	on demand and free on tool destruction, just as we do e.g. for
	points.

svn path=/trunk/; revision=25968
2008-06-20 12:22:46 +00:00
Martin Nordholts 395b1c5a34 Remove n_saved_points_(lower|higher)_segment, we don't need them.
2008-06-20  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c: Remove
	n_saved_points_(lower|higher)_segment, we don't need them.

svn path=/trunk/; revision=25967
2008-06-20 11:40:32 +00:00
Martin Nordholts 4de401f623 Plug leak.
2008-06-20  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c (gimp_free_select_tool_finalize):
	Plug leak.

svn path=/trunk/; revision=25966
2008-06-20 11:23:09 +00:00
Michael Natterer f53e9a45db Latest GTK+ trunk deprecations showed some uglyness in gimp:
2008-06-20  Michael Natterer  <mitch@gimp.org>

	Latest GTK+ trunk deprecations showed some uglyness in gimp:

	* app/tools/gimpeditselectiontool.h: we were still using GTK_CHECK
	macros here, use proper G_TYPE type checking instead.

	* app/widgets/gimpuimanager.c
	* app/widgets/gimpdockable.c: s/GtkDestroyNotify/GDestroyNotify/.

	* plug-ins/help-browser/gimpthrobber.c: s/GtkType/GType/.

	* plug-ins/common/filter-pack.c
	* plug-ins/common/sample-colorize.c
	* plug-ins/imagemap/imap_main.c: s/GtkSignalFunc/GCallback/.


svn path=/trunk/; revision=25965
2008-06-20 11:08:42 +00:00
Martin Nordholts 6e225b60c7 Correct the improved display of the rectangle ratio.
2008-06-13  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c (gimp_rectangle_tool_motion):
	Correct the improved display of the rectangle ratio.

svn path=/trunk/; revision=25946
2008-06-13 17:36:26 +00:00
Sven Neumann 3cb4814efe we need to define the 'highlight' property here as well.
2008-06-13  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptextoptions.c (gimp_text_options_class_init):
	we need to define the 'highlight' property here as well.

svn path=/trunk/; revision=25945
2008-06-13 13:44:00 +00:00
Michael Natterer 8912b68290 app/widgets/Makefile.am app/widgets/widgets-types.h new widget containing
2008-06-13  Michael Natterer  <mitch@gimp.org>

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpsettingsbox.[ch]: new widget containing the
	combo and menu button for the image map tool settings plus most of
	their logic. Has "import" and "export" signals that might go away
	if I figure a way to nicely abstract that. Contains some minor
	bugfixes and cosmetic improvements compared to the old code.

	* app/tools/gimpimagemaptool.[ch]
	* app/tools/gimpimagemaptool-settings.[ch]: changed accordingly,
	mostly removal of lots of code that is now in the widget.


svn path=/trunk/; revision=25943
2008-06-13 11:56:46 +00:00
Sven Neumann fdc55c5cee try to make the display of the aspect ratio somewhat more obvious.
2008-06-12  Sven Neumann  <sven@gimp.org>

	* app/tools/gimprectangletool.c (gimp_rectangle_tool_motion):
	try to make the display of the aspect ratio somewhat more 
obvious.


svn path=/trunk/; revision=25937
2008-06-12 19:24:27 +00:00
Michael Natterer b823c752d0 app/display/gimpdisplayshell-scale.c app/gegl/gimpoperationdesaturate.h
2008-06-04  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-scale.c
	* app/gegl/gimpoperationdesaturate.h
	* app/tools/gimprectangletool.c
	* app/widgets/gimpradioaction.h
	* app/widgets/gimptoggleaction.h: various fixes tpo make gtk-doc
	happy.


svn path=/trunk/; revision=25893
2008-06-04 16:09:57 +00:00
Sven Neumann b1f1852e50 app/tools/gimpcropoptions.c app/tools/gimprectangleoptions.c fixed
2008-06-04  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpcropoptions.c
	* app/tools/gimprectangleoptions.c
	* app/tools/gimprectangleselectoptions.c: fixed handling of the
	"highlight" property that needs different default values for the
	Crop and Rectangle Select tools (bug #536582).

svn path=/trunk/; revision=25890
2008-06-04 13:57:39 +00:00
Sven Neumann 1d4d2be2dd changed descriptions for GimpHistogramScale enum.
2008-06-03  Sven Neumann  <sven@gimp.org>

	* app/widgets/widgets-enums.[ch]: changed descriptions for
	GimpHistogramScale enum.

	* app/tools/gimpimagemaptool.[ch]

	* app/tools/gimpimagemaptool-settings.c: added a GtkSizeGroup for
	aligning with the "Presets" label. Added an accessor for the
	dialog's vbox.

	* 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: use the new accessor. Minor
	dialog cleanups in a few places.

svn path=/trunk/; revision=25884
2008-06-03 10:51:04 +00:00
Martin Nordholts c827f0cd84 Implemented this function to support rotating with arrow keys. See bug
2008-05-31  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprotatetool.c (gimp_rotate_tool_key_press):
	Implemented this function to support rotating with arrow keys. See
	bug #387779.

svn path=/trunk/; revision=25873
2008-05-31 17:51:52 +00:00
Martin Nordholts a3626edd9f Made moving the selection mask in the varoius ways automatically commit
2008-05-30  Martin Nordholts  <martinn@svn.gnome.org>

	Made moving the selection mask in the varoius ways automatically
	commit any pending rectangle/ellipse selection. Fixes bug #349340.

	* app/tools/gimprectangleselecttool.c
	(gimp_rectangle_select_tool_oper_update): Don't disable support
	for moving the selection mask.

	(gimp_rectangle_select_tool_button_press): Handle delegation to
	the selection tool.

	(gimp_rectangle_select_tool_delegate_button_press): New helper
	function.

	(gimp_rectangle_select_tool_execute): Guard against NULL
	tool->display:s.

svn path=/trunk/; revision=25872
2008-05-30 18:46:38 +00:00
Martin Nordholts c2f0cf3ee8 Also show the plain aspect ratio in the status bar along with the
2008-05-29  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c (gimp_rectangle_tool_motion): Also
	show the plain aspect ratio in the status bar along with the
	rectangle size information.

svn path=/trunk/; revision=25847
2008-05-29 04:27:19 +00:00
Michael Natterer 3860e94e9d don't add the gradient box for the blend tool. Clean up the code by moving
2008-05-27  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: don't add the gradient box for
	the blend tool. Clean up the code by moving the checks for the
	tool type out of the utility functions into the main
	gimp_paint_options_gui() function.

	* app/tools/gimpblendoptions.c: add the gradient box here.


svn path=/trunk/; revision=25826
2008-05-27 09:44:16 +00:00
Michael Natterer b819602590 Applied modified patch from Alexia Death. Addresses bug #534770:
2008-05-26  Michael Natterer  <mitch@gimp.org>

	Applied modified patch from Alexia Death. Addresses bug #534770:

	* app/paint/gimppaintoptions.[ch]: add properties for scaling
	the effects of pressure, velocity and hardness and honor them
	in the various get_dynamic_foo() functions.

	(gimp_paint_options_get_dynamic_size): look at
	pressure_options->size again, that code got lost in one of the
	earlier patches.

	* app/tools/gimppaintoptions-gui.c: add GimpScaleButtons to the
	table for the new properties.

	* app/display/gimpdisplayshell-coords.c: don't let "velocity"
	reach 1.0, use 0.9999 instead.


svn path=/trunk/; revision=25816
2008-05-26 19:52:09 +00:00
Michael Natterer e9f98bead5 remove unused includes.
2008-05-26  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: remove unused includes.


svn path=/trunk/; revision=25815
2008-05-26 19:22:40 +00:00
Michael Natterer cd2c6fee40 replace the identical GimpPressureOptions, GimpVelocityOptions and
2008-05-26  Michael Natterer  <mitch@gimp.org>

	* app/paint/gimppaintoptions.[ch]: replace the identical
	GimpPressureOptions, GimpVelocityOptions and GimpRandomOptions
	struct by a single GimpDynamicOptions struct.

	* app/tools/gimppaintoptions-gui.c: don't pass the various
	sub-structs to the _options_gui() function because they are not
	needed.


svn path=/trunk/; revision=25814
2008-05-26 18:54:28 +00:00
Michael Natterer a37509ecdb app/config/gimpbaseconfig.c app/config/gimpguiconfig.c remove unused
2008-05-26  Michael Natterer  <mitch@gimp.org>

	* app/config/gimpbaseconfig.c
	* app/config/gimpguiconfig.c
	* app/tools/gimpcolorpickeroptions.[ch]: remove unused compat
	properties because the config parser silently skips unknown
	properties now.


svn path=/trunk/; revision=25812
2008-05-26 17:47:28 +00:00
Martin Nordholts 5c4bf26cf7 Name cleanup.
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_revert_to_saved_state): Name cleanup.

svn path=/trunk/; revision=25799
2008-05-25 17:37:26 +00:00
Martin Nordholts a0ba68acff Handle the special case when there is only one point, so that moving
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_prepare_for_move)
	(gimp_free_select_tool_revert_to_saved_state)
	(gimp_free_select_tool_move_segment_vertex_to): Handle the special
	case when there is only one point, so that moving segment vertices
	works even if there only is one.

svn path=/trunk/; revision=25798
2008-05-25 17:35:52 +00:00
Martin Nordholts 82f331416f For completeness, comment on some uncommented instance-private variables.
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c: For completeness, comment on
	some uncommented instance-private variables.

svn path=/trunk/; revision=25797
2008-05-25 15:16:46 +00:00
Martin Nordholts 20106d27e7 Properly update the cursor.
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_cursor_update): Properly update the cursor.

svn path=/trunk/; revision=25796
2008-05-25 15:08:50 +00:00
Martin Nordholts 021fa373c3 Added support for supressing handles by holding Shift in the Free Select
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	Added support for supressing handles by holding Shift in the Free
	Select Tool so that new segments can be created where handles
	would otherwise obstruct.

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_handle_segment_selection): Renamed, and
	only select segment vertices if handles are not supressed.

	(gimp_free_select_tool_modifier_key): Make Shift toggle supressing
	handles.

	(gimp_free_select_tool_draw): Don't draw the handles if they are
	supressed.

	(gimp_free_select_tool_should_close): Only accept distance from
	start point as a reason to close the polygon if the handles are
	not supressed.

svn path=/trunk/; revision=25795
2008-05-25 14:31:33 +00:00
Martin Nordholts 5ca90dd406 Added support for double-clicking in the Free Select Tool. A double-click
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	Added support for double-clicking in the Free Select Tool. A
	double-click will commit the selection.

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_get_double_click_info): Helper function to
	retrive GTK+ double-click settings.

	(gimp_free_select_tool_should_close): Take double-clicking into
	account.

	(gimp_free_select_tool_revert_to_saved_state): Bail out if needed.

	(gimp_free_select_tool_button_release): Pass on time when
	clicking.

	(gimp_free_select_tool_handle_click): Pass time to this function,
	and modify it to handle double-clicks.

svn path=/trunk/; revision=25794
2008-05-25 13:44:11 +00:00
Martin Nordholts 0ddc9061f4 Remove invalid comment.
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_button_release): Remove invalid comment.

svn path=/trunk/; revision=25793
2008-05-25 11:50:12 +00:00
Martin Nordholts 866cc37543 A click might have slightly adjusted the points, so revert before doing
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_handle_click): A click might have slightly
	adjusted the points, so revert before doing the selection.
	(gimp_free_select_tool_revert_to_saved_state): Move definition up
	a bit.

svn path=/trunk/; revision=25792
2008-05-25 11:48:37 +00:00
Martin Nordholts 820379250b Make moving selection mask/pixels within the selection work for the Free
2008-05-25  Martin Nordholts  <martinn@svn.gnome.org>

	Make moving selection mask/pixels within the selection work for
	the Free Select Tool, as well as interaction with any resulting
	floating selection.

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_handle_click): Handle floating selections.
	(gimp_free_select_tool_status_update): Show the inital
	instructions until there are 3 or more segment vertices, rather
	than 3 or more points.

	(gimp_free_select_tool_oper_update): When there is no active tool,
	show selection tool status bar help messages instead of the tool
	specific ones.

	(gimp_free_select_tool_delegate_button_press): New helper function
	to decide wether to delgate operation to the selection tool.

	(gimp_free_select_tool_button_press): Handle delegation to the
	selection tool.

svn path=/trunk/; revision=25791
2008-05-25 11:25:56 +00:00
Michael Natterer d43f8bb4d5 fix dynamics grid label positions for RTL mode by attaching the fixed to
2008-05-24  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: fix dynamics grid label
	positions for RTL mode by attaching the fixed to the table *after*
	the toggle buttons (eek). See comment in the code.


svn path=/trunk/; revision=25790
2008-05-24 16:40:28 +00:00
Martin Nordholts d228bf7398 Kill the Polygon Select Tool. The Free Select Tool now provides a superset
2008-05-24  Martin Nordholts  <martinn@svn.gnome.org>

	Kill the Polygon Select Tool. The Free Select Tool now provides a
	superset of the old Polygon Select Tool functionality. We still
	keep the tool icons etc around though, they might come in useful
	in the future.

	* app/tools/gimppolygonselecttool.[ch]: Removed.

	* app/tools/Makefile.am: Removed gimppolygonselecttool.[ch].

	* app/tools/gimp-tools.c (gimp_tools_init): Don't register the
	Polygon Select Tool.

	* app/widgets/gimphelp-ids.h: Remove
	GIMP_HELP_TOOL_POLYGON_SELECT.

svn path=/trunk/; revision=25783
2008-05-24 07:21:55 +00:00
Martin Nordholts 43dec1b186 Draw handles within HANDLE_SIZE * 7 distance from cursor instead of only
2008-05-23  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_draw): Draw handles within HANDLE_SIZE * 7
	distance from cursor instead of only showing the hovered handle.
	(gimp_free_select_tool_oper_update): Remember last coordinates
	given here, so we can do above calculations.

svn path=/trunk/; revision=25782
2008-05-23 21:46:13 +00:00
Sven Neumann 35738aa952 string change.
2008-05-23  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpimagemaptool-settings.c: string change.

svn path=/trunk/; revision=25778
2008-05-23 14:21:32 +00:00
Sven Neumann 5aa59b3ba0 app/core/gimpchannel-select.c app/core/gimpdrawable-bucket-fill.c
2008-05-23  Sven Neumann  <sven@gimp.org>

	* app/core/gimpchannel-select.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-transform.c
	* app/core/gimpimage-crop.c
	* app/dialogs/image-scale-dialog.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimpperspectivetool.c
	* app/tools/gimppolygonselecttool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/tools/gimpsheartool.c
	* libgimpwidgets/gimpcolorprofilestore.c
	* plug-ins/gfig/gfig-dialog.c: use C_() instead of Q_() for
	translations with context.

svn path=/trunk/; revision=25777
2008-05-23 14:09:55 +00:00
Michael Natterer 99a338132b left-align the labels in the new dynamics matrix. Add some code for RTL
2008-05-23  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: left-align the labels in the
	new dynamics matrix. Add some code for RTL layout that doesn't
	work properly yet.


svn path=/trunk/; revision=25772
2008-05-23 08:09:51 +00:00
Michael Natterer d66828c883 replace the pressure-expanded, velocity-expanded and random-expanded
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/paint/gimppaintoptions.[ch]: replace the pressure-expanded,
	velocity-expanded and random-expanded properties by a single
	dynamics-expanded property.

	* app/tools/gimppaintoptions-gui.c: pack the toggle matrix into an
	expander, some cleanup.


svn path=/trunk/; revision=25765
2008-05-22 19:06:51 +00:00
Michael Natterer 791638fb15 revert accidential change of all occurences of "hardness" to "pressure" in
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: revert accidential change of
	all occurences of "hardness" to "pressure" in strings and function
	names.


svn path=/trunk/; revision=25764
2008-05-22 18:54:16 +00:00
Michael Natterer c03253684a factor out a utility function that creates a dynamics check button.
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: factor out a utility function
	that creates a dynamics check button.


svn path=/trunk/; revision=25763
2008-05-22 18:38:18 +00:00
Michael Natterer 3bcf7ff632 first version of a matrix of toggles for the dynamics parameters instead
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppaintoptions-gui.c: first version of a matrix of
	toggles for the dynamics parameters instead of three expanders.


svn path=/trunk/; revision=25762
2008-05-22 18:28:39 +00:00
Martin Nordholts 91cf64359d Base a start of a new segment on the pending point, and enable 15 degree
2008-05-22  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c: Base a start of a new segment on
	the pending point, and enable 15 degree constraints on the pending
	point when Ctrl is being held down.

svn path=/trunk/; revision=25761
2008-05-22 18:05:10 +00:00
Martin Nordholts cb13929f5c app/tools/gimpfreeselecttool.[ch] Fix that some
2008-05-22  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.[ch]
	* app/tools/gimpforegroundselecttool.c: Fix that some
	gimp_free_select_tool_-functions had the wrong name.

svn path=/trunk/; revision=25759
2008-05-22 16:58:21 +00:00
Michael Natterer fe70064f00 Applied slightly modified and fixed patch from Alexia Death which adds a
2008-05-22  Michael Natterer  <mitch@gimp.org>

	Applied slightly modified and fixed patch from Alexia Death which
	adds a "random" axis to the paint dynamics and fixes some issues
	in the previous paint dynamics commits. Fixes bug #529431.

	* app/core/core-types.h: add a "random" axis to GimpCoords.

	* app/display/gimpdisplayshell-coords.c: set it to a random value.

	* app/display/gimpdisplayshell-callbacks.c: on button_press,
	use the dynamics from the last motion event to avoid blotches
	at the beginning of paint strokes.

	* app/paint/gimppaintoptions.[ch]: add random properties the same
	way we do pressure and velocity. Add get_dynamic_size(),
	get_dynamic_color() and get_dynamic_hardness() functions which
	look at all dynamic parameters of the passed coords.

	* app/tools/gimppaintoptions-gui.c: add gui for the random options.

	* app/paint/gimpbrushcore.[ch]: remove calc_brush_scale() and use
	gimp_paint_options_get_dynamic_size_instead().
	Add "dynamic_hardness" parameters to paste_canvas(),
	replace_canvas() and get_brush_mask().

	* app/paint/gimpairbrushoptions.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimperaser.c
	* app/paint/gimpheal.c
	* app/paint/gimppaintbrush.c
	* app/paint/gimpsmudge.c: calculate the dynamic hardness and pass
	it to above brush core functions. Use the get_dynamic_color() to
	calculate the gradient color.


svn path=/trunk/; revision=25758
2008-05-22 16:38:57 +00:00
Sven Neumann ea80388073 use a logarithmic slider.
2008-05-22  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpposterizetool.c (gimp_posterize_tool_dialog):
	use a logarithmic slider.

svn path=/trunk/; revision=25757
2008-05-22 16:18:57 +00:00
Martin Nordholts 3ba5ecb5eb Remember the selection operation in use when the tool was started, and use
2008-05-22  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c: Remember the selection operation
	in use when the tool was started, and use that when doing the
	selection. Improvements are still to be made with regards to
	synchronizing the tool options with the selection operation
	actually used.

svn path=/trunk/; revision=25756
2008-05-22 15:40:18 +00:00
Michael Natterer 8004eba247 check if the tool class has the "settings_name" string set to decide
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.c: check if the tool class has
	the "settings_name" string set to decide whether to add
	the settings GUI.

	* app/tools/gimpdesaturatetool.c
	* app/tools/gimpposterizetool.c: don't set any settings
	strings. Presets make no sense for tools with just one parameter.


svn path=/trunk/; revision=25755
2008-05-22 15:39:00 +00:00
Michael Natterer e3ffcae1bb Fix menu item label.
svn path=/trunk/; revision=25753
2008-05-22 11:25:56 +00:00
Michael Natterer 9f85ee0070 s/save/export/g, s/load/import/g, removed button tooltip members.
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.[ch]: s/save/export/g,
	s/load/import/g, removed button tooltip members.

	* app/tools/gimpimagemaptool-settings.[ch]
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdesaturatetool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpthresholdtool.c: changed accordingly.

	* app/tools/gimpimagemaptool-settings.c: clean up menu item creation.


svn path=/trunk/; revision=25752
2008-05-22 11:00:50 +00:00
Michael Natterer 4aaf1c4737 delete trailing whitespace.
2008-05-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpfreeselecttool.c: delete trailing whitespace.


svn path=/trunk/; revision=25751
2008-05-22 10:53:20 +00:00
Sven Neumann b3ac4eadb6 make the mnemonic work
svn path=/trunk/; revision=25750
2008-05-22 09:05:30 +00:00
Sven Neumann 0d6c259be3 added a call to gimp_tool_options_create_folder().
2008-05-22  Sven Neumann  <sven@gimp.org>

	* app/tools/gimp-tools.c (gimp_tools_init): added a call to
	gimp_tool_options_create_folder().

	* app/core/gimp-user-install.c (gimp_user_install_items): no need
	to create the tool-options folder here if we are doing that on
	each startup.

svn path=/trunk/; revision=25749
2008-05-22 09:01:08 +00:00
Sven Neumann e161a6148c use a combo-box for the curve type.
2008-05-22  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpcurvestool.c (gimp_curves_tool_dialog): use a
	combo-box for the curve type.

svn path=/trunk/; revision=25748
2008-05-22 08:39:30 +00:00
Martin Nordholts 41f102f1ab Don't return in the middle of the function.
2008-05-22  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_cursor_update): Don't return in the middle
	of the function.

svn path=/trunk/; revision=25746
2008-05-22 05:44:28 +00:00
Martin Nordholts 79623b1ade "Draw a rough circle around the object to extract" -> "Rougly outline the
2008-05-21  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpforegroundselecttool.c
	(gimp_foreground_select_tool_oper_update): "Draw a rough circle
	around the object to extract" -> "Rougly outline the object to
	extract".

svn path=/trunk/; revision=25743
2008-05-21 19:48:02 +00:00
Martin Nordholts 17e98ebccc Don't expose implementation details.
2008-05-21  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.[ch]: Don't expose implementation
	details.

	* app/tools/gimpforegroundselecttool.c
	(gimp_foreground_select_tool_select): Use new
	gimp_free_select_get_points() functions since we don't know
	anything about how the Free Select Tool is implemented any longer.

svn path=/trunk/; revision=25742
2008-05-21 19:36:16 +00:00
Michael Natterer 986ba501f5 app/tools/gimpimagemaptool.[ch] turn the ugly row of favorites options
2008-05-21  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.[ch]
	* app/tools/gimpimagemaptool-settings.c: turn the ugly row of
	favorites options buttons into a menu that's attached to an arrow
	button right of the favorites combo.


svn path=/trunk/; revision=25741
2008-05-21 19:14:46 +00:00
Michael Natterer 48fbb509a4 remove unused variable.
2008-05-21  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpcurvestool.c: remove unused variable.


svn path=/trunk/; revision=25740
2008-05-21 19:12:49 +00:00
Martin Nordholts 3842f7cb03 Made the Foreground Select Tool work again.
2008-05-21  Martin Nordholts  <martinn@svn.gnome.org>

	Made the Foreground Select Tool work again.

	* app/tools/gimpforegroundselecttool.c
	(gimp_foreground_select_tool_control): Set tool->display =
	NULL when halting the tool.

	(gimp_foreground_select_tool_button_press): Only activate the
	tool control if it is not active (it might be actived already
	by the Free Select Tool).

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_commit): Don't _halt explicitly
	here. If a tool implementation wants to halt in this
	situation, let them do that in their
	GimpFreeSelectTool::select() instead.

svn path=/trunk/; revision=25735
2008-05-21 18:23:23 +00:00
Martin Nordholts 97edc3567f Slightly improve one of the status bar messages.
2008-05-21  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_status_update): Slightly improve one of the
	status bar messages.

svn path=/trunk/; revision=25733
2008-05-21 15:39:52 +00:00
Sven Neumann c19b2170ff changed to take a pointer as first argument as all PixelProcessor
2008-05-21  Sven Neumann  <sven@gimp.org>

	* app/base/desaturate.[ch]: changed to take a pointer as first
	argument as all PixelProcessor functions.

	* app/core/gimpdrawable-desaturate.c: changed accordingly.

	* app/tools/gimpdesaturatetool.[ch]: added legacy code path.

svn path=/trunk/; revision=25730
2008-05-21 14:20:15 +00:00
Sven Neumann e86e003224 Add Desaturate as an image-map tool with live preview (bug #533808):
2008-05-21  Sven Neumann  <sven@gimp.org>

	Add Desaturate as an image-map tool with live preview (bug #533808):

	* app/gegl/Makefile.am
	* app/gegl/gegl-types.h
	* app/gegl/gimpdesaturateconfig.[ch]: added config object for the
	desaturate point filter.
	
	* app/gegl/gimpoperationdesaturate.[ch]: derive from
	GimpOperationPointFilter. Unrolled the inner loop.

	* app/core/gimpdrawable-desaturate.c: changed accordingly.

	* app/tools/Makefile.am
	* app/tools/gimpdesaturatetool.[ch]: added desaturate as an
	imagemap tool. So far only the GEGL code path is implemented.

	* app/tools/gimp-tools.c: register the new tool.

	* app/dialogs/dialogs.c: register the new tool dialog.

	* app/dialogs/Makefile.am
	* app/dialogs/desaturate-dialog.[ch]: removed the desaturate dialog.

	* app/actions/drawable-actions.c
	* app/actions/drawable-commands.[ch]: removed action
	"drawable-desaturate".

	* app/widgets/gimphelp-ids.h: changed help IDs accordingly.

	* menus/image-menu.xml.in: replaced "drawable-desaturate" with
	"tools-desaturate".

	* libgimpwidgets/gimpstock.h: added a define for
	GIMP_STOCK_TOOL_DESATURATE.

svn path=/trunk/; revision=25726
2008-05-21 13:11:06 +00:00
Michael Natterer a921d65df6 app/core/Makefile.am app/core/core-types.h new GimpViewable subclass which
2008-05-20  Michael Natterer  <mitch@gimp.org>

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpimagemapconfig.[ch]: new GimpViewable subclass
	which has a "time" property. Sets the object's name to a date
	string if a time != 0 gets set. Has a compare function which first
	sorts the objects with a timestamp in MRU order and then the
	objects without timestamp by name.

	* app/gegl/gimpbrightnesscontrastconfig.[ch]
	* app/gegl/gimpcolorbalanceconfig.[ch]
	* app/gegl/gimpcolorizeconfig.[ch]
	* app/gegl/gimpcurvesconfig.[ch]
	* app/gegl/gimphuesaturationconfig.[ch]
	* app/gegl/gimplevelsconfig.[ch]
	* app/gegl/gimpposterizeconfig.[ch]
	* app/gegl/gimpthresholdconfig.[ch]: derive from GimpImageMapConfig.

	* app/tools/gimpimagemaptool.c: sort the settings container with
	above compare function.

	* app/tools/gimpimagemaptool-settings.c: add utility functions
	for loading and saving the settings container. In the settings
	combo, add a separator between MRU items and favorites.

	* app/Makefile.am: make the thing link.


svn path=/trunk/; revision=25724
2008-05-20 21:41:47 +00:00
Martin Nordholts 889cc7155a Increase handle size to 12 pixels (the same size as for the Paths Tool).
2008-05-20  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpfreeselecttool.c: Increase handle size to 12
	pixels (the same size as for the Paths Tool).

svn path=/trunk/; revision=25722
2008-05-20 19:09:41 +00:00
Martin Nordholts 59e3ee1317 Added statusbar help-messages for the Free Select Tool.
2008-05-20  Martin Nordholts  <martinn@svn.gnome.org>

	Added statusbar help-messages for the Free Select Tool.

	* app/tools/gimpfreeselecttool.c
	(gimp_free_select_tool_oper_update): Don't bail out if
	tool->display is NULL, instead modify the underlying logic to deal
	with this.

svn path=/trunk/; revision=25721
2008-05-20 17:06:19 +00:00
Michael Natterer d6e3339f1b remove gimp_image_map_tool_add_recent()...
2008-05-20  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.c: remove
	gimp_image_map_tool_add_recent()...

	* app/tools/gimpimagemaptool-settings.[ch]: ...and add it here.


svn path=/trunk/; revision=25720
2008-05-20 15:50:49 +00:00
Michael Natterer 38ee606813 unref the new settings object after adding it to the recent container.
2008-05-20  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.c (gimp_image_map_tool_add_recent):
	unref the new settings object after adding it to the recent
	container.

	* app/tools/gimpimagemaptool-settings.c: add a "Save to Favorites"
	button which pops a string entry dialog and saves the current
	settings to the recent container.


svn path=/trunk/; revision=25719
2008-05-20 15:03:03 +00:00
Michael Natterer 353283b8e8 app/tools/Makefile.am new files containing all the recent settings and
2008-05-20  Michael Natterer  <mitch@gimp.org>

	* app/tools/Makefile.am
	* app/tools/gimpimagemaptool-settings.[ch]: new files containing
	all the recent settings and settings load/save GUI and code.  Got
	rid of shortcut loading/saving using shift+click. Added default
	implementations of ::settings_load() and ::settings_save().
	The GUI is currently horrible, work in progress!

	* app/tools/gimpimagemaptool.c: removed the settings code here.

	* app/tools/gimpcurvestool.c * app/tools/gimplevelstool.c: don't
	pack the load and save buttons, this is done generically for all
	tools now.

	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorizetool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpthresholdtool.c: set the load/save related members
	of GimpImageMapToolClass.


svn path=/trunk/; revision=25718
2008-05-20 14:17:13 +00:00
Sven Neumann 115bf7cedd app/tools/gimpbrightnesscontrasttool.c fixed grammar.
2008-05-20  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpbrightnesscontrasttool.c 
	* app/tools/gimplevelstool.c: fixed grammar.


svn path=/trunk/; revision=25716
2008-05-20 06:14:53 +00:00
Michael Natterer 62719d6703 Unabstract image map tool settings load/save a bit before it's turned into
2008-05-19  Michael Natterer  <mitch@gimp.org>

	Unabstract image map tool settings load/save a bit before it's
	turned into generic load/save for all image map tools:

	* app/gegl/gimpcurvesconfig.[ch]
	* app/gegl/gimplevelsconfig.[ch]: add GError** to save_cruft()
	functions.

	* app/tools/gimpimagemaptool.[ch]: add GError to
	::settings_save(), changed "file" parameter of ::settings_load()
	and ::settings_save() to "filename", removed
	gimp_image_map_tool_load_save() utility function and moved the
	code to the settings_load() and settings_save() utility functions.

	* app/tools/gimpcurvestool.c
	* app/tools/gimplevelstool.c: changed accordingly. Open and close
	the settings files here.


svn path=/trunk/; revision=25714
2008-05-19 18:22:01 +00:00
Michael Natterer 4d0b4464ac made the lists of recent settings persistent. Note that the settings of
2008-05-18  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.c: made the lists of recent settings
	persistent. Note that the settings of tools that modify multiple
	channels or ranges are saved incompletely because their settings
	still lack custom serialize() implementations. Work in progress.


svn path=/trunk/; revision=25702
2008-05-18 17:01:48 +00:00
Martin Nordholts b615941210 Merged the Polygon Select Tool capabilities with the Free Select Tool.
2008-05-18  Martin Nordholts  <martinn@svn.gnome.org>

	Merged the Polygon Select Tool capabilities with the Free Select
	Tool. Among the things still to do is improved help texts, more
	suitable graphics, and cursor mangement, but the core
	functionality is in place. Thanks to Alexia Death for initial
	testing. It will also be neccesary to do some work to adapt the
	Foreground Select Tool to the new Free Select Tool implementation.

	Quick instructions on how the tool works:

	 o A click adds a polygonal segment, a drag adds a free-hand
	   segment
	 o Return-key commits, Escape-key cancels, Backspace-key removes
	   last segment
	 o You can grab and move segment vertices
	 o You can cancel both a move, and the creation of a segment

	* app/tools/gimpfreeselecttool.[ch]: More or less
	reimplemented. We keep a sequential array of all the points in the
	polygon (including the free segments), and we have another array
	with point indices that we use to represent the segments. On top
	of this we have a few helper functions that tries to abstract away
	the pretty raw nature of the implementation.

	* app/tools/gimpforegroundselecttool.[ch]: Keep track on its own
	last_coord, and adjust to the new implementation of the Free
	Select Tool. Still needs some work, for example handling that the
	Free Select Tool now resets GimpTool::display.
	(gimp_foreground_select_tool_key_press): Pass on key event to
	parent class when appropriate. (Bails out too early though...)

svn path=/trunk/; revision=25693
2008-05-18 11:39:17 +00:00
Michael Natterer 228dd93e9d add gimp_image_map_tool_edit_as().
2008-05-17  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.[ch]: add gimp_image_map_tool_edit_as().

	* app/tools/gimplevelstool.c (levels_to_curves_callback): use it.

	* app/gegl/gimpbrightnesscontrastconfig.[ch]: add
	gimp_brightness_contrast_config_to_levels_config().

	* app/tools/gimpbrightnesscontrasttool.c: implement "Edit as Levels".


svn path=/trunk/; revision=25690
2008-05-17 17:57:39 +00:00
Michael Natterer 2a38f864f2 add new function gimp_stock_button_new() which creates a button with icon
2008-05-17  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpwidgets-constructors.[ch]: add new function
	gimp_stock_button_new() which creates a button with icon and label
	which is *not* the stock_id's label.

	* app/dialogs/preferences-dialog.c (prefs_button_add)
	* app/tools/gimplevelstool.c (gimp_levels_tool_dialog): use it.


svn path=/trunk/; revision=25688
2008-05-17 14:29:25 +00:00
Michael Natterer e801795022 app/core/gimpimagefile.c app/tools/gimpaligntool.c
2008-05-17  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimagefile.c
	* app/tools/gimpaligntool.c
	* app/tools/gimpselectiontool.c
	* app/tools/gimpvectortool.c
	* plug-ins/color-rotate/color-rotate-dialog.c
	* plug-ins/common/noise-rgb.c
	* plug-ins/common/value-propagate.c
	* plug-ins/gfig/gfig-dialog.c
	* plug-ins/gfig/gfig.h
	* plug-ins/gimpressionist/general.c
	* plug-ins/gimpressionist/gimpressionist.h
	* plug-ins/gimpressionist/orientation.c
	* plug-ins/gimpressionist/size.c
	* plug-ins/gimpressionist/utils.c
	* plug-ins/gradient-flare/gradient-flare.c
	* plug-ins/ifs-compose/ifs-compose.c
	* plug-ins/imagemap/imap_main.c
	* plug-ins/imagemap/imap_preferences.c: in latest GLib _() returns
	"const gchar*" as it should. Add const qualifiers to local utility
	functions and some explicit casts to fix the warnings caused by
	this.


svn path=/trunk/; revision=25685
2008-05-17 13:08:19 +00:00
Michael Natterer ddf2dca558 First prototype of a button in the levels tool dialog that will jump the
2008-05-13  Michael Natterer  <mitch@gimp.org>

	First prototype of a button in the levels tool dialog that will
	jump the the curves tool with the same settings:

	* app/gegl/gimplevelsconfig.[ch]: add new function
	gimp_levels_config_to_curves_config() which converts a
	GimpLevelsConfig to a GimpCurvesConfig. Still lacks support
	for gamma.

	* app/tools/gimplevelstool.c: add "Edit this Settings as Curves"
	button and jump to curves when clicked. Still ugly.


svn path=/trunk/; revision=25654
2008-05-13 20:52:24 +00:00
Sven Neumann 6e6a0355aa app/core/Makefile.am
2008-05-11  Sven Neumann  <sven@gimp.org>

	* app/core/Makefile.am
	* app/core/gimpcurve.[ch]:
	* app/core/gimpcurve-map.[ch]: split curve map functions into
	seperate files.

	* app/gegl/gimpoperationcurves.c
	* app/tools/gimpcurvestool.c
	* app/widgets/gimpcurveview.c: changed accordingly.

	* app/Makefile.am (AM_LDFLAGS): make it link.


svn path=/trunk/; revision=25642
2008-05-11 14:56:57 +00:00
Sven Neumann a392a231d3 renamed gimp_curve_map() to gimp_curve_map_value(). Added new function
2008-05-11  Sven Neumann  <sven@gimp.org>

	* app/core/gimpcurve.[ch]: renamed gimp_curve_map() to
	gimp_curve_map_value(). Added new function 
gimp_curve_map_pixels()
	which will allow for better optimization.

	* app/gegl/gimpoperationcurves.c 
(gimp_operation_curves_process):
	use gimp_curve_map_pixels().

	* app/tools/gimpcurvestool.c
	* app/widgets/gimpcurveview.c: follow API change.


svn path=/trunk/; revision=25641
2008-05-11 14:48:22 +00:00
Martin Nordholts f5c4c35ff8 No need to expose definitions of GimpCropTool or GimpCropToolClass.
2008-05-11  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpcroptool.[ch]: No need to expose definitions of
	GimpCropTool or GimpCropToolClass.

svn path=/trunk/; revision=25640
2008-05-11 13:23:35 +00:00
Martin Nordholts de8909ddee Fix emission of rectangle-change-complete signals.
2008-05-11  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c: Fix emission of
	rectangle-change-complete signals.

	* app/tools/gimpcroptool.c
	* app/tools/gimprectangleselecttool.c:
	Use the rectangle-change-complete signal to update the default
	aspect ratio. Fixes bug #530519.

	* app/tools/gimpcroptool.c
	(gimp_crop_tool_button_release)
	(gimp_crop_tool_options_notify)
	* app/tools/gimprectangleselecttool.c
	(gimp_rectangle_select_tool_button_release): No need to explicitly
	update option defaults since it is handled through the
	rectangle-change-complete signal now.

svn path=/trunk/; revision=25639
2008-05-11 13:01:24 +00:00
Martin Nordholts d933812406 Active the tool control earlier. (gimp_rectangle_tool_synthesize_motion):
2008-05-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_button_press): Active the tool control
	earlier.
	(gimp_rectangle_tool_synthesize_motion): Bail out if the tool
	control is active, we don't want to synthesize a motion in this
	case as it emits unwanted rectangle-changed signals.

svn path=/trunk/; revision=25630
2008-05-10 19:19:47 +00:00
Martin Nordholts e6beb59347 Don't forget updating the default apsect ratio when cancelling a rectangle
2008-05-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangleselecttool.c
	(gimp_rectangle_select_tool_cancel): Don't forget updating the
	default apsect ratio when cancelling a rectangle select.

svn path=/trunk/; revision=25619
2008-05-10 12:44:04 +00:00
Sven Neumann 9f582ed6ac rerender the text layer as suggested in bug #532078.
2008-05-10  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptexttool.c (gimp_text_tool_confirm_response):
	rerender the text layer as suggested in bug #532078.
	(gimp_text_tool_confirm_dialog): minor dialog improvements.


svn path=/trunk/; revision=25618
2008-05-10 12:36:06 +00:00
Martin Nordholts 05320b55ea Don't forget updating the integer representation when reverting the
2008-05-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_button_release): Don't forget updating the
	integer representation when reverting the rectangle after
	cancelling a rubber-banding.

svn path=/trunk/; revision=25610
2008-05-10 10:34:03 +00:00
Martin Nordholts a535806b14 Update the tool options after a release; the rectangle might change if a
2008-05-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_button_release): Update the tool options
	after a release; the rectangle might change if a rubber-banding is
	cancelled.

svn path=/trunk/; revision=25608
2008-05-10 10:25:23 +00:00
Sven Neumann 9b7a46311f don't reserve Delete for use by tools. Fixes bug #532116.
2008-05-10  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_events) 
(gimp_display_shell_canvas_tool_events):
	don't reserve Delete for use by tools. Fixes bug #532116.

	* app/tools/gimpimagemaptool.c
	* app/tools/gimptransformtool.c: don't use Delete (you can still
	use the Backspace key to achieve the same).


svn path=/trunk/; revision=25607
2008-05-10 10:20:42 +00:00
Michael Natterer 82c2616f0f Applied modified patch from Alexia Death which adds velocity support to
2008-05-10  Michael Natterer  <mitch@gimp.org>

	Applied modified patch from Alexia Death which adds velocity
	support to paint tools in the spirit of the pressure support we
	already have. Fixes bug #529431.

	* app/display/gimpdisplayshell-coords.c
	(gimp_display_shell_eval_event): tweak velocity calculation to
	work in screen coordinates.

	* app/paint/gimppaintoptions.[ch]: add velocity options in the
	same way as there are pressure options. Add utility functions
	which return dynamic opatity and dynamic rate according to the the
	option's settings and some GimpCoords' pressure and velocity.

	* app/tools/gimppaintoptions-gui.c: add GUI for the velocity
	options.

	* app/paint/gimpbrushcore.h: remove PRESSURE_SCALE define, it's
	now in gimppaintoptions.h.

	* app/paint/gimpbrushcore.c (gimp_brush_core_interpolate):
	inerpolate velocity too.

	(gimp_brush_core_calc_brush_scale): take velocity into account.

	(gimp_brush_core_get_brush_mask): always pressurize the mask in
	the GIMP_BRUSH_PRESSURE because there always is velocity (unlike
	pressure which is only there on tablets).

	* app/paint/gimpairbrush.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimperaser.c
	* app/paint/gimpheal.c
	* app/paint/gimppaintbrush.c
	* app/paint/gimpsmudge.c: get opacity and rate from the new paint
	options utility functions which take both pressure and velocity
	into account.

	* app/paint/gimppaintbrush.c: take velocity into account when
	calculating the gradient color offset.

	* app/paint/gimpairbrush.c: do some additional fiddling with
	velocity in the asynchronous airbrush timeout.

	* app/paint/gimpairbrushoptions.c: override the velocity-size
	property and have it default to FALSE.


svn path=/trunk/; revision=25604
2008-05-10 10:03:21 +00:00
Martin Nordholts d6db9d5262 Add a GimpRectangleTool::cancel() implementation that updates default
2008-05-10  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpcroptool.c: Add a GimpRectangleTool::cancel()
	implementation that updates default aspect ratio when cancelling a
	crop.

svn path=/trunk/; revision=25601
2008-05-10 07:34:22 +00:00
Martin Nordholts 0a27fd37fa Keep track of the current image and manage a subscription to
2008-05-09  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpcroptool.[ch]: Keep track of the current image and
	manage a subscription to "size-changed" so that default aspect
	ratio is properly updated.
	(gimp_crop_tool_execute): No need to explicitly call
	gimp_crop_tool_update_option_defaults() any longer.

svn path=/trunk/; revision=25598
2008-05-09 12:46:28 +00:00
Simon Budig f65cb91356 kind of resurrect the blending modes, although now implemented as
2008-05-09  Simon Budig  <simon@gimp.org>

	* app/core/gimpscanconvert.[ch]: kind of resurrect the
	blending modes, although now implemented as compositing
	on top of the existing content of a mask.

	* app/tools/gimpforegroundselecttool.c: changed accordingly


svn path=/trunk/; revision=25595
2008-05-09 11:18:44 +00:00
Simon Budig 5426c0c10e removed Libart usage, replaced with Cairo. Dashed strokes do not yet work
2008-05-09  Simon Budig  <simon@gimp.org>

	* app/core/gimpscanconvert.[ch]: removed Libart usage,
	  replaced with Cairo. Dashed strokes do not yet work again, will
	  happen tomorrow. Also the blending modes need a second look at.

	  Also removed deprecated API which made it unnecessarily complicated.

	* app/tools/gimpiscissorstool.c: use the current API.

	* app/core/Makefile.am
	* app/Makefile.am
	* configure.in: removed libart dependency, added cairo dependency
	  where necessary.


svn path=/trunk/; revision=25591
2008-05-08 23:35:53 +00:00
Martin Nordholts fc35afe371 Make it feel like a class member function by G_CONNECT_SWAPPED-izing it.
2008-05-07  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpcroptool.c (gimp_crop_tool_image_changed): Make it
	feel like a class member function by G_CONNECT_SWAPPED-izing it.

svn path=/trunk/; revision=25582
2008-05-07 17:55:39 +00:00
Sven Neumann 563684d665 app/tools/gimppainttool.c applied patch from Alexia Death which changes
2008-05-05  Sven Neumann  <sven@gimp.org>

	* app/tools/gimppainttool.c
	* app/display/gimpdisplayshell-coords.c: applied patch from 
Alexia
	Death which changes the maximum smoothing for paint tools to 
more
	conservative default and adds velocity dependent smooth 
suppression.


svn path=/trunk/; revision=25564
2008-05-05 06:21:22 +00:00
Martin Nordholts 032b3998d4 gimptexttool.c
2008-05-02  Martin Nordholts  <martinn@svn.gnome.org>

	* gimptexttool.c
	* gimptexttool.h:
	* gimprectangletool.c
	* gimprectangletool.h
	* gimprectangleselecttool.c: Renamed the "rectangle-changed"
	signal to "rectangle-change-complete" which is much better name
	since the signal is not emited when the rectangle is changed, but
	when the change is complete.

svn path=/trunk/; revision=25557
2008-05-02 09:05:13 +00:00
Martin Nordholts b9987bbfb6 Minor simplification.
2008-05-01  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_active_modifier_key): Minor simplification.

svn path=/trunk/; revision=25555
2008-05-01 19:29:15 +00:00
Martin Nordholts b9aa7f2c67 Align static function prototpyes.
2008-04-30  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimpcroptool.c: Align static function prototpyes.

svn path=/trunk/; revision=25554
2008-04-30 18:55:49 +00:00
Michael Natterer 1a264f0989 clean up last commit.
2008-04-26  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c: clean up last commit.


svn path=/trunk/; revision=25535
2008-04-26 12:12:26 +00:00
Øyvind Kolås 9672d0a207 made the GEGL tool only show ops from relevant categories, the list of
* app/tools/gimpgegltool.c: (gimp_get_subtype_classes),
(gimp_gegl_tool_compare_operation_names), (gimp_get_geglopclasses),
(gimp_gegl_tool_dialog): made the GEGL tool only show ops from
relevant categories, the list of relevant categories is hard coded
for now.

svn path=/trunk/; revision=25533
2008-04-26 11:49:25 +00:00
Martin Nordholts 2d2358b47f No need to bail out if there is no display.
2008-04-26  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_options_notify): No need to bail out if there
	is no display.

svn path=/trunk/; revision=25532
2008-04-26 11:14:19 +00:00
Martin Nordholts 5743e21890 Some more simplifications and cleanups.
2008-04-26  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_options_notify): Some more simplifications
	and cleanups.

svn path=/trunk/; revision=25531
2008-04-26 10:54:34 +00:00
Martin Nordholts f2a00b3018 Simplifications and cleanups.
2008-04-26  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_options_notify): Simplifications and
	cleanups.

svn path=/trunk/; revision=25530
2008-04-26 10:38:53 +00:00
Martin Nordholts 947e873793 Do appropriate equal and not-equal comparions for floting point numbers.
2008-04-24  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_options_notify): Do appropriate equal and
	not-equal comparions for floting point numbers. Fixes bug #527863.

svn path=/trunk/; revision=25516
2008-04-24 05:55:59 +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
Sven Neumann df22da37fd formatting.
2008-04-14  Sven Neumann  <sven@gimp.org>

	* app/tools/gimppolygonselecttool.c: formatting.

svn path=/trunk/; revision=25486
2008-04-14 12:56:25 +00:00
Michael Natterer 3a2cbab0db simplify and fix logic to do the "right" thing. Hard to describe, try
2008-04-14  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppolygonselecttool.c
	(gimp_polygon_select_tool_button_release): simplify and fix logic
	to do the "right" thing. Hard to describe, try youself ;)


svn path=/trunk/; revision=25485
2008-04-14 12:50:21 +00:00
Sven Neumann e7c5bf8086 added stock-id parameters to all statusbar setters.
2008-04-14  Sven Neumann  <sven@gimp.org>

	* app/display/gimpstatusbar.[ch]: added stock-id parameters to 
all
	statusbar setters.

	* app/display/gimpdisplayshell-title.c: pass NULL as stock-id.

	* app/tools/gimptool.c: pass the tool icon to the statusbar.

	* app/tools/gimpeditselectiontool.c 
(gimp_edit_selection_tool_start):
	inherit the tool-info from the parent tool.


svn path=/trunk/; revision=25477
2008-04-14 06:28:43 +00:00
Sven Neumann 9db8d2ef35 formatting.
2008-04-13  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptool.h: formatting.


svn path=/trunk/; revision=25476
2008-04-13 18:04:27 +00:00
Michael Natterer af484e2fe2 minor cosmetics.
2008-04-13  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpiscissorstool.c: minor cosmetics.

	* cursors/gimp-tool-cursors.xcf: add the new SELECT modifier.


svn path=/trunk/; revision=25474
2008-04-13 13:50:01 +00:00
Martin Nordholts a8bbf6b29b Applied modified patch from Daniel Hornung that changes the mouse cursor
2008-04-12  Martin Nordholts  <martinn@svn.gnome.org>

	Applied modified patch from Daniel Hornung that changes the mouse
	cursor to a "clicking will create a selection"-icon when hovering
	the center of a pending Scissors Select Tool selection (bug #493370)

	* app/tools/gimpiscissorstool.c
	(gimp_iscissors_tool_cursor_update): Use the new cursor icon.

	* cursors/modifier-select.png
	* cursors/xbm/modifier-select.xbm
	* cursors/xbm/modifier-select-mask.xbm: New cursor icon.

	* cursors/makefile.msc
	* cursors/Makefile.am 
	* app/widgets/gimpcursor.c
	* app/widgets/widgets-enums.h: Changed accordingly.

svn path=/trunk/; revision=25473
2008-04-12 11:40:52 +00:00
Sven Neumann 22205696de tweaked the layout to save a few pixels.
2008-04-11  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptextoptions.c (gimp_text_options_gui): tweaked the
	layout to save a few pixels.

svn path=/trunk/; revision=25467
2008-04-11 15:30:58 +00:00
Sven Neumann f1196fd405 added missing file.
2008-04-07  Sven Neumann  <sven@gimp.org>

	* app/gegl/Makefile.am (libappgegl_a_SOURCES): added missing 
file.

	* app/tools/tools-enums.c: regenerated.


svn path=/trunk/; revision=25404
2008-04-07 20:56:03 +00:00
Sven Neumann 3f129393cf app/tools/gimptexttool.c removed out 'force-narrow' mode as it is hard to
2008-04-07  Sven Neumann  <sven@gimp.org>

	* app/tools/gimprectangletool.[ch]:
	* app/tools/gimptexttool.c removed out 'force-narrow' mode as it
	is hard to use and just looks broken.


svn path=/trunk/; revision=25399
2008-04-07 18:57:32 +00:00
Sven Neumann b677d882a4 formatting.
2008-04-07  Sven Neumann  <sven@gimp.org>

	* app/tools/gimprectangletool.c: formatting.


svn path=/trunk/; revision=25398
2008-04-07 18:25:18 +00:00
William Skaggs d3a6f7f2a1 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/tools/gimprectangletool.[ch]: add "force_narrow"
	parameter.

	* app/tools/gimptexttool.c: Force rectangle to always
	be narrow, and squash a few bugs.

svn path=/trunk/; revision=25397
2008-04-07 16:32:31 +00:00
Sven Neumann 1006d379e4 app/display/gimpdisplayshell-callbacks.c
2008-04-07  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-coords.[ch]
	* app/tools/gimppainttool.c
	* app/tools/gimptool.[ch]: applied patch from Alexia Death as
	attached to bug #508639. This change makes the smoothing depend on
	the active tool.

svn path=/trunk/; revision=25392
2008-04-07 13:54:43 +00:00
William Skaggs 98e0671a85 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/text/gimptextlayout.c
	* app/tools/gimptexttool.[ch]
	* app/tools/gimprectangletool.[ch]
	* app/tools/gimptextoptions.c: allow resizing of text
	box.  This is work in progress, and needs some tweaks
	and fixes.  See bug #122707.

svn path=/trunk/; revision=25344
2008-04-02 21:32:32 +00:00
Sven Neumann 842d68b491 removed frame around the mode radio buttons (bug #525747).
2008-04-02  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpperspectiveclonetool.c: removed frame around the
	mode radio buttons (bug #525747).

	* app/tools/gimpdodgeburntool.c: relabelled "Mode" frame to 
"Range".


svn path=/trunk/; revision=25336
2008-04-02 18:53:53 +00:00
Mukund Sivaraman 0708ffea76 Fixes for some Sparse reported issues in app/
2008-03-28  Mukund Sivaraman  <muks@mukund.org>

        Fixes for some Sparse reported issues in app/

        * app/core/gimpdrawable-operation.c: Added prototype for            
        gegl_node_add_child().

        * app/core/gimpcurve.c: Remove C99 code       
                                
        * app/tools/gimpcurvestool.c 
        * app/tools/gimpperspectiveclonetool.c 
        * app/vectors/gimpstroke.c: Mark functions as static.

        * app/base/siox.c: state is a pointer.

        * app/plug-in/gimppluginprocframe.c: values is a pointer.

        * app/plug-in/plug-in-rc.c: plug_in_rc_parse() returns a pointer.

        * app/plug-in/gimpinterpreterdb.c: Check program[0] for '\0'
        instead of the pointer program itself.


svn path=/trunk/; revision=25292
2008-03-28 23:18:19 +00:00
Michael Natterer bc9424a2b5 app/actions/data-commands.c app/actions/debug-commands.c
2008-03-12  Michael Natterer  <mitch@gimp.org>

	* app/actions/data-commands.c
	* app/actions/debug-commands.c
	* app/actions/dockable-commands.c
	* app/dialogs/stroke-dialog.c
	* app/display/gimpdisplayshell-handlers.c
	* app/gui/gui-message.c
	* app/gui/gui.c
	* app/tools/gimpforegroundselectoptions.c
	* app/tools/gimpinkoptions-gui.c
	* app/widgets/gimpcolordialog.c
	* app/widgets/gimpcontainerpopup.c
	* app/widgets/gimpcontainerview-utils.c
	* app/widgets/gimpdock.c
	* app/widgets/gimpdockable.c
	* app/widgets/gimpsessioninfo-book.c
	* app/widgets/gimpsessioninfo-dock.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimpunitcombobox.c
	* app/widgets/gimpviewablebox.c
	* libgimp/gimpexport.c
	* libgimpmodule/gimpmodule.h
	* libgimpwidgets/gimpenumwidgets.c
	* libgimpwidgets/gimpframe.c
	* libgimpwidgets/gimpoldwidgets.c
	* libgimpwidgets/gimpwidgets.c
	* plug-ins/MapObject/mapobject_ui.c
	* plug-ins/common/papertile.c
	* plug-ins/common/sinus.c
	* plug-ins/flame/flame.c
	* plug-ins/helpbrowser/gimpthrobber.c
	* plug-ins/script-fu/scheme-wrapper.c
	* plug-ins/script-fu/script-fu-console.c: use accessors instead of
	accessing GtkBin.child and GtkPaned.child1,2 directly.


svn path=/trunk/; revision=25095
2008-03-12 16:58:28 +00:00
Michael Natterer 5dccee41cb Fix mishandling of the "antialias" GParamSpec. Fixes bug #521069:
2008-03-09  Michael Natterer  <mitch@gimp.org>

	Fix mishandling of the "antialias" GParamSpec. Fixes bug #521069:

	* app/tools/gimpselectionoptions.c: remove
	gimp_selection_options_reset() which used to set the default for
	"antialias" depending on the tool type (which is impossible since
	the antialias GParamSpec only exists once, and not once for each
	subclass).

	* app/tools/gimpforegroundselectoptions.c: override the antialias
	property here and default to FALSE.


svn path=/trunk/; revision=25077
2008-03-09 17:43:28 +00:00
Michael Natterer 64317165e9 app/tools/gimprectangleselecttool.[ch]
2008-03-09  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimprectangleselecttool.[ch]
	* app/tools/gimprectangleselectoptions.[ch]
	* app/tools/gimpellipseselecttool.[ch]
	* app/tools/gimp-tools.c: s/Rect/Rectangle/ and s/rect/rectangle/
	in types and function names.


svn path=/trunk/; revision=25076
2008-03-09 15:38:25 +00:00
Michael Natterer 32a1de9167 app/tools/Makefile.am app/tools/gimpiscissorsoptions.[ch] new options
2008-03-09  Michael Natterer  <mitch@gimp.org>

	* app/tools/Makefile.am
	* app/tools/gimpiscissorsoptions.[ch]
	* app/tools/gimpregionselectoptions.[ch]: new options classes.

	* app/tools/gimpselectionoptions.[ch]: remove the options here.
	Also remove some leftover rectangle options cruft that is in its
	own files since long ago.

	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimpiscissorstool.[ch]
	* app/tools/gimpregionselecttool.[ch]
	* app/widgets/gimpselectioneditor.c: changed accordingly.


svn path=/trunk/; revision=25071
2008-03-09 15:05:54 +00:00
Martin Nordholts 067e05e376 Make the GimpCoords used for snap calculations depend on the precision
2008-03-09  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c
	(gimp_rectangle_tool_setup_snap_offsets): Make the GimpCoords used
	for snap calculations depend on the precision mode of the
	rectangle. This gives a more pleasant experience when resizing and
	moving the rectangle with image zoom factor larger than 100%.

svn path=/trunk/; revision=25068
2008-03-09 10:40:42 +00:00
Sven Neumann 9026f4965f app/tools/gimpflipoptions.c app/tools/gimpmoveoptions.c
2008-03-08  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpflipoptions.c
	* app/tools/gimpmoveoptions.c
	* app/tools/gimpselectionoptions.c
	* app/tools/gimptransformoptions.c: don't add the label into the
	stock box, use an extra hbox with 2 pixels spacing.


svn path=/trunk/; revision=25064
2008-03-08 14:07:16 +00:00
Martin Nordholts e9bfe0613c Don't draw the handle for a vertex while it is being moved.
2008-03-08  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimppolygonselecttool.c: Don't draw the handle for a
	vertex while it is being moved.

svn path=/trunk/; revision=25063
2008-03-08 13:54:09 +00:00
Martin Nordholts beab79680f Added TODO on how to improve the code by changing the way the rectangle is
2008-03-08  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimprectangletool.c: Added TODO on how to improve the
	code by changing the way the rectangle is represented internally.

svn path=/trunk/; revision=25062
2008-03-08 13:14:32 +00:00
Sven Neumann 32d8cb9a4e app/actions/tools-actions.c app/actions/tools-commands.[ch] allow to
2008-03-06  Sven Neumann  <sven@gimp.org>

	* app/actions/tools-actions.c 
	* app/actions/tools-commands.[ch]
	* app/tools/gimptransformtool.c: allow to control the preview
	opacity by actions (defaults to < to > keys).

svn path=/trunk/; revision=25050
2008-03-06 17:13:59 +00:00
Sven Neumann b870738a86 app/tools/gimptransformtool.c app/tools/gimptransformoptions.[ch] take the
2008-03-06  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptransformtool.c
	* app/tools/gimptransformoptions.[ch]
	* app/display/gimpdisplayshell-preview.c: take the preview opacity
	from the transform tool options. Based on a patch from Tom Lechner.
	Closes bug #520690.

svn path=/trunk/; revision=25049
2008-03-06 11:54:44 +00:00
Sven Neumann abb3fd7b66 applied some unrelated cleanups from a patch from Tom Lechner (from bug
2008-03-05  Sven Neumann  <sven@gimp.org>

	* app/tools/gimptransformtool.[ch]: applied some unrelated
	cleanups from a patch from Tom Lechner (from bug #167926).


svn path=/trunk/; revision=25037
2008-03-05 19:56:26 +00:00
Michael Natterer f71fd9f878 changed PROJ_ROUND() macros to use RINT() so they work correctly with
2008-03-05  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell.h: changed PROJ_ROUND() macros to
	use RINT() so they work correctly with negative numbers.

	* app/tools/gimpdrawtool.c
	(gimp_draw_tool_draw_line)
	(gimp_draw_tool_draw_dashed_line)
	(gimp_draw_tool_draw_rectangle)
	(gimp_draw_tool_draw_arc)
	(gimp_draw_tool_draw_boundary): use floating-point coordinate
	transform functions again. These functions were changed to use
	integer transform functions in 2004 (!!) which broke sub-pixel
	precision drawing for stuff like straight-line and blend tool
	and also sub-pixel drawing of the brush outline.

	Should be backported to 2.4 after it has shown no ill effects in
	trunk.


svn path=/trunk/; revision=25036
2008-03-05 16:37:43 +00:00
Martin Nordholts 424eee436d Only draw the grabbed point, not all points. Drawing all points adds
2008-03-01  Martin Nordholts  <martinn@svn.gnome.org>

	* app/tools/gimppolygonselecttool.c
	(gimp_polygon_select_tool_draw): Only draw the grabbed point, not
	all points. Drawing all points adds unnecessary clutter to the
	user interface.
	(gimp_polygon_select_tool_select_closest_point): Handle drawing of
	grabbed points.

svn path=/trunk/; revision=25004
2008-03-01 12:51:23 +00:00
Michael Natterer f4378d6237 get rid of fixed-size arrays and allocate the points and curve arrays
2008-02-28  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpcurve.[ch]: get rid of fixed-size arrays and
	allocate the points and curve arrays dynamically. Added "n-points"
	and "n-samples" CONSTRUCT_ONLY properties. Renamed member "curve"
	to "samples". Lots of code changes to work with dynamic limits
	rather than 17 and 256.

	* app/core/gimpdrawable-curves.c
	* app/gegl/gimpcurvesconfig.c
	* app/tools/gimpcurvestool.c
	* app/widgets/gimpcurveview.c: changed accordingly.


svn path=/trunk/; revision=24995
2008-02-28 12:34:46 +00:00
Michael Natterer 96645da002 cursors/Makefile.am cursors/gimp-tool-cursors.xcf
2008-02-28  Michael Natterer  <mitch@gimp.org>

	* cursors/Makefile.am
	* cursors/gimp-tool-cursors.xcf
	* cursors/tool-polygon-select.png
	* cursors/xbm/tool-polygon-select.xbm
	* cursors/xbm/tool-polygon-select-mask.xbm
	* app/widgets/widgets-enums.h
	* app/widgets/gimpcursor.c: new cursor for polygon select.

	* app/tools/gimppolygonselecttool.c: use it.


svn path=/trunk/; revision=24994
2008-02-28 12:16:42 +00:00
Michael Natterer 1b11a9e838 draw handles at the corners and use the MOVE cursor modifier when we are
2008-02-26  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppolygonselecttool.c: draw handles at the corners
	and use the MOVE cursor modifier when we are moving them. Fix draw
	tool pause/resume in button_press() plus some minor cleanup.


svn path=/trunk/; revision=24985
2008-02-26 20:14:10 +00:00
Michael Natterer a384cca5f3 app/display/gimpdisplayshell-transform.[ch]
2008-02-26  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-transform.[ch]
	(gimp_display_shell_transform_points)
	* app/tools/gimpdrawtool.[ch] (gimp_draw_tool_draw_lines): take
	arrays of GimpVector2 instead of arrays of gdouble to represent
	the input points.

	* app/display/gimpdisplayshell-draw.c
	* app/tools/gimppolygonselecttool.c
	* app/tools/gimpfreeselecttool.c: don't cast the GimpVector2 arrays
	to double arrays when passing them to above functions.

	* app/tools/gimpiscissorstool.c: create a temporary GimpVector2
	array instead of a temporary gdouble array.


svn path=/trunk/; revision=24979
2008-02-26 17:30:33 +00:00
Michael Natterer a6962b5355 rename member num_points to n_points and various small cleanups all over
2008-02-26  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimppolygonselecttool.c: rename member num_points to
	n_points and various small cleanups all over the place.


svn path=/trunk/; revision=24978
2008-02-26 16:41:24 +00:00
Michael Natterer a5a12b89f6 clean up generic property handling of generated settings classes.
2008-02-18  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c (gimp_gegl_tool_config_get_property):
	clean up generic property handling of generated settings classes.


svn path=/trunk/; revision=24908
2008-02-18 15:52:01 +00:00
Michael Natterer d753ee57f5 don't create the recent settings menu if the tool did not set a config
2008-02-18  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpimagemaptool.c (gimp_image_map_tool_initialize):
	don't create the recent settings menu if the tool did not set a
	config object.

	* app/tools/gimpgegltool.[ch]: pack the operation's settings in a
	frame and add a label when there is no operation selected.


svn path=/trunk/; revision=24907
2008-02-18 15:31:23 +00:00
Michael Natterer 23456dc253 app/display/gimpdisplayshell-callbacks.c
2008-02-16  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimppolygonselecttool.c
	* app/tools/gimprectangletool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c
	* app/widgets/gimpcontainerpopup.c
	* app/widgets/gimppaletteview.c
	* libgimpwidgets/gimpcolorhexentry.c
	* libgimpwidgets/gimpnumberpairentry.c
	* plug-ins/script-fu/script-fu-console.c: Unify the handling of
	various "Enter" and "Space" keysyms all over the place. Fixes bug
	#516544 (also see gtk bug #515047).


svn path=/trunk/; revision=24894
2008-02-16 17:51:02 +00:00
Michael Natterer e831300587 port the "xpos" API to [0.0..1.0] doubles too.
2008-02-09  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpcurveview.[ch]: port the "xpos" API
	to [0.0..1.0] doubles too.

	* app/tools/gimpcurvestool.[ch]: rename "col_value" member to
	"picked_color" and use gdouble instead of gint. Also use GimpCurve
	API to map the values instead of accessing the curve directly.
	Fixes setting curve anchor points by color picking.


svn path=/trunk/; revision=24838
2008-02-09 10:56:25 +00:00
Michael Natterer 044359f93d changed all values to be [0.0..1.0] doubles instead of [0..255] integers.
2008-02-09  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpcurve.[ch]: changed all values to be [0.0..1.0]
	doubles instead of [0..255] integers. Also changed the API to use
	doubles instead of ints. Still have the fixed-size arrays though.

	(gimp_curve_map): new function to map values.

	* app/gegl/gimpoperationcurves.c: remove private map() function
	and use the one from GimpCurve.

	* app/gegl/gimpcurvesconfig.c
	* app/core/gimpdrawable-curves.c: port to the new gdouble API.

	* app/tools/gimpcurvestool.c: use gimp_curve_get_uchar() to get
	the arrays for the color bars.

	* app/widgets/gimpcurveview.[ch]: port to gdouble and some cleanup.


svn path=/trunk/; revision=24837
2008-02-09 10:01:51 +00:00
Michael Natterer fdb9060f73 app/tools/gimpgegltool.c (gimp_param_spec_duplicate) add support for
2008-02-06  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c (gimp_param_spec_duplicate)
	* app/widgets/gimppropwidgets.c (gimp_prop_table_new): add support
	for GParamSpecEnum.

	* app/core/gimpimagemap.c (gimp_image_map_apply): add even better
	checks for input and output pads of the passed operation.


svn path=/trunk/; revision=24824
2008-02-06 18:38:29 +00:00
Michael Natterer 84939f1652 app/tools/gimpgegltool.c (gimp_param_spec_duplicate) support multiline
2008-02-06  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c (gimp_param_spec_duplicate)
	* app/widgets/gimppropwidgets.c (gimp_prop_table_new): support
	multiline text and file paths. The multiline support is hacked up
	and needs some proper solution.


svn path=/trunk/; revision=24818
2008-02-06 09:09:34 +00:00
Michael Natterer 3d079cfaee don't include <gegl-plugin.h> any longer.
2008-02-05  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpgegltool.c: don't include <gegl-plugin.h> any longer.


svn path=/trunk/; revision=24816
2008-02-05 21:26:09 +00:00