Commit graph

4995 commits

Author SHA1 Message Date
Alexandre Prokoudine
4ce063cf32 app: add gegl:high-pass as Filters > Enhance > High Pass 2016-01-25 02:54:05 +03:00
Alexandre Prokoudine
50daf44ef3 app: add gegl:saturation as Colors -> Saturation 2016-01-25 02:33:53 +03:00
Michael Natterer
56e032c1eb app: remove gimp_image_map_tool_dialog_get_label_group()
The "Settings:" label should never be aligned with a label in the UI
below, because that suggests that are related. Also consistently
rename all GimpImageMapTool parameters and variables to "im_tool".
2016-01-24 22:03:58 +01:00
Michael Natterer
a4f005ba22 app: change widget grouping in the curves dialog like in levels 2016-01-24 21:41:03 +01:00
Michael Natterer
27cf1e5e6f app: finish the levels dialog widget grouping
seems I didn't consistently group things in indented GimpFrame widgets
last time I cleaned up here. Should be better now. Also change the
"Auto" button to "Auto Input Levels" to make things clearer.
2016-01-24 21:39:31 +01:00
Michael Natterer
c8ee9f951d app: fix crash in gimp_gegl_tool_get_operation()
actually chain up, instead of calling ourselves recursively...
2016-01-23 22:06:19 +01:00
Michael Natterer
bd9e59a9f0 app: add "title", "icon_name" and "help_id" to gimp_tool_gui_new()
so things are the same at the API and the inside, which makes
GimpImageMapTool's use of GimpToolGui a little more obvious.
2016-01-22 23:41:45 +01:00
Michael Natterer
8c09210d7d app: move stuff from GimpOperationTool to GimpImageMapTool
Add new string members to GimpImageMapTool and use them instead of the
resp. fields of GimpToolInfo. Change ::get_operation() to return the
operation name and a lot of strings for the UI, and create both the
GeglNode and the config object in GimpOperationTool. Lots of various
cleanups in GimpImageMapTool subclasses. This is an intermediate state
on the way of making the whole filter applying mechanism more generic
and less depending on subclasses.
2016-01-22 21:28:33 +01:00
Michael Natterer
39cc3eccd5 app: rename gimp-gegl-config-proxy.[ch] to gimp-gegl-config.[ch]
and rename its functions to make more sense.
2016-01-20 12:18:35 +01:00
Michael Natterer
06a5b2fa3f app: bring dialog titles and help IDs to GEGL filter dialogs
Add "title" and "help_id" parameters and members/properties to
GimpToolDialog, GimpToolGui, GimpOperationTool. Also make the order of
parameters more consistent.
2016-01-17 20:17:07 +01:00
Ell
350c7ca338 app: Add "Diagonal neighbors" option to the bucket fill tool
When checked, diagonally neighboring pixels are considered connected
when calculating the affected area.

This commit also adds a corresponding diagonal_neighbors parameter to
gimp_drawable_bucket_fill(), and modifies the callers, other than the
bucket fill tool, to pass FALSE for this parameter, to retain the
current behavior.
2016-01-17 00:46:54 +01:00
Ell
070007d891 app: Add "Diagonal neighbors" option to the fuzzy select tool
When checked, diagonally neighboring pixels are considered connected
when calculating the affected area.
2016-01-17 00:46:54 +01:00
Ell
93bf78b83e app: Add diagonal_neighbors parameter to...
...gimp_pickable_contiguous_region_by_seed(), in preperation
for adding a similar option to the relevant tools.

When this parameter is TRUE, all eight neighbors of each pixel
are considered when calculating the resulting region, instead
of just the four orthogonal ones.

This commit also modifies all callers to pass FALSE for this
parameter, to retain the current behavior.
2016-01-17 00:46:54 +01:00
Michael Natterer
149d3f441f app: turn the desaturate tool into a normal GEGL filter 2016-01-16 22:38:12 +01:00
Michael Natterer
6541c6b80b app: add icons to the generated gimp-gegl-config-proxy classes 2016-01-16 22:01:07 +01:00
Michael Natterer
7b009c6900 app: turn the posterize tool into an ordinary GEGL filter
which means replacing the whole thing by a few lines.
2016-01-16 21:41:00 +01:00
Michael Natterer
83fbd31f12 app: disable "Resize windows on zoom/resize" in single-window mode
They only make sense if the image is by itself in multi-window mode.
2016-01-10 20:09:28 +01:00
Michael Natterer
dd171bbf0c Bug 760175 - paintbrush size not applied in python scripts in version 2.9
Remove the code that links size, spacing etc. to brush defaults from
the GimpPaintOptions class impl and add it to gimppaintoptions-gui.c
as a callback instead.

It's not a core thing and that magic with side effects should only be
applied to the GimpPaintOptions behind the tool options GUI.
2016-01-06 01:24:56 +01:00
Michael Natterer
2a43ab240b app: don't access GimpSamplePoint members directly
Use the new accessors instead. Clean up guide and sample point code in
image crop and resize a bit.
2016-01-04 22:06:27 +01:00
Michael Natterer
37de341099 Bug 759194 - Unified Transform Tool fails when layer is hidden
For the lack of a proper transform preview, add a HACK that allows to
make the transformed layer invisible while the tool is active.
2016-01-04 19:37:14 +01:00
Daniel Sabo
ea66a7a974 app: mypaint: Include offset_by_random in the cursor calculation 2015-12-29 09:56:38 -08:00
Alexia Death
ee9e0da72d app: correct outline calculation to match mypaint and add fallback 2015-12-29 19:37:45 +02:00
Michael Natterer
e415b1cfab Bug 759939 - Ghost brush outline in FG Select tool
Undraw the outline when the pointer leaves the canvas.
2015-12-29 12:57:17 +01:00
Michael Natterer
2e40af5dcf app: remove virtual function GimpToolOptions::reset()
and use GimpConfig::reset() instead.
2015-12-29 12:47:04 +01:00
Daniel Sabo
677b1f2d82 app: mypaint: Add a toggle to change between erase & paint mode 2015-12-28 15:25:47 -08:00
Michael Natterer
8fa6e261d0 app: add a brush selector to the MyPaint brush options 2015-12-28 20:04:29 +01:00
Michael Natterer
e9a38c320d app: fix the curves tool to not warn on layers without alpha
when adding control points to all channels with control-click. It was
looking up curve points based on a -1 alpha value.
2015-12-28 02:07:20 +01:00
Michael Natterer
ab8f2c6d2b app: more s/mybrush/mypaint-brush/ in strings visible in config files 2015-12-22 19:39:11 +01:00
Michael Natterer
d01ba07ed6 configure.ac, app: make libmypaint a hard dependency
and move the MyPaint brush tool out of the playground.
2015-12-21 21:39:48 +01:00
Michael Natterer
ccd8ec5dee app: connect the MyPaint brush core with the new brush container
and remove all hackish temp code that did the same. Remove quite
some #ifdefs around code that doesn't depend on libmypaint.
2015-12-21 12:28:46 +01:00
Michael Natterer
d4aa39a7cd app, libgimpwidgets, icons: rename mypaint brush icons and help ID
from "mybrush" to "mypaint brush".
2015-12-21 00:09:55 +01:00
Michael Natterer
a5eff27149 app: add new GimpData subclass GimpMybrush and infrastructure around it
- GimpContext API and property
- a GimpDataFactory
- List and grid views with GimpDataFactoryView
- actions and a context menu

None of this is connected to the actual tool yet, or depends on
libmypaint in any way.
2015-12-20 23:51:44 +01:00
Daniel Sabo
df21e07855 app: Fix MyPaint brush rendering, implement MyPaintSurface in a native format 2015-12-15 14:48:18 -08:00
Michael Natterer
9c3944d63b Bug 759212 - Warp tool must be disabled on group layers
Disable the warp tool on invisible, locked and group layers, and show
the "forbidden" cursor.
2015-12-09 20:30:32 +01:00
Michael Natterer
0c784559c8 app: improve the layout of GimpBufferSourceBox
and add a label with the selected pickable's name.
2015-11-30 02:46:22 +01:00
Michael Natterer
baae27c786 app: note to self: don't push intermediate commits... 2015-11-29 19:56:32 +01:00
Michael Natterer
6040aa2b97 app: use GimpBufferSourceBox in GimpOperationTool
and support ops with an arbitrary number of aux inputs.
2015-11-29 19:30:58 +01:00
Michael Natterer
71e566fde7 app: add gegl:gaussian-blur-selective to Filters -> Blur 2015-11-26 11:20:44 +01:00
Thomas Manni
127b3de54a Bug 756775 - UnifiedTransformTool: nan value in handle geometry computation
Do not compute angle between 2 vectors if at least one of them is a null vector.
Return 0.0 instead.
2015-11-24 10:31:47 +01:00
Michael Natterer
96de700b43 app: add gegl:sepia to Colors -> Desaturate 2015-11-22 21:32:36 +01:00
Alexandre Prokoudine
70dd9102a0 Don't use double space in Unified Transform options 2015-11-22 17:45:25 +03:00
Michael Natterer
909ecd4e79 Bug 757905 - using select tool on image in one tab causes user to lose...
...selection on image in another tab

Fixed for rectangle select, ellipse select and crop, they now all
confirm the previous display's tool interaction instead of aborting it
when the tool is used on another display.
2015-11-20 20:51:23 +01:00
Michael Natterer
9cde7572b4 Bug 757905 - using select tool on image in one tab causes user to lose...
...selection on image in another tab

Make the free select tool behave when switching between displays.
Also clean up the code a bit and reduce utility function
fragmentation.
2015-11-20 19:17:45 +01:00
Jehan
011c6db39e app: enable GimpCurvesTool on construction.
The Curves tool is to be considered "enabled" as soon as it is selected,
not when it is initialized (usually at the first click on the image).
One of the main consequence of not being "enabled" was that the tool
cursor was wrong at selection.
2015-11-05 18:31:06 +01:00
Michael Natterer
ace40d125d Bug 735891 - color areas in the color picker info window are half transparent
Add code to GimpOverlayChild which can render arbitrary children of
the widget fully opaque, ignoring the configured opacity.

Add gimp_widget_get,set_fully_opaque() which gets/sets a per-widget
boolean flag to trigger that code.

Set the color picker's and the text tool style widget's color areas to
fully opaque.
2015-10-27 21:41:32 +01:00
Michael Natterer
ded7c8f585 app: add gimp_display_shell_scale_to_rectangle()
and move the magnify tool's rectangle zoom logic to the new function.
2015-10-18 14:59:30 +02:00
Michael Natterer
7ec04e4afe app: get rid of hardcoding GDK_SHIFT_MASK in tools/
gimp_suggest_modifiers(): change "shift_format" and "control_format"
parameters to "extend_selection_format" and "toggle_behavior_format",
which fixes the longstanding problem that the function did the right
thing only by accident.

tools: use gimp_get_extend_selection_mask() instead of GDK_SHIFT_MASK
which is not 100% semantically correct in all cases, but at least a
step in the right direction to make the tool modifiers easier to
improve.
2015-10-17 15:31:08 +02:00
Jonathan Tait
7167586919 Bug 754998 - Warp Transform Tool > Animation> Frames...
...spinbox does not step/page correctly

Correct the increments to be integers not floats.
2015-09-28 20:22:57 +02:00
Michael Natterer
29fee56914 app: fix visibility of the color picker tools info window
Since commit 867b1f7e the window did always pop if it was set to
visible once, even if closed and "Use info window" disabled.

Fix this by adapting the show logic to the fact that we now keep the
widget alive across images/displays.
2015-09-20 00:37:05 +02:00
Michael Natterer
867b1f7efa Bug 754713 - On-canvas dialog of color picker tool always displays...
...in initially active tab

We intend reuse the dialog across displays, so don't destroy the
dialog in GIMP_TOOL_CONTROL_HALT, only hide it. This way the dialog
keeps its detached state.
2015-09-09 01:24:19 +02:00
Michael Natterer
22fc50c279 app: rename all values of enum GimpContextPropMask
from GIMP_CONTEXT_FOO_MASK to GIMP_CONTEXT_PROP_MASK_FOO.
Also rename the FIRST and LAST values of enum GimpContextPropType.
2015-09-08 21:18:49 +02:00
Michael Natterer
3f02b2aaf2 app: add gegl:maze to Filters -> Render -> Pattern 2015-09-03 22:12:23 +02:00
Michael Natterer
ebcd7cacbb app: redo widget grouping in the levels dialog, still far from good
but a bit more logical. This totally needs to change again.
2015-09-01 22:33:42 +02:00
Michael Henning
0ff7ab3712 app: Fix typo
Pointed out by prokoudine on irc after it was introduced in e2bdfd41
2015-08-31 20:24:50 -04:00
Michael Natterer
e2bdfd41e2 Bug 750954 - Make tips of the "Black point" and "White point" buttons...
...in the Levels dialog explain the difference between them

Improve the tooltips of the pick buttons to say

"Pick FOO point for {all channels|the selected channel}"
2015-08-31 00:09:22 +02:00
Michael Natterer
3ca15939ff app: fix signature of gimp_curves_tool_color_picked()
which I forgot in yesterday's color picking refactoring.
2015-08-25 23:51:33 +02:00
Michael Natterer
8c80ee14ff Bug 748749 - picked colors don't match image colors...
...when a color profile is active

This commit doesn't fix anything, but it prepares the code to do the
right thing:

It passes the actual raw image pixels through the entire color picking
mechanism to the widgets which display colors, particularly
GimpColorFrame.

This is needed for GimpColorFrame's "Pixel" mode (as opposed to its
RGB, HSV etc. modes) which is supposed to show the raw pixel values
from the image.

Before this commit, it was recreating the raw pixel values from the
GimpRGB value it knows, which will become impossible when we correctly
pick color managed GimpRGB values soon.
2015-08-25 00:05:59 +02:00
João S. O. Bueno
4f78fdd31c Fixes parent_instence typo 2015-07-25 03:26:56 -03:00
Jehan
43e4256d56 "gegl:seamless-clone" operation's properties "max-refine-steps" changed…
… into "max-refine-scale". See GEGL commit 346139b.
It does not fix the Seamless Clone tool, but at least now the slider
has a meaning.
2015-07-12 19:47:49 +02:00
Michael Natterer
d6c578c567 app: change gimp_image_crop() to use x, y, width, height 2015-07-03 19:38:08 +02:00
Michael Natterer
4c2edf1841 app: use gimp_image_item_list_bounds() in GimpEditSelectionTool
the code was duplicated 4 times. Also merge the layer and vectors
cases for finding bounding boxes into one, they are the same now.
2015-07-03 19:38:08 +02:00
Michael Natterer
e90e90265b app: port everything from gimp_channel_bounds() to gimp_item_bounds()
except gimpchannel.c itself.
2015-07-03 19:38:08 +02:00
Michael Natterer
7e90a3e4e5 app: use gimp_item_bounds() instead of gimp_vectors_bounds() 2015-07-03 19:38:06 +02:00
Michael Natterer
bc525f39ee app: factor out a function in GimpEditSelectionTool, and move one around 2015-07-03 19:38:06 +02:00
Michael Natterer
7d220a56e0 app: free GimpEditSelectionTool's stuff in finalize() 2015-07-03 12:27:08 +02:00
Michael Natterer
3d7af8a184 app: remove the "exclude" paameter from gimp_image_item_list_get_list()
and from gimp_image_item_list_filter(). After the fixes for bug 735906
it's no longer needed, and it was harmful.
2015-06-28 23:49:47 +02:00
Michael Natterer
358f13f5b8 Bug 735906 - Transform tools give unexpected results when transforming...
...certain sets of linked layers

Fix the move tool (GimpEditSelectionTool) using the same principle
as the other "linked item" features, just a bit more complicated...

Never translate the active item and its linked items separately,
always translate the entire list at once.

The linked logic was distributed across the entire file. Changed the
code to prepare lists of items that are translated live (layers and
vectors), and items that are translated at the end (channels, masks
and the selection). In the motion and button release functions, simply
use the prepared lists without any further duplicated checking.

Also clean up the stuff a bit, there is more cleanup needed but first
the fix...
2015-06-27 12:34:19 +02:00
Michael Natterer
3c706d00c6 Bug 735906 - Transform tools give unexpected results when transforming...
...certain sets of linked layers

Fix for translating layers from the PDB, and with the cursor keys
for gimpeditselectiontool. Moving layers with the mouse is still broken.

The approach is exactly the same as in 25a696c7.
2015-06-26 12:00:45 +02:00
Michael Natterer
25a696c7f8 Bug 735906 - Transform tools give unexpected results when transforming...
...certain sets of linked layers

Fix this bug for flip, rotate and general transforms (not for move yet):

gimp_item_linked_flip,rotate,transform(): always transform the passed
item too (do not filter it out of the list of items), so these functions
do the entire job of transforming a linked group now. Transforming the
active item separately didn't work (and is not implementable) if both
a layer and its parent layer group were linked.

flip tool, transform tool, layer->transform callbacks: don't call
gimp_item_foo() *and* (if the item is linked) gimp_item_linked_foo().
Instead call gimp_item_linked_foo() if the item is linked, and
gimp_item_foo() otherwise.

This commit also kills the mis-feature of transforming the selected
pixels of the active layer, and then the linked items completely. We
now either only transform the selected area *or* the linked group.
2015-06-25 12:25:41 +02:00
Michael Natterer
e58bf5138f Bug 751333 - Crash when moving cursor with ibus "Hangul" input method
Had a closer look at GtkTextView again and implemented the IM
callbacks like there. I don't know if this fixes the bug, please test.
2015-06-22 22:54:16 +02:00
Michael Natterer
6d6efbbf8b app: remove "remove_children" parameter from gimp_image_item_list_filter()
It was always TRUE. The function should be renamed now, but not until
the merging of linked item fixes to 2-8 is done.
2015-06-20 21:59:37 +02:00
Michael Natterer
64b24d169d app: remove "remove_locked" parameter from gimp_image_item_list_filter()
This is just removal of unused code before fixing bug 735906.
2015-06-20 16:03:40 +02:00
Michael Natterer
014cd08c5c Bug 750953 - The Curves dialog should present per channel lines...
...when opened by the "Edit these settings as Curves" button on the
Levels dialog

The code to configure the entire GUI correctly was not even called
when initially creating the curves dialog (the color bars probably
looked right just because of default values of their own).

Factor out gimp_curves_tool_update_channel() which properly updates
the GUI. Call it after the dialog has been created, and when the
active channel changes.
2015-06-15 00:11:13 +02:00
Michael Natterer
6487d0a26a app: move the seamless clone tool to the playground
It's not release material unless somebody comes and fixes its bugs,
and its speed.
2015-06-14 13:02:31 +02:00
Thomas Manni
22dbdbe1fb app, menus: add gegl:displace to Filters -> Map 2015-06-10 19:43:34 +02:00
Øyvind Kolås
7e6320497e follow gegl api changes from commit af5361ca8d, with an abyss policy argument
to gegl_buffer_copy.
2015-05-25 01:27:31 +02:00
Alexandre Prokoudine
1ac8f750ff Improve Foreground Select tooltips 2015-05-07 15:42:00 +03:00
Mikael Magnusson
9b30b1d744 gimptransformoptions: Mark strings for translation 2015-05-03 01:24:55 +02:00
Ville Pätsi
c4cd3c6562 app/tools/gimpgegltool.c: blacklist lcms-from-profile 2015-05-02 10:15:41 -04:00
Ville Pätsi
d6f916a3c2 app/tools/gimpgegltool.c: blacklist linear-gradient and radial-gradient 2015-05-02 00:23:42 -04:00
Michael Natterer
93414342c3 Bug 748762 - GIMP crashes when a selection is outside a layer boundary...
...and % is selected in rotate Tool

Refuse to start any transform tool (with an error message) if the
selection doesn't intersect with the layer.
2015-05-02 00:00:39 -04:00
Michael Natterer
a110639233 app, menus: add gegl:tile-paper to Filters -> Map 2015-04-30 11:59:49 -04:00
Michael Natterer
9d510d8fff app: make the MyPaint brush path configurable in Prefs -> Folders
Keep the config values around even if compiled without MyPaint brush
support, so we remember the values between sessions of differently
compiled GIMP versions.
2015-04-25 21:14:22 -04:00
Michael Natterer
fcf7a0f9f5 app: port MyPaint brush loading to GFileEnumerator 2015-04-22 11:31:31 +02:00
Michael Natterer
109d568b46 app: remove GimpOperationTool's "config" member
The same object is kept around by the GimpImageMapTool parent class.
2015-04-10 14:10:19 +02:00
Michael Natterer
8a95f32473 app: hide the region combo for operations which do not depend on the region
This fixes commit 62cbd3eac3.
2015-04-10 13:20:26 +02:00
Michael Natterer
81cf8aa601 app: improve usability of the handle transform tool
Reorganize tool modes to be { ADD_TRANSFORM, MOVE, REMOVE }, where
ADD_TRANSFORM is the default and allows to add handles *and* transform
the image in one click-drag. MOVE moves handles without transforming
(shift) and REMOVE removes handles (control). Also improve cursors to
accurately show the result of a click.
2015-04-02 23:31:41 +02:00
Michael Natterer
aa3cb40600 app: fix warnings in GimpTileHandlerIscissors 2015-03-30 22:51:13 +02:00
Jehan
5217900748 configure/app: libmypaint becomes an optional dependency. 2015-03-30 22:38:35 +02:00
Jehan
5460c414db app: move the MyPaint brush into the playground. 2015-03-30 22:38:35 +02:00
Michael Natterer
2594c09e41 app: make the mypaint tool brush outline size follow the settings instantly 2015-03-30 22:38:35 +02:00
Michael Natterer
6ea9b5c3cf app: connect the MyPaint brush radius to the tool tip size action 2015-03-30 22:38:35 +02:00
Michael Natterer
5ccea24952 app: let gimppaintoptions-gui.c know about the MyPaint brush tool
and disable stuff accordingly.
2015-03-30 22:38:35 +02:00
Michael Natterer
628593ae5a app: port the MyPaint brush to GimpPaintTool::get_outline() 2015-03-30 22:38:35 +02:00
Michael Natterer
dd767bca37 app: use gimp_paint_tool_set_draw_circle() in the MyPaint brush tool 2015-03-30 22:38:34 +02:00
Michael Natterer
071ede915a app: first draft of GimpMybrushTool, which uses MyPaint brushes 2015-03-30 22:38:34 +02:00
Michael Natterer
974ce0b6d1 app: GimpHandleTransformTool: remove shortcuts in is_handle_position_valid()
The check should not depend on trans_info[NUM] because the code that
has the division by zero to avoid doesn't either. Closes bug #721009.
2015-03-30 00:12:16 +02:00
Michael Natterer
a5edc76c76 app: Iscissors: actually set the state to REMOVE so the right cursor appears 2015-03-28 22:46:49 +01:00
Michael Natterer
f2c4b9317f app: Iscissors: allow to remove points with Control-Click 2015-03-28 22:41:43 +01:00
Michael Natterer
bd75ed6bf0 app: Iscissors: don't crash when cancelling the initial point 2015-03-28 21:52:26 +01:00
Michael Natterer
4842e2a14f Bug 670031 - Would like to undo intelligent scissors selections in progress
Add undo to the Isissors tool, along with some refactoring:

- Always modify the actual curve, instead of a set of obscure states
  kept around in the tool instance
- On cancel, simply go back to the curve on the undo stack
- Draw handles on top of curve segments
- Draw the currently edited segments and handles in the highlight color
2015-03-28 21:31:03 +01:00
Michael Natterer
565b0af74d app: IScissors: add struct ICurve for the entire curve and its state 2015-03-27 21:37:57 +01:00
Michael Natterer
e6fe3ed3b0 app: Iscissors: rename struct ICurve to ISegment 2015-03-27 10:45:28 +01:00
Michael Natterer
36ca4d03f1 app: some cleanup in GimpTransformTool and subclasses
- formatting
- rename some GimpTransformTool members
- add member "does_persoective" and don't include subclasses
- handle drawing cleanup
2015-03-23 23:18:28 +01:00
Michael Natterer
94a872f051 app: some cleanup in the Iscissors tool
Create utility functions to create and free ICurve segments, improves
readability. And some random code cleanup.
2015-03-20 21:18:23 +01:00
Michael Natterer
d11f83a640 app: resurrect the Iscissors tool to a zombie state
The interaction is fully restored, it's also ported to the new halt()
and commit() API of tools and semi-properly GEGLized: the gradient map
is now constructed on the fly using a GimpTileHandlerValidate
subclass.

The only problem is that it doesn't find any edges in the image and is
totally useless. Pushing anyway to put an end to the bitrot, any help
with debugging is greatly appreciated...
2015-03-17 22:24:56 +01:00
Michael Natterer
4dcd48fff2 app: move the handle transform tool to the playground 2015-03-08 17:21:11 +01:00
Michael Natterer
8f4fe89309 app: some more cleanup in the handle transform tool 2015-03-08 17:12:13 +01:00
Johannes Matschke
2989bad35a Bug 721009 - new transform tool with freely placeable handles
Add new tool GimpHandleTransformTool which allows to freely place up
to 4 handles on the image, then move any one of them, which transforms
the image so that the remaining handles keep their position.

Did quite some cleanup on the code before pushing --Mitch
2015-03-05 12:36:59 +01:00
Michael Natterer
67673e0b09 app: oops, fix last commit 2015-03-05 10:28:50 +01:00
Michael Natterer
8236068982 app: add struct GimpTransformOptionsClass
instead of simply typedefing it to the parent class struct.
2015-03-05 09:57:23 +01:00
Michael Natterer
e44e738267 app: add gegl:edge to Filters -> Edge-Detect 2015-03-03 22:55:39 +01:00
Michael Natterer
b27c5b0985 app: move the N-Point Deformation tool to the playground
It has to be enabled via Prefs -> Playground. The menu entry is always
disabled until it leaves the playground, for reasons worth fixing.
2015-03-03 20:26:58 +01:00
Michael Natterer
825d4ab185 app: make sure there is always a tool selected on startup
"No tool on startup" can happen if a tool has disappeared between
sessions, or by broken manual config file editing.
2015-03-03 20:24:40 +01:00
Michael Natterer
3f523dc88b app: some cosmetic cleanup in the cage tool 2015-03-02 01:02:06 +01:00
Michael Natterer
c194c5d8c2 app: simplify npd tool motion event handling
by getting rid of the complicated "previous selected points" handling
and simply keeping around the last motion event's coords for
calculating the deltas to move the selected points.
2015-03-01 23:57:10 +01:00
Michael Natterer
06797982ba app: fix crash and cleanup in gimp_n_point_deformation_tool_key_press() 2015-03-01 20:30:17 +01:00
Michael Natterer
87ee494f79 app: npd: no CAPS in property and member names
This commit should also fix setting the tool's options on the GEGL op;
and it gets rid of one more member of the npd options.
2015-03-01 18:21:17 +01:00
Michael Natterer
c3b6b3273c app: lots of cleanup in the N-Point Deformation tool
- Formatting and indentation
- Handle GIMP_TOOL_ACTION_COMMIT
- Fix calls to gimp_tool_control_activate()/halt()
- Move variables to local scopes
- Remove and reorder includes
- Remove redundant members from the tool struct
- Set members to NULL after freeing them
- And whatnot...
2015-03-01 16:49:22 +01:00
Marek Dvoroznak
8a56234c9a app: npd-tool: let GEGL NPD operation destroy the model 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
415d7f2781 app: npd-tool: remove option to pause the deformation process 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
129c826d49 app: npd-tool: draw lattice using GimpDrawTool's functions 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
f80b126563 app: npd-tool: fix tool's options 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
ffc6024ee4 app: npd-tool: show only a preview (hide the image) when the deformation is in progress
and show the image again when the deformation is done
2015-02-27 20:21:52 +01:00
Marek Dvoroznak
10255eddbb app: npd-tool: add option to apply or cancel the deformation 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
c4e12fdd7c app: npd-tool: use canvas buffer preview 2015-02-27 20:21:52 +01:00
Marek Dvoroznak
c1f8784ae3 app: npd-tool: deal with drawable's offset 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
b6b1d3c27a app: npd-tool: add option to pause/unpause deformation process 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
8fcf1e0015 app: npd-tool: update tool's start function 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
4af9bd5981 app: npd-tool: deformation runs in its own thread 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
2654fadc6c app: npd-tool: scale radius of a control point according to display shell's scale 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
ccc83296e7 app: npd-tool: start and stop the tool more correctly
Don't add a control point after the first click on the drawable,
just start the tool. Don't stop the tool if it hasn't been started.
2015-02-27 20:21:51 +01:00
Marek Dvoroznak
a90159a3ef app: npd-tool: remove control points using proper keys
BACKSPACE removes last added control point, DELETE removes selected control points.
2015-02-27 20:21:51 +01:00
Marek Dvoroznak
ffecedf223 app: npd-tool: add option to remove selected control points 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
80adf02de8 app: npd-tool: add rubber band selection 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
6ea27ea690 app: npd-tool: add option to show mesh 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
b1059d9461 app: npd-tool: add provisional tool's options 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
b4ae7c7f61 app: npd-tool: display cursor and cursor modifiers 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
fe193f5d57 app: npd-tool: move (multi)selected control points 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
433194ee20 app: npd-tool: remove last added control point using backspace 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
1a0c8d5cb2 NPD tool uses GEGL NPD operation 2015-02-27 20:21:51 +01:00
Marek Dvoroznak
f15a7bc71d app: add NPD tool basics 2015-02-27 20:21:51 +01:00
Michael Natterer
a71d64f701 app: add gegl:value-propagate to Filters -> Distorts 2015-02-06 19:26:52 +01:00
Alexandre Prokoudine
931f4581b7 app: add gegl:diffraction-patterns Filters -> Render -> Pattern 2015-01-21 00:47:11 +03:00
Alexandre Prokoudine
fdaed22911 app: add gegl:color-enhance to Color -> Auto 2015-01-13 22:40:13 +03:00
Alexia Death
b0dbb2edf2 Bug 741200 - paint options spacing differs from brush spacing
Add "link" buttons to the tool options that are duplicates of brush
properties, so the tool options values can be set to change along with
the current brush.
2015-01-11 23:20:31 +01:00
Kristian Rietveld
cea42c73d8 app: fix implicit enum casting
Silences clang.
2015-01-10 00:02:28 +01:00
Alexandre Prokoudine
27ec429b43 app: add gegl:lens-flare to Filters -> Light and Shadow 2014-12-31 13:12:53 +03:00
Michael Natterer
be5e2e6991 app: add gegl:engrave to Filters -> Distorts 2014-12-15 23:42:57 +01:00
Massimo Valentini
af64a104c3 Bug 741352: Cage tool crashes pressing Enter after Esc 2014-12-11 18:37:49 +01:00
Thomas Manni
960f54360f gimpoperationtool: add support for aux2 input buffer 2014-12-11 08:28:14 +01:00
Michael Natterer
41e61719c4 app: add gegl:illusion to Filters -> Map 2014-12-04 20:30:57 +01:00
Michael Natterer
3a6962e0bd app: some cosmetic code cleanup in the color picker tools 2014-12-01 13:49:40 +01:00
Michael Natterer
293e5bde9e Bug 740059 - Text tool changes from "Dynamic" to "Fixed"...
after text box moved using Alt key

In gimp_text_tool_button_release(), handle the "moving" case
separately instead of running into the default else branch that
assumes the user clicked outside and made a new text layer.
2014-11-28 23:57:06 +01:00
Michael Natterer
bebdcbe0bf app: change enum GimpColorPickState to { START, UPDATE, END }
It used to be { NEW, UPDATE } but that didn't allow to distinguish the
final END update, which we will soon need for automatic color history
updating. Make sure all places that handle motion events on colors
(pick from canvas, gradient editor) correctly send and handle END
events.
2014-11-28 12:00:53 +01:00
Thomas Manni
d36b18d7dc fix typo on commit 5ae6c8b1b3 2014-11-27 15:44:58 +01:00
Thomas Manni
5ae6c8b1b3 Bug 740778 - fix transformtools
Do not enable transform tools in selection mode when no selection exists.
2014-11-27 08:30:56 +01:00
Michael Natterer
01c79a2661 app: add gegl:noise-solid to Filters -> Render -> Noise 2014-11-22 20:45:40 +01:00
Michael Natterer
3a5eaeb3af app: add gegl:sinus to Filters -> Render -> Pattern 2014-11-21 20:49:15 +01:00
Michael Natterer
36d8431058 icons: add icons for seamless clone contributed by Klaus Staedtler 2014-11-19 21:32:36 +01:00
Michael Natterer
ecaf485f85 app: draw the paint tool fallback crosshair only as last resort
if there was no outline drawn, no line preview, no circle, and no
cursor is shown. All these cases, if drawn, never need a crosshair.
2014-11-19 19:55:22 +01:00
Alexia Death
59364ea76d app: separate fallback cursor from primary indicator cursor
Separate fallback use of a cursor from using a plain size
indicator cursor. Ink tool uses a plain circle as primary
drawing indicator instead of outline, totally different
use than a fallback, when brush is too small to be drawn.

Conflicts:
	app/tools/gimppainttool.c
2014-11-19 00:41:43 +02:00
Michael Natterer
c17e8b0412 app: add crosshair drawing to GimpCanvasAnchor and use it in GimpPaintTool
instead of drawing the crosshair cursor manually.
2014-11-18 23:06:43 +01:00
Alexia Death
5442421a34 app: crosshairs type fallback brush cursor
Replaces circular fallback cursor with a less distracting
crosshairs type cursor.
2014-11-18 21:18:29 +02:00
Michael Natterer
6c590ac083 app: add gegl:supernova to Filters -> Lights & Shadows 2014-11-18 20:01:09 +01:00
Michael Natterer
a101ed2aef app, pdb: change range of brush-spacing to 0.01..5.0
And only use percent in the GUI.
2014-11-17 23:56:16 +01:00
Michael Natterer
548df1fa32 app: change brush-hardness and brush-force range to [0.0..1.0]
and set a factor of 100 on the GUI.
2014-11-17 23:17:13 +01:00
Michael Natterer
c9e75b1fa0 app: some cleanup in the new paint options code 2014-11-17 21:45:01 +01:00
Alexia Death
32e545277b app: fixes for force and hardness 2014-11-17 15:24:59 +02:00
Alexia Death
4421070a6a app: add explicit paint options sliders for hardness and force 2014-11-17 13:13:18 +02:00
Alexia Death
9a953a9239 app: locking brush size to zoom 2014-11-17 00:03:10 +02:00
Michael Natterer
0aaee2a0e0 app: coding style and tooltip fixes 2014-11-15 22:23:14 +01:00
Alexia Death
0ac4dc5ac1 app: ajust paint options gui refactoring 2014-11-15 11:24:13 +02:00
Alexia Death
d205ca2b50 app: refactor paint options spinscale creation into helper function 2014-11-14 23:37:05 +02:00
Michael Natterer
9f492273cb Revert "app: reorder spacing after size in the new spacing override code/ui"
This reverts commit 492e1ab560,
but keeps the code cleanups, and adds some more.
2014-11-13 00:37:19 +01:00
Michael Natterer
492e1ab560 app: reorder spacing after size in the new spacing override code/ui 2014-11-12 23:55:46 +01:00
Alexia Death
0c6848e79e app: make spacing override part of paint options 2014-11-13 00:08:40 +02:00
Michael Natterer
a8853801a0 app: add gegl:video-degradation to Filters -> Distorts 2014-11-12 22:20:11 +01:00
Michael Natterer
488998031e app: add gegl:color-exchange to Colors -> Map 2014-11-10 22:23:54 +01:00
Michael Natterer
dfcbc23cac app: implement creating an animation from a warp tool transform
like in the iwarp plug-in. I consider the plug-in obsolete now.
2014-11-08 00:47:39 +01:00
Michael Henning
8f20b09ecf app: Animate blend tool handles appearing/disappearing 2014-10-18 21:07:18 -04:00
Michael Henning
c298485ba4 Revert "app: Refactor GimpBlendTool to not use update methods."
This reverts commit 8a2a9775b9.

Conflicts:
	app/tools/gimpblendtool.c
2014-10-18 19:05:56 -04:00
Michael Natterer
13a626a304 app: add gegl:oilify to Filters -> Artistic 2014-10-11 20:32:31 +02:00
Michael Natterer
849481a861 Clean up code around calls to g_file_replace()
- use G_FILE_CREATE_NONE instead of 0
- don't put "Could not open <file> for writing: <error>" around the
  returned error, the returned message is already verbose
2014-10-04 02:44:54 +02:00
Michael Natterer
7ee69c3053 Bug 737583 - Fix static placement of Chinese IME window
Call gtk_im_context_set_cursor_location() whenever we draw the text
tool cursor or start a preedit sequence.
2014-10-03 00:04:24 +02:00
Jehan
56c2e19733 Removes various easy compilation warnings. 2014-09-28 18:18:00 +02:00
Michael Natterer
90c967a39f Bug 737008 - Curve color always black
Don't hardcode "black" for the "Value" curve in GimpCurvesTool.
Instead, pass a NULL color to GimpCurveView, which is then interpreted
as the theme's text color (the curve's background is the theme's text
background color). We still hardcode pure red, green and blue for the
other curves.
2014-09-21 12:32:23 +02:00
Michael Henning
8a2a9775b9 app: Refactor GimpBlendTool to not use update methods.
Simply call draw_tool_pause/resume instead.
2014-09-08 17:08:36 -04:00
Michael Henning
36d719c986 app: In GimpBlendTool, don't start the draw tool too early.
Also simplify some related logic and rename related functions to
be clearer.
2014-09-02 18:57:14 -04:00
Michael Natterer
bda1cd049d Bug 735516 - Crop to content fails
Return a new enum GimpAutoShrink { SHRINK, EMPTY, UNSHRINKABLE } from
gimp_pickable_auto_shrink() because a simply boolean FALSE doesn't
distinguish between "not further shrinkable" and "no content". Change
the callers accordingly add a special "already cropped" message where
we only had a "no content" message before.
2014-08-31 17:41:54 +02:00
Michael Natterer
f38d3a1672 app: don't try to draw a NULL boundary in gimp_region_select_tool_draw() 2014-08-27 21:10:55 +02:00
Mikael Magnusson
45a9519cec app: Don't do integer division before saving to gdouble, remove stray ; 2014-08-16 02:38:55 +02:00
Simon Budig
40c06ab685 fix some copy&paste errors
Spotted by Andrey Karpov using static code analysis:
   http://www.viva64.com/en/b/0273/
2014-08-16 00:37:13 +02:00
Michael Henning
59dfa2e6e6 app: If the user makes a new gradient, commit the old one 2014-08-04 17:20:58 -04:00
Michael Henning
41e2a01976 app: Tweak the blend tool UI for shapebursts 2014-08-04 12:32:45 -04:00
Michael Natterer
50568ae258 app: add gegl:distance-transform to Filters->Generic as "Distance Map" 2014-08-03 21:34:32 +02:00
Michael Natterer
b200345a98 app: change GimpImageMapTool::get_settings_ui()'s "default_folder" to GFile 2014-07-29 11:56:49 +02:00
Michael Natterer
9a90bfa26a app: more gimp_directory() -> gimp_directory_file() 2014-07-29 11:56:49 +02:00
Michael Natterer
b03d69dd40 libgimpbase, app: add variants of gimp_$foo_directory() which return GFiles
gimp_directory_file(), gimp_data_directory_file() etc. The new
functions take a variable list of path elements to the file,
the list has to be NULL-terminated. Remove the newly added
gimp_personal_rc_gfile(). Start using the new functions in app/.
2014-07-28 02:04:01 +02:00
Michael Henning
f7986e391e app: In GimpBlendTool, fix the preview for layers with offsets. 2014-07-22 17:39:58 -04:00
Michael Henning
a1a5bba022 app: Fix the order of arguments to gimp_progress_start
See a6601d563b
2014-07-22 13:33:18 -04:00
Michael Henning
c531c087ac app: Redo the handles in GimpBlendTool 2014-07-22 13:13:47 -04:00
Michael Henning
8fef1918a9 app: Support gradients with fg/bg segments in the blend tool preview. 2014-07-22 13:13:47 -04:00
Michael Henning
0388d41528 app: Update the gradient tool preview when the gradient is modified. 2014-07-22 13:13:47 -04:00
Michael Henning
350863ce9a app: When constraining angles, don't allow points to get out of line. 2014-07-22 13:13:47 -04:00
Michael Henning
3b2430af1d app: Sync opacity and paint-mode properties with blend_tool->image_map 2014-07-22 13:13:47 -04:00
Michael Henning
d7dbee7113 app: In GimpBlendTool, sync the operation properties with GimpBlendOptions 2014-07-22 13:13:47 -04:00
Michael Henning
54b3f02baf app: Add a basic live preview to GimpBlendTool using GimpImageMap 2014-07-22 13:13:47 -04:00
Michael Henning
31dfc44313 app: Prevent grabbing handles after halting in the blend tool. 2014-07-22 13:13:47 -04:00
Michael Henning
bd8ef51eee app: Remove last_{x,y} from struct _GimpBlendTool
and use local variables instead.
2014-07-22 13:13:46 -04:00
Michael Henning
12d60dc3e0 app: Add UI for adjusting the gradient points in GimpBlendTool 2014-07-22 13:13:46 -04:00
Michael Natterer
328e4eff18 app: add gimp_progress_set_text_literal()
and use it instead of set_text (progress, "%s", literal_message);
2014-07-20 23:32:19 +02:00
Michael Natterer
a6601d563b app: some GimpProgress cleanup
- change start() and set_text() to use "format" and "..." instead of
  "message", allowing to format progress messages in place
- s/cancelable/cancellable/
- move "cancellable" to be the second argument of start()
2014-07-12 23:45:20 +02:00
Michael Natterer
ad9fd33915 app: guide cleanup
- Move all GimpGuide members to a private struct
- Remove cruft checks for position < 0, we don't keep removed guides
  around in the image's guide list since a long time ago
- Add #define GIMP_GUIDE_POSITION_UNDEFINED G_MININT and use that
  instead of -1 (this is also a prerequisite for having guides
  outside of the image)
2014-07-10 00:20:57 +02:00
Michael Natterer
29427fa4f1 app: port GimpImageMapTool settings import/export to streams
Simplifies and centralizes error checking and reporting.
2014-07-04 18:31:00 +02:00
Michael Natterer
b4cdecb4c3 app: port the curves and levels cruft format loaders to GIO 2014-07-04 13:18:01 +02:00
Michael Natterer
4e6a6079f4 app: port levels cruft format saving to GIO 2014-07-02 23:45:16 +02:00
Michael Natterer
87ecc83885 app: port curves cruft format saving to GIO 2014-07-02 23:40:26 +02:00
Michael Natterer
98e7ec090b app: use the new gimp_personal_rc_gfile() in lots of places
and pass the GFile to the newly added GFile-based GimpConfig,
GimpScanner etc. functions. This is starting to make sense now...
2014-07-01 20:02:45 +02:00
Michael Natterer
a31cb02405 app: return a GFile from gimp_tool_info_build_options_filename()
and rename it to gimp_tool_info_get_options_file().
2014-07-01 15:41:12 +02:00
Michael Natterer
8c8135a881 app: port GimpImageMapTool's settings API from filename to GFile 2014-07-01 15:13:02 +02:00
Michael Natterer
6fb9d1a3b0 app: cancel the tool progress if the progress title was clicked 2014-06-30 03:41:46 +02:00
Michael Natterer
f4803af808 app: add boolean "cancelable" API to GimpImageMap and gimpdrawable-filter.[ch]
Return booleans indicating success (FALSE == user has canceled), and
allow canceling only in GimpImageMapTool for now.
2014-06-30 01:06:04 +02:00
Michael Natterer
9ec2a3cdeb app: implement progress canceling in GimpTool
In gimp_tool_progress_start(), if the progress is cancelable, grab on
an invisible widget and emit the progress' "cancel" signal when Escape
is pressed.
2014-06-30 00:02:33 +02:00
Michael Natterer
5c7e2f5c95 app: add gegl:mirrors to Filters -> Distorts as "Kaleidoscope" 2014-06-27 12:02:16 +02:00
Michael Natterer
88762df4cf app: more debug output in GimpWarpTool, for fixing the timeout mess... 2014-06-26 14:01:35 +02:00
Michael Natterer
6eba4c716b app: cleanup in GimpImageMap
- don't allow to create a GimpImageMap of an operation without output
- make "region", "mode" and "gamma-hack" settable on a map that
  already has a graph
- don't insert a useless "over" if the operation is a source op
- do the gamma-hack always on formats with alpha, so we don't lose
  intermediate alpha results on source ops
- simplify graph connection a lot
- in GimpImageMap tool, don't recreate the map when reconfiguring
  "region" and "gamma-hack"
2014-06-25 18:16:52 +02:00
Michael Natterer
a665c30823 app: gimp_spin_button_new() -> gtk_spin_button_new() 2014-06-21 22:39:37 +02:00
Michael Natterer
99efd9c1a5 app: make sure the warp tool's canvas circle updates when its size changes
and make the undo functions static, no idea why they were not.
2014-06-20 01:14:53 +02:00
Michael Natterer
374fd6cfd6 app: fix some blacklisting typos in GimpGeglTool 2014-06-20 01:14:21 +02:00
Michael Natterer
604c14a08c app: allow the fuzzy and by-color select tools to show the mask directly
instead of the outline. This is experimental, please comment. The
color is currently hardcoded to magenta.
2014-06-11 22:15:00 +02:00
Michael Natterer
21a8f9c96b app: add boolean "mask_inverted" to GimpDisplayShell
and to gimp_display_shell_set_mask(). It allows to choose whether the
mask is drawn inverted, instead of always drawing it inverted.
2014-06-11 21:33:57 +02:00
Michael Natterer
6857d0141d Revert "app: put #include "gegl-plugin.h" back in two places, but with a FIXME"
This reverts commit 5c1d0e8dc2.

gegl_operation_get_key() is now included via gegl.h as it should.
2014-06-10 23:04:32 +02:00
Michael Natterer
5c1d0e8dc2 app: put #include "gegl-plugin.h" back in two places, but with a FIXME 2014-06-10 10:04:22 +02:00
Michael Natterer
8aa0019c2e app: clean up inclusion of gegl-plugin.h, mostly removals 2014-06-10 03:13:09 +02:00
Michael Natterer
7496a0471b app: GimpGeglTool: show the operations' title, if they have one 2014-06-10 03:11:54 +02:00
Michael Natterer
cd479ce04e app: add an "auto overlay" API to GimpToolGui
which makes tool dialogs auto-overlay if the canvas is large
enough. Set all tools dialogs except GimpImageMapTool's dialog to
auto.
2014-06-09 03:08:43 +02:00
Michael Natterer
e2628b9bd0 app: revive gimpdrawable-foreground-extract
Move the extraction graph from the foreground select tool there.
Enable the PDB wrapper again, using default values for now.
Some sytle cleanup in the foreground select tool.
2014-06-03 23:05:23 +02:00
Michael Natterer
38c86da8e9 app: factor out utility function gimp_get_fill_params()
which returns an error if there is no pattern for GIMP_FILL_PATTERN.
Use it instead of having the same code in 3 variants, and make error
handling consistent with bucket fill.
2014-06-03 14:00:01 +02:00
Michael Natterer
1416743b5c app: use GimpFillType in gimp_drawable_bucket_fill()
GimpBucketFillMode is now tool- and pdb-only.
2014-06-03 01:34:51 +02:00
Michael Natterer
425748dab0 libgimpbase, *: rename GimpFillType values: GIMP_FOO_FILL -> GIMP_FILL_FOO
Change all users accordingly and add compat enum values and compat
constants to script-fu and pygimp.
2014-06-03 01:11:32 +02:00
Michael Natterer
2068c61a85 Bug 730862 - Preview frozen while dragging selection tools...
...(crop, rectangle, etc) in large image zoomed-to-fit

Default to GIMP_MOTION_MODE_COMPRESS in all tools, and override it to
GIMP_MOTION_MODE_EXACT if the tool really needs the exact path of
motion events. This greatly reduces the events processed by the
rectangle tools and makes them much more responsive.
2014-06-02 20:55:33 +02:00
Michael Natterer
1781b79a16 app: record GimpDrawTool's last draw time *after* it has drawn its stuff
not before. Doesn't seem to change things but it's more correct.
2014-06-02 20:45:31 +02:00
Michael Natterer
069996d75f app: some random code cleanup 2014-06-02 20:17:39 +02:00
Michael Natterer
1464bee257 app: use the GParamSpec's nick as label in gimp_prop_spin_scale_new()
if a NULL label was passed. Override this with explicit calls to
gimp_spin_scale_set_label() in the two cases where we really don't
want a label.
2014-06-01 23:39:19 +02:00
Michael Natterer
0349b8972a app: rename gimpimage-contiguous-region.[ch] to gimppickable-....[ch]
The functions don't need to know about sample_merged, in fact they
used the boolean only to either use the passed image or drawable and
otherwise ran the same code. The sample_merged logic belongs into
their callers (and sometimes not even there).
2014-05-31 09:52:44 +02:00
Michael Natterer
227cff3af4 app: add gegl:color-rotate to Colors -> Map 2014-05-29 18:34:45 +02:00
Michael Natterer
00f6973b3c app: add gegl:convolution-matrix to Filters -> Generic 2014-05-29 02:36:59 +02:00
Michael Natterer
a06d570748 app: rename gimpproptable.[ch] to gimppropgui.[ch] 2014-05-27 02:15:48 +02:00
Michael Henning
6923f49b0d app: Fix broken header guards. 2014-05-25 20:50:56 -04:00
Michael Natterer
7286bbda52 app: use GimpSpinScale in the shear tool dialog 2014-05-25 15:44:38 +02:00
Michael Natterer
38c0937b8f Bug 723534 - Warp transform tool does not follow active layer
Add GIMP_DIRTY_ACTIVE_DRAWABLE to the warp tool's dirty mask, so it
correctly switches to the new active layer. Also remove
GIMP_DIRTY_IMAGE_STRUCTURE, I don't know why that was there in the
first place.
2014-05-25 15:00:49 +02:00
Michael Natterer
62cbd3eac3 app: show the region combo only if the op has the "position-dependent" key
otherwise, hide it and default to SELECTION.
2014-05-24 03:06:24 +02:00
Michael Natterer
bb73acbb15 app: create an empty node with the gegl:nop operation
so we can safely ask for its name (workaround for GEGL warning).
2014-05-24 03:04:26 +02:00
Michael Natterer
3550132ac7 app: add support for picking GEGL relative-coordinate values
Also, don't link relative coordinates by default, and remove some crap
heuristics that predate property keys.
2014-05-24 01:38:15 +02:00
Michael Natterer
6c5515c676 app: allow to specify the workarea of GEGL ops in the GEGL tool GUI
Add a combo that switches between "selection" and "entire layer".
Need to find a way to hide that thing when the setting makes no
difference. Also the combo is generally pretty much experimantal.
2014-05-24 01:07:28 +02:00
Michael Natterer
413846475f app: make GimpOperationTool manage an icon name for the GUI
and add an icon_name parameter to gimp_operation_tool_set_operation().
2014-05-22 23:29:59 +02:00
Michael Natterer
7ae3612485 app: GimpBrightnessContrastTool: don't call gimp_image_map_tool_preview()
it was redundant because the function already modified the config
object.
2014-05-22 01:25:01 +02:00
Michael Natterer
ebb663e1c6 Revert "app: add a small delay when applying a GUI change in GimpImageMapTool"
This reverts commit d46a8335e6,
it was a bad idea (like this at least).
2014-05-22 01:17:52 +02:00
Michael Natterer
d46a8335e6 app: add a small delay when applying a GUI change in GimpImageMapTool
This keeps the tool more responsive for expensive ops, since multiple
fast changes are compressed into one call to gimp_image_map_tool_preview().
2014-05-22 00:50:21 +02:00
Michael Natterer
4a0e9a2083 app: gegl:noise-cell -> gegl:cell-noise 2014-05-19 01:31:55 +02:00
Michael Natterer
c899f14f79 app: add gegl:panorama-projection to Filters -> Map 2014-05-17 01:23:24 +02:00
Michael Natterer
9e1ee4235f app: add gegl:perlin-noise and gegl:simplex-noise to Filters->Render->Clouds 2014-05-17 01:17:30 +02:00
Michael Natterer
e09453cfbb app: add gegl:tile-glass to Filters -> Artistic 2014-05-16 21:59:30 +02:00
Øyvind Kolås
2df26f7fd8 app: GimpOperationTool: change values for color roles property keys
Foreground and background are GIMP concepts; the annotations on GEGL ops
should be about how the operation makes use of the meta-data; not where
it comes from in one particular application using GEGL.

old names:

"role", "foreground-color",
"role", "background-color",

new names:
"role", "color-primary",
"role", "color-secondary",
2014-05-16 17:05:50 +02:00
Michael Natterer
befb871b6e app: GimpOperationTool sync the op with drawable/context in reset() 2014-05-16 16:28:24 +02:00
Michael Natterer
f50b215d16 app: add a default impl of GimpImageMapTool::reset()
and chain up where possible instead of duplicating that code.
2014-05-16 16:22:31 +02:00
Michael Natterer
86988e7d67 app: GimpOperationTool: don't crash GimpGeglTool 2014-05-16 08:21:33 +02:00
Michael Natterer
58b096e02e app: fix x/y copy-paste confusion in last commit 2014-05-16 03:17:08 +02:00
Michael Natterer
dac7201ead app: follow GEGL propertiy keys convention change
and clean up the magic a bit.
2014-05-16 03:10:01 +02:00
Michael Natterer
0dd1a4b552 app: sync the op with the drawable/image/gimp in GimpOperationTool
which currently means setting FG/BG color on properties with the
right GEGL property keys, and the output size of source ops.
2014-05-16 02:32:16 +02:00
Michael Natterer
8be52f6aa7 app, libgimp*: pass translated blurbs to GIMP_CONFIG_INSTALL_PROP_FOO()
instead of passing N_()-strings; and remove gettext() calls on these
strings when using them. Reduces complexitx, and fixes double- and
untranslated strings. Also enables to treat properties of GIMP and
GEGL objects the same way, which was totally broken before.
2014-05-14 23:34:01 +02:00
Michael Natterer
65a65947d9 app, libgimp: replace GTK_STOCK_FOO by icon names
unless it's a stock ID used for an action button, will address that
later.
2014-05-11 22:49:22 +02:00
Michael Natterer
17167594ea app: use the newly added libgimpwidgets icon name APIs 2014-05-07 21:32:09 +02:00
Michael Natterer
0d2d1c3752 app: port most of app's GUI from stock IDs to icon names
There is still quite some stock ID rendering around, stay tuned...
2014-05-07 15:30:38 +02:00
Michael Natterer
23037b5230 app: convert all stock IDs kept around by the core by icon names
Particularly GimpViewable's stock_id. Make sure old config files
containing stock IDs are still properly parsed.
2014-05-07 01:01:56 +02:00
Michael Natterer
a601e21281 app: add gegl:noise-cell and gegl:noise-reduction to the menus 2014-05-05 02:06:10 +02:00
Michael Natterer
84ce7f1a9a app: add a "Gamma hack" toggle to the GimpImageMap dialog 2014-05-04 20:42:58 +02:00
Michael Natterer
242ccacdcc app: s/paint_brush/paintbrush/ in the paintbrush action code 2014-05-03 22:55:05 +02:00
Michael Natterer
7d398da360 app: connect the warp tool's effect size to the standard tool size action 2014-05-03 20:24:09 +02:00
Mukund Sivaraman
a2f6d60a42 app: Return NULL if assertion fails 2014-05-02 23:32:53 +05:30
Michael Natterer
843866e7e7 app: make things behave more reasonable with multiple monitors
There is now a preference option that determines whether windows
should be opened on the same monitor as before. It should be disabled
when the machine gets monitors plugged/unplugged dynamically ("laptop")
and enabled when there is a static multi-monitor setup ("wokstation").
This is merely the current simplistic policy on top of the newly added
underlying infrastructure:

- pass integer monitor numbers around in all places where we already
  pass around a GdkScreen. Pass the "current" monitor to these changed
  APIs, where "current" is either the monitor where the action-triggering
  widget is, or if that is unavailable the monitor where the mouse is.

- add gimp_widget_get_monitor() in order to easily get to the monitor,
  just like gtk_widget_get_screen().

- add screen and monitor parameters in some places that were missed
  before.

- in sessionrc, save all window positions relative to the window's
  monitor, and save the monitor separately, if it's not the screen's
  primary monitor.

- when restoring window positions, use the stored monitor when the new
  prefs options says so (use the screen's primary monitor if there is
  no stored monitor), otherwise use current monitor that is now passed
  around.
2014-05-02 03:01:23 +02:00
Michael Natterer
b60e1779cd app: pass a GimpGradient to gimp_drawable_blend(), not a GimpBlendMode
The blend mode is now only a PDB compat enum, translate between
GimpBlendMode and the built-in gradients in the gimp-edit-blend PDB
wrapper.
2014-04-30 09:17:42 +02:00
Michael Natterer
b196a42d8e app: add missing include in gimpseamlesscloneoptions.c 2014-04-30 00:05:47 +02:00
Jehan
5ca9240d74 app: display a status error when seamless cloning without foreground image. 2014-04-30 09:11:31 +12:00
Jehan
8f410b927a app: optimize and add progress information to seamless clone
Display information when seamless clone is being processed.
Also ensure that I don't compute again when no properties is changed.
2014-04-30 09:10:31 +12:00
Jehan
cb93f2bd27 app: commit seamless clone in progress when switching tools. 2014-04-30 09:08:09 +12:00
Jehan
5077a149f3 app: add correct options for seamless clone operation. 2014-04-30 09:07:03 +12:00
Michael Natterer
a4223766f2 all,libgimp*: move GimpConvolveType and GimpInkBlobType to libgimpbase
and make GimpConvolveType's values sane.
2014-04-29 22:44:58 +02:00
Michael Natterer
22c222291d libgimpbase,*: clean up enum values in gimpbaseenums.h
GIMP_ADD_foo_MASK -> GIMP_ADD_MASK_foo
GIMP_foo_MODE -> GIMP_BLEND_foo
GIMP_foo_CLONE -> GIMP_CLONE_foo
GIMP_foo -> GIMP_DODGE_BURN_TYPE_foo
GIMP_foo -> GIMP_TRANSFER_foo

Add compat values for the old names and compat code to script-fu
and pygimp.
2014-04-29 20:58:30 +02:00
Michael Natterer
1397b9aae7 app: use gimp_draw_tool_add_arc() for the GimpPaintTool brush circle
because add_handle() doesn't scale with the image.
2014-04-20 22:03:17 +02:00
Jehan
c2470611d9 app: fix variable typo.
Small bug in commit 0bdb747. A variable was initialized twice and
another none. That's for peer programming. :-)
2014-04-20 19:24:03 +12:00
Michael Natterer
0bdb74710a app: rename the value-1...value-4 actions to opacity, size, aspect, angle 2014-04-19 20:09:39 +02:00
Michael Natterer
6e726f248f app: use the right aspect and angle actions for GimpBrushTool 2014-04-19 19:53:40 +02:00
Michael Natterer
fb8b05a149 app: FG select: remove some redundant "display" parameters 2014-04-19 03:35:31 +02:00
Michael Natterer
6b10b0511a app: FG select: refresh the preview when matting options change 2014-04-19 02:51:00 +02:00
Michael Natterer
de710e72d1 app: FG select: default to drawing foreground strokes 2014-04-19 02:50:38 +02:00
Michael Natterer
6ec272fde7 Bug 312780 - Add undo to foreground selection tool
Implement undoing strokes by keeping copies of the changed parts
of the trimap around in internal undo/redo stacks.
2014-04-19 00:34:21 +02:00
Michael Natterer
df8a148db0 app: make the transform tool's undo functions static 2014-04-18 23:03:22 +02:00
Michael Natterer
b8a3f395e5 app: FG select: turn the "Preview" button into an actual toggle button 2014-04-18 22:37:33 +02:00
Michael Natterer
35f23b5311 app: FG select: use the FG select stock icon/text instead "Apply"
and GTK_RESPONSE_APPLY instead of a private RESPONSE_APPLY.
2014-04-18 22:15:35 +02:00
Michael Natterer
1756779771 app: FG select: refactor to use the standard tool cancel/commit logic
Simplifies things and prevents losing a complex selection on tool change.
2014-04-18 22:06:07 +02:00
Michael Natterer
ebc4910a7c app: FG select: reorder functions to match all other tools 2014-04-18 21:52:38 +02:00
Michael Natterer
5ba7eaa5c7 app: FG select: remove trailing space from the "status_mode" message
such formatting should not be done intranslatable strings, instead
add the space between the two messages when putting them together
using an untranslatable format string.
2014-04-18 21:42:08 +02:00
Michael Natterer
667f4e2d3a app: FG select: rename "Reset" to "Cancel" because that's what it does
Also call update_gui() at the right places so we don't leave the GUI
in an inconsistent state.
2014-04-18 21:38:53 +02:00
Michael Natterer
a53c2f8b30 app: cancel the active tool before going brightness/contrast->levels->curves
because changing tools now automatically commits the old tool.
2014-04-18 21:15:46 +02:00
Michael Natterer
2e3011bddf app: FG select: implement GimpTool::initialize()
And create/show the GUI there, so it only becomes visible after
actually activating the tool with a click. Also refuse to operate
on invisible drawables.
2014-04-17 10:55:07 +02:00
Michael Natterer
d695c98d74 app: free select: start the draw tool more subclass-friendly 2014-04-17 10:51:50 +02:00
Michael Natterer
a876c1b4b0 app: always overlay FG select's GUI on the canvas 2014-04-17 08:48:42 +02:00
Michael Natterer
a18f196dd3 app: FG select: fix condition for upchaining in key_press()
Fixes committing the free select using return.
2014-04-17 01:59:34 +02:00
Michael Natterer
2d797bf8d5 app: FG select: remove parameters from stroke_paint()
and factor out a cancel_paint() function.
2014-04-17 01:52:21 +02:00
Michael Natterer
e138333204 app: FG select: implement canceling the current stroke (right mouse button) 2014-04-17 01:46:32 +02:00
Michael Natterer
05abd5a37d app: don't call gimp_free_select_tool_select() from FG select
It doesn't serve any purpose since its implementation doesn't
do anything in FREE_SELECT mode.
2014-04-17 01:42:38 +02:00
Michael Natterer
61aaa11158 app: reorder some prototypes in FG select 2014-04-17 01:40:08 +02:00
Michael Natterer
8836a1eae1 app: general cleanup in the foreground select tool
- fix some indentation
- implement GimpTool::options_notify() instead of a signal callback
- consistently chain up first in FREE_SELECT state
- misc. cleanup
2014-04-16 23:03:57 +02:00
Michael Natterer
b1a0b4555e Bug 726181 - Heal tool mode is ignored - always in "Normal" mode
Make the paint mode menu insensitive for the heal tool.
2014-04-15 17:15:32 +02:00
Michael Natterer
60da428c73 app: add gegl:apply-lens to Filters -> Distorts 2014-04-13 20:58:25 +02:00
Michael Natterer
6d5b6a648d app: turn the paint tool fallback cursor cross into a circle 2014-04-12 22:17:55 +02:00
Michael Natterer
2a9b6bf569 app: make blend's and straight line's start-line-end drawing look nicer
Use circle handles instead of crosses, and put the items into a stroke
group so they don't look ugly when drawing over each other.
2014-04-12 22:10:26 +02:00
Michael Natterer
36905bf46c app: foreground select: the initial rough selection is an unknown area
not the foreground area. This seems to make the tool do something useful.
2014-04-12 21:31:38 +02:00
Michael Natterer
693d0d082b app: don't draw a redundant fallback crosshair when a line preview is shown
and introduce some local variables is gimp_paint_tool_draw() to reduce
clutter.
2014-04-12 15:26:11 +02:00
Michael Natterer
d897188e32 app: also move the "draw brush outline" logic from brush to paint tool
So all paint tools honor the setting.

Add GimpPaintTool::get_outline() which either returns an outline, or
calls gimp_paint_tool_set_draw_cursor() and implement it in
GimpBrushTool and GimpInkTool. Handle all brush/circle/fallback
drawing in gimp_paint_tool_draw().
2014-04-12 15:03:15 +02:00
Michael Natterer
1ade034c49 app: move "show paint tool cursor" logic from GimpBrushTool to GimpPaintTool
Now all paint tools (also ink and mypaint brush) honor the setting and
can work without mouse cursor.
2014-04-12 12:54:08 +02:00
Michael Natterer
66010e6c6d Bug 623734 - No brush outline with dynamics set to 'size' on 'pressure'
Improve the logic in gimp_brush_tool_draw() and draw a brush-sized
circle if the actual brush outline got scaled away by dynamics.
2014-04-12 01:13:11 +02:00
Michael Natterer
e3a98eade2 app: use gimp_paint_tool_set_draw_circle() in the ink tool
so we get at least a rough preview of where the paint will go.
2014-04-09 15:27:37 +02:00
Michael Natterer
703c2c78c4 app: add gimp_paint_tool_set_draw_circle()
which enables drawing a circle with a given radius at the cursor
location.
2014-04-09 15:27:31 +02:00
Michael Natterer
e8459beb24 app: don't create a fallback crosshair in gimp_brush_tool_create_outline()
Instead, draw the crosshair in gimp_brush_tool_draw() if create_outline()
didn't return an item *and* if there is no brush tool cursor.

In gimp_source_tool_draw(), don't add an additional crosshair if
create_outline() returned an item.

This fixes both "no cursor at all" and "both outline and crosshair
shown" for certain prefs settings conbinations (bug #623734).
2014-04-09 14:53:24 +02:00
Michael Natterer
88e4d7e468 app: commit ongoing tool operations on tool change instead of cancelling
On tool change, we used to simply halt tools before switching to the
new one, which meant losing ongoing live-previewed tool changes, like
transforms, warps and color corrections. This change makes them being
applied to the image instead before switching to the new tool:

Add enum value GIMP_TOOL_ACTION_COMMIT that is passed to
GimpTool::control() before tool switching. Handle the new enum value
in all tools, and actually commit the previewed stuff. This changes
the behavior of GimpCageTool, GimpImageMapTool, GimpTransformTool and
GimpWarpTool.
2014-04-04 22:34:26 +02:00
Michael Natterer
40d42d113e app: make tool_manager_select_tool() a private function 2014-04-04 16:47:51 +02:00
João S. O. Bueno
72ac53705f Adds "fill" arrange modes to the Align Tool
The Align Tool had to be used in a very hacky way if one
intended to evenly distribute items across an image,
or other reference object (it would actually require one to
calculate the item spacing out of GIMP). This adds vertical
and horizontal fill modes: the reference object is divided
in N equal segments, where N is the number of items,
and each item is placed in the center of one of
these segments. The existing "offset" parameter
is used as an extra margin for the distribution,
and can be set to negative values, so that the items can
even get moved outside the boundaries of the reference object.
2014-03-13 03:38:53 -03:00
João S. O. Bueno
8d85c0c41c Enables aligning of elements using the active Path
For some reason, using the image active Path as
a reference for the align tool was displayed
in the UI, but disabled in the code.
2014-03-12 22:44:26 -03:00
Michael Natterer
b13c68fda6 Bug 701159 - Wrong name in transform tool dialogs...
...when acting on a path or selection

Factor out the code that checks if an active item exists and if it's
transformable (not locked etc.) and use that function in more places.
This fixes both the wrong dialog labels and the tool running into
broken states when the selection or a path are being transformed.
2014-02-05 00:57:28 +01:00
Michael Natterer
1335bc42c8 app: halt the transform tool when switching layer|selection|path transform 2014-02-04 23:28:59 +01:00
Michael Natterer
651be184b7 Bug 721066 - There is a 2nd, broken, "GEGL Operation" tool in the toolbox
Make the operation tool invisible by default.
2014-02-04 00:19:30 +01:00
Michael Natterer
7385e030dd app, libgimp: add increment parameters to gimp_prop_widget_set_factor()
Step and page increments can't be reasonable calculated or guessed
based on the GUI widget's factor, so pass them each time we call
set_factor(). This change reintroduces sane ranges for the levels tool
for != u8 images again.
2014-02-03 22:57:51 +01:00
Michael Natterer
5054241ca6 Bug 722034 - Incorrect snapping behaviour for scale tool
Always snap to the center of transform tool handles.
2014-01-29 23:40:35 +01:00
Michael Natterer
ef85845372 app: add gimp_paint_options_set_default_brush_size()
and use it globally instead of two different methods, one of which was
forgotten to be ported to the new aspect ratio range where 0.0 means
1:1. Add a FIXME comment in paint_tools.pdb where I think setting the
default size is a bug, see #721249.
2014-01-04 15:48:34 +01:00
Michael Natterer
ca938c1275 app: add gegl:texturize-canvas to the menus as "Apply Canvas" 2014-01-01 19:07:48 +01:00
Elle Stone
f79bff0719 Increase Levels, Curves increments to 10000.
1000 increments is not enough for just barely noticeable
shadow adjustments in linear gamma color spaces.
2013-12-26 15:41:02 +01:00
Michael Natterer
81c02e7db1 Bug 720492 - Letter spacing in Text Tool not reset to default
Also reset the "letter-spacing" property in gimp_text_options_reset().
2013-12-20 13:11:53 +01:00
Daniel Sabo
dca3559f13 app: Allow painting in Foreground Select's preview mode 2013-12-14 02:49:00 -08:00
Daniel Sabo
e9d3bf8f19 Improve Foreground Select tool's GUI
* Add a dialog with Preview, Apply, and Reset buttons instead of
  depending only on hidden keyboard shortcuts.
* Change default paint mode to Unknown.
* Disable engine list when there is only one engine available.
* Hide useless Anti-Alias toggle.
* Write to selection instead of the layer mask.
2013-12-13 12:20:19 -08:00
Daniel Sabo
845139f910 gegl-tool: Blacklist "display" ops by category 2013-12-03 09:43:00 -08:00
Téo Mazars
9e429993c7 app: add gegl:wind to Filters -> Distorts 2013-12-01 12:57:15 +01:00
Massimo Valentini
b81641e25f app: fix two typos 2013-11-28 19:44:45 +01:00
Téo Mazars
5152e1061c app: add gegl:stretch-contrast-hsv to Colors/Auto/
before removing the old plugin
2013-11-16 16:31:35 +01:00
Téo Mazars
5efcc0eb09 app: add gegl:stretch-contrast to Colors/Auto/
before removing the plug-in
2013-11-15 19:12:56 +01:00
Téo Mazars
7aeb9da6e3 app: follow gegl:dot removal
gegl:dot is now included in gegl:pixelize
2013-11-11 16:52:10 +01:00
Jehan
2aabbbd9c7 Bug 662787 - Segfaults when trying to set a large text size
If a font size is too big for cairo or pango to deal with, nicely back
up from rendering and alert the user via an error dialog.
2013-10-24 20:23:51 +13:00
Michael Natterer
697572ccc0 app,libgimp*: fix includes to follow our include policy
- don't include <gdk-pixbuf/gdk-pixbuf.h> in headers in app/
- instead, include it in many .c files instead of <glib-object.h>,
  finally acknowledging the fact that app/ depends on gdk-pixbuf almost
  globally
- fix up includes as if libgimpbase depended in GIO, which it soon will
2013-10-15 01:58:39 +02:00
Téo Mazars
68feec5dcf app: add gegl:mosaic to Filters -> Distorts 2013-09-21 19:02:10 +02:00
Jehan
ac0ac60ca9 Bug 708521 - Getting rid of cage_complete property on GimpCageTool, redundant with tool_state. 2013-09-22 02:28:30 +12:00
Jehan
2294b8da26 Bug 708519 - Fix using Backspace to delete a closed cage tool's points. 2013-09-22 02:17:22 +12:00
Jehan
5e331e1d25 Bug 708517: Assertion on cage tool commit with ENTER + fix cage completion with ENTER.
The key press handler must return TRUE on successfully processing the key,
otherwise the handler ends up being run several times.
2013-09-21 22:42:41 +12:00
Michael Natterer
74c54464c3 app: add a label to GimpOperationTool's aux input button
and don't pack it expanding.
2013-09-17 20:06:37 +02:00
Michael Natterer
52fe319fcb app: use a GimpPickableButton for GimpOperationTool's aux input
also WIP and currently looks like shit.
2013-09-15 00:37:42 +02:00
Jehan
c7aa623a55 app: clean out a big bunch of leading tabs.
For some unknown reason, most calls to gimp_message_literal() were
indented with tabs.
2013-09-15 04:59:20 +12:00
Michael Natterer
125cf2a2a3 app: use the image instead of the projection for accessing a pickable 2013-09-13 23:29:06 +02:00
Michael Natterer
0d5910aa4b app: add gegl:bump-map to Filters -> Map 2013-09-04 00:16:25 +02:00
Michael Natterer
b60d361d6c app: add gegl:plasma to Filters -> Render -> Clouds 2013-08-27 08:14:51 +02:00
Michael Natterer
28c9470d5f app: fix warning when a gegl op's aux input combo box gets destroyed
gimp_operation_tool_aux_selected() is called with a NULL drawable
when the combo is destroyed, but at that time the GeglNode we set
the buffer on is already gone. Instead of adding evil if()s,
connect_object() the combo's "select-item" signal to the node
instead of the tool, so it gets disconnected automatically.
2013-08-25 22:41:43 +02:00
Téo Mazars
8bad383a3b app: Add gegl:channel-mixer to Color/Components 2013-08-03 23:30:58 +02:00
Téo Mazars
23bc1b255c app: Add gegl:antialias -> Filters/Enhance 2013-08-03 22:47:58 +02:00
Téo Mazars
62f65ea981 app: add gegl:tile-seamless to Filters -> Map 2013-07-28 19:15:25 +02:00
Jehan
3aaa0a956d Bug 704238 - Notify through status bar that warp effect is committed with ENTER 2013-07-21 08:46:13 +09:00
Michael Natterer
d682135d7a app: add gegl:alien-map to Colors -> Map 2013-07-18 22:53:06 +02:00
Michael Natterer
d1795ac204 Bug 700193 - undoing paint tools doesn't update last_coords properly
paint_core->start_coords is in fact the last stroke's endpoint and
only used for storing it in GimpPaintCoreUndo, so the last endpoint
can be resotred for straight-line painting after an undo. Make the
code actually doing that.
2013-07-15 00:41:43 +02:00
Michael Natterer
0fc78cd811 app: don't add the aux input as a child to GimpOperationTool's operation
It turns the operation into a graph, which breaks things.
2013-06-30 19:10:49 +02:00
Michael Natterer
0e98904f78 app: start supporting composer ops in GimpOperationTool
If the operation has an aux input, add a combo that allows feeding
it one of the image's channels. This is all work in progress and
and should allow to use any drawable of any image.
2013-06-29 01:18:19 +02:00
Michael Natterer
7947f24bd8 app: make gimp_operation_tool_set_operation() more readable 2013-06-27 23:42:08 +02:00
Michael Natterer
f56f6d1255 app: follow the GEGL invert -> invert-linear vs. invert-gamma change
and invert masks using invert-linear and other drawables using
invert-gamma. drawable_invert_cmd_callback() still always uses
invert-gamma even though it can be used on layer masks.
2013-06-24 00:45:04 +02:00
Michael Natterer
caf73f5f35 Add support for both gamma-corrected and linear for all bit depths
- Add new enum GimpComponentType which contains u8, u16, u32 etc.
- Change GimpPrecision to be u8-linear, u8-gamma, u16-linear etc.
- Add all the needed formats to gimp-babl.c
- Bump the XCF version to 5 and make sure version 4 with the old
  GimpPrecision enum values is loaded correctly

This change blows up the precision enums in "New Image" and
Image->Precision so we can test all this stuff. It is undecided what
format will be user-visible options in 2.10.
2013-06-23 16:51:24 +02:00
Clayton Walker
df21310b0f app: properly initialize variables 2013-06-23 01:41:50 +02:00
Michael Natterer
31e9cc2ad9 Bug 702369 - foreground selection doesnt work with image precision >8 bit
This removes the obsolete check which makes the tool fail from
gimp_display_shell_set_mask(). Also change the foreground select tool
and the display mask from using GimpChannel to GeglBuffer, because
that's what it needs, simply buffers. Most changed files simply newly
include <gegl.h> because a GeglBuffer appeared in two headers.
2013-06-22 22:26:46 +02:00
Michael Natterer
2e8ef97c13 Bug 701803 - Cage Transform raises segmentation fault...
...if layer bounds are changed.

Call gimp_tool_control_set_preserve (tool->control, FALSE) so it is
stopped when the drawable changes.
2013-06-18 19:05:54 +02:00
Michael Natterer
6280e4933a app: add gimp_handle_bar_connect_events()
to replace 3 completely ugly signal connections, repeated in 4 places.
2013-06-17 22:13:48 +02:00
Michael Natterer
640189d01e app: merge levels_linear_gamma_update() into its only caller
also reorder some functions to be in vtable order.
2013-06-17 22:07:31 +02:00
Michael Natterer
234a05845f app: use prop widgets in GimpLevelsTool, and generally clean up a bit 2013-06-17 02:07:10 +02:00
Michael Natterer
a009b18a6e app: use gimp_prop_widget_set_factor() not gimp_spin_scale_set_factor() 2013-06-15 20:52:57 +02:00
Michael Natterer
731360a8f7 app: add gimp_prop_widget_set_factor()
which allows adjustment-based prop widgets to display the property
value multiplied by factor. Remove gimp_prop_opacity_spin_scale_new()
because that's simply a factor of 100.0.
2013-06-15 01:28:54 +02:00
Michael Natterer
efbe095b66 app: configure GimpBrightnessContrastTool's scales according to image precision 2013-06-14 08:17:39 +02:00
Michael Natterer
afb767fcc1 app: use 0..1 axes in GimpCurveTool's curves widgets on != 8-bit images 2013-06-13 00:23:49 +02:00
Michael Natterer
4edba97932 app: port GimpThresholdTool to the new variable # of histogram bins 2013-06-12 16:35:15 +02:00
Michael Natterer
6c97908a9e app: add "gboolean gamma_corrected" to gimp_histogram_new()
so we can make histograms of the gamma-corrected image data. Pass
TRUE all over the place so the histogram works perceptually. This
needs more thinking...
2013-06-12 01:02:25 +02:00
Michael Natterer
a7f42de4c0 app: turn GimpHistorgram into a GimpObject, no other changes 2013-06-11 21:23:32 +02:00
Michael Natterer
875b1705fc app: don't ROUND() all input/output values to int in GimpLevelsTool
That was a leftover from before the change to 0..100 sliders for
non-8-bit images. Spoted by Elle Stone.
2013-06-10 21:51:15 +02:00
Michael Natterer
25cc5922b6 app: add gimp_tool_gui_set_focus_on_map() and use it 2013-06-08 15:34:23 +02:00
Michael Natterer
90797f0927 app: add an embedding toggling test button to the transform dialogs 2013-06-08 01:33:35 +02:00
Michael Natterer
ad8d12ed69 app: add "response" signal to GimpToolGui
and connect to it instead of to gimp_tool_gui_get_dialog()'s signal.
One more step towards on-the-fly embedding/detaching.
2013-06-07 23:45:11 +02:00
Michael Natterer
0afa7d30f0 app: add gimp_tool_gui_set_description() and use it 2013-06-07 17:01:39 +02:00
Michael Natterer
9a811d276e app: add gimp_tool_gui_set_alternative_button_order() and use it
Also make some of GimpToolGui's memory management proper, there was
no leak but it needs to be proper in order to add runtime switching
between dialog and overlay.
2013-06-07 15:18:24 +02:00
Michael Natterer
88387d6e8d app: remove the "shell" parameter from gimp_tool_dialog_new() and gui_new() 2013-06-07 12:19:42 +02:00
Michael Natterer
9b9302b91a app: use a GimpToolGui in GimpColorPickerTool 2013-06-07 12:11:59 +02:00
Michael Natterer
c86eebb034 app: use a GimpToolGui in GimpMeasureTool 2013-06-07 12:03:39 +02:00
Michael Natterer
1c20940f82 app: use a GimpToolGui in GimpTransformTool 2013-06-07 11:52:48 +02:00
Michael Natterer
7abbd38a25 app: use a GimpToolGui in GimpImageMapTool
instead of implementing both dialog types manually.
2013-06-07 10:28:41 +02:00
Michael Natterer
964d59df58 app: use gimp_tool_control_push/pop_preserve() in GimpWarpTool
instead of set_preserve(TRUE/FALSE). It makes no difference in this
case, but push/pop is the right API to use anyway.
2013-06-07 10:05:05 +02:00
Michael Natterer
785436f32e app: don't crash the flip tool on each click
Don't push an internal transform tool undo after invoking the flip
special case of directly transforming on each click, because the
transform clears the tool state and there is nothing to undo anyway
(flip is atomic). Additionally, add a precondition check to
gimp_transform_tool_push_internal_undo().
2013-06-06 02:08:00 +02:00
Michael Natterer
ec786816bb */Makefile.am: merge INCLUDES into AM_CPPFLAGS
automake-1.13 finally warns about this anachronism.
2013-06-05 20:48:37 +02:00
Michael Natterer
6f17eb54a1 app: make sure the warp tool halts when the drawable is changed
Set preserve=FALSE by default, also don't set preserve=TRUE around
aborting the image map, that's not needed any longer because image map
has stopped to be a temporarily destructive thing.
2013-06-04 10:16:32 +02:00
Michael Natterer
f1e5544053 app: gegl:noise-CIE_lch was renamed to gegl:noise-cie-lch 2013-06-04 00:54:12 +02:00
Michael Natterer
a328f9d305 app: shorten enum GimpMattingEngine's value names
and reorder code in GimpForegroundSelectOptions to match the order of
properties.
2013-06-03 23:11:39 +02:00
Michael Natterer
28a9e69885 app: clean up and simplify the GimpForegroundSelectOptions GUI
Also use spin scales and the new combo box labels.
2013-06-03 23:05:39 +02:00
Michael Natterer
fc0765ce16 app: ellipsize most tool options combo boxes
which means that now check/radio button labels are our biggest
width-wasters.
2013-06-03 17:35:36 +02:00
Michael Natterer
a5d2123adf app: use the new combo box label in many tool options
and generally clean up a bit. Reuse the clone options code in the
perspective clone options. Addresses bug #122862.
2013-06-03 16:40:24 +02:00
Michael Natterer
cbbfe674b0 app: add gegl:motion-blur-circular and -zoom to Filters -> Blur
and follow the gegl:motion-blur -> gegl:motion-blur-linear rename.
2013-06-03 00:20:42 +02:00
Michael Natterer
338ca6694a app: add gegl:waves to Filters -> Distorts 2013-06-01 15:13:40 +02:00
Michael Natterer
86d0120482 app: add gegl:grid to Filters -> Render -> Pattern 2013-06-01 01:20:30 +02:00
Michael Natterer
7a284def90 app: add gegl:dropshadow to Filters -> Light and Shadow
Also move gegl:vignette there from Filters -> Decor.
2013-06-01 01:13:22 +02:00
Michael Natterer
01ada21ae6 app: add totally evil "heuristic" for picking coords to GimpOperationTool
This can't continue like that, GEGL properties need to be tagged
somehow using gegl_operation_class_set_keys(), as planned.
2013-05-31 22:56:27 +02:00
Michael Natterer
fc65928df7 app: reorder the list of blacklisted ops to be more managable
It's now two sections: ops that are in GIMP's menus, and ops
blacklisted for other reasons.
2013-05-31 22:54:46 +02:00
Michael Natterer
1ad50f300a app: don't manually blackist all GEGL transform ops any longer
They now all have the "transform" category set.
2013-05-31 09:37:00 +02:00
Michael Natterer
822057a4ff app: call gimp_color_tool_disable() when an old op's options_table dies
so gimp_image_map_tool_color_picked() isn't called any longer on clicks.
Add a warning there in case it happens anyway because this is always a
programming error.
2013-05-31 02:50:17 +02:00
Michael Natterer
3b68ae0f3c app, pdb, libgimp: Remove all traces of the supersampling recursion level
from all transform APIs. This is no longer used since we use GEGL to
transform, the value was only passed around and never used.
2013-05-31 01:15:32 +02:00
Michael Natterer
40a1efef09 app: GimpOperationTool: add support for picking coordinates from the image
gimp_operation_tool_color_picked(): if the picker's identifier is of
the form "param_spec_name:param_spec_name" and the param specs both
exist and are of the same numeric type, set the pick coordinates on
these properties of the operation's config object.
2013-05-30 23:32:54 +02:00
Michael Natterer
814c47b0b9 app: don't crash on a dangling image_map_tool->active_picker pointer
gimp_operation_tool_set_operation(): set it to NULL when destroying
the previous operation's options_table (if it was non-NULL it was a
widget from that table).
2013-05-30 23:28:26 +02:00
Michael Natterer
0a2b86e534 app: fix parameter name of gimp_image_map_tool_add_color_picker()
It's a "tooltip", and used as such, not a "help_id".
2013-05-30 23:25:39 +02:00
Michael Natterer
83dffbc03e app: fix signature of GimpColorTool's "picked" signal 2013-05-30 22:34:55 +02:00
Michael Natterer
b593e3eb02 app: add gegl:motion-blur to Filters -> Blur 2013-05-30 20:04:10 +02:00
Michael Natterer
b8558f8859 app: add coordinates to GimpColorTool's and GimpImageMapTool's "picked"
signals and vfuncs. This is currently unused, but GEGL operations
can soon pick coordinates just like they can pick colors.
2013-05-30 19:29:36 +02:00
Michael Natterer
73d7c28f76 app: add dedicated source files for gimp_prop_table_new() 2013-05-30 16:33:30 +02:00
Massimo Valentini
0a31b29b9a app: transform_tool - don't flush the image when display is NULL
it means the dialog is being deleted
2013-05-29 20:10:33 +02:00
Michael Natterer
e3ef19ec89 app: don't gimp_display_get_image(NULL) in gimp_transform_tool_response() 2013-05-29 19:41:54 +02:00
Michael Natterer
279abd260b app: add gegl:noise-spread to Filters -> Noise 2013-05-29 19:22:14 +02:00
Michael Natterer
963275e846 app: use gimp_prop_color_button_new() in GimpColorizeTool
which removes the remaining old callbacks. Remove the set/get_color()
API from GimpColorizeConfig and instead add an unserialized "color"
property that stores its value in the other properties.
2013-05-29 00:45:24 +02:00
Michael Natterer
0c70a79c69 app: use GimpSpinScales in GimpBrightnessContrastTool 2013-05-29 00:28:39 +02:00
Michael Natterer
905439b4bf app: use GimpSpinScales in GimpColorizeTool 2013-05-29 00:18:07 +02:00
Michael Natterer
a544b9d689 app: hue-saturation's lightness and saturation are -100..100 not -180..180 2013-05-29 00:16:25 +02:00
Michael Natterer
8ba777f5b1 app: use GimpSpinScales in GimpHueSaturationTool 2013-05-29 00:04:35 +02:00
Michael Natterer
3f193cd503 app: set GimpColorBalanceTool's sliders back to -100..100 2013-05-28 23:48:01 +02:00
Michael Natterer
1822bd1502 app: use gimp_prop_spin_scale_new() in GimpColorBalanceTool 2013-05-28 23:18:53 +02:00
Michael Natterer
783edc1e7b app: use gimp_prop_spin_scale_new() in GimpPosterizeTool
and remove tons of code needed to update the old stuff.
2013-05-28 22:47:12 +02:00
Michael Natterer
d5fb5922b7 app: port "range" and "preserve" widgets in GimpColorBalanceTool to propwidgets 2013-05-28 19:13:40 +02:00
Michael Natterer
38e771eea3 app: use gimp_prop_enum_radio_frame_new() in GimpDesaturateTool
and remove tons of code that was needed to update the old widget.
2013-05-28 19:01:14 +02:00
Michael Natterer
07c87c7ce1 app: add gegl:shift to Filters -> Distorts 2013-05-27 00:45:51 +02:00
Michael Natterer
9c69130f72 app: add gegl:fractal-trace to Filters -> Map 2013-05-26 23:58:12 +02:00
Michael Natterer
5f76a735af app: add gegl:deinterlace to Filters -> Enhance 2013-05-26 22:15:36 +02:00
Michael Natterer
9072bf331a app: rename GimpImageMapConfig to GimpSettings
It was misnamed from the beginning and has no relation to GimpImageMap
except that it happens to be used by GimpImageMapTools. Now it feels
less weird to potentially use it for other settings too.
2013-05-25 15:26:18 +02:00
Michael Natterer
df22570727 app: simplify gimp_tool_set_[active]_modifier_state()
by factoring out bits of code that were repeated 8 times, also
make sure we actually pass TRUE or FALSE as gboolean, and not some
(state & MODIFIER).
2013-05-25 02:09:33 +02:00
Michael Natterer
d4bb6e0fe7 app: some general cleanup in seamless clone 2013-05-23 23:12:17 +02:00
Michael Natterer
fb7ae4ba48 app: reorder functions in GimpSeamlessCloneTool to standard order 2013-05-23 22:59:51 +02:00
Michael Natterer
278def0bf9 app: set the warp tool's image_map to DRAWABLE mode 2013-05-23 19:30:46 +02:00
Massimo Valentini
e378a29a91 app: fix warping an offset layer with selection 2013-05-23 19:03:31 +02:00
Michael Natterer
fdfa2c782d app: integrate transform tool undo with normal image undo
Also clean up formatting a bit, and add gimp_transform_tool_halt()
which really cleans the tool's state, so we don't end up with wrong
undo/redo actions in a new tool interaction.
2013-05-23 16:02:42 +02:00
Michael Natterer
79c0ab31c2 app: some skeleton code for better warp cursors, does nothing 2013-05-22 23:59:44 +02:00
Michael Natterer
72e0743067 app: fix some broken wrap undo/redo behavior, and factor out common code 2013-05-22 23:47:31 +02:00
Michael Natterer
f862bfb342 app: don't leak all new warp ops, don't abort the image map on undo/redo 2013-05-22 23:37:22 +02:00
Michael Natterer
867c5721a6 app: implement redo in the warp tool 2013-05-22 23:26:07 +02:00
Michael Natterer
2a93677b0c app: implement undo in the warp tool, no redo yet 2013-05-22 23:01:51 +02:00
Michael Natterer
f51c8af556 app: remove the deleted node from the graph in gimp_warp_tool_undo() 2013-05-22 22:48:37 +02:00
Michael Natterer
b601018e33 app: update the display in a "changed" handler of the warp stroke
and get the update extents from the signal's "roi" parameter. Should
be more correct but produces more artifacts for me. Either this patch
is broken, or (more likely) this triggers a bug.
2013-05-22 22:43:32 +02:00
Michael Natterer
3eadcd5e9e app: don't leak all warp strokes, unref them in button_release() 2013-05-22 09:01:54 +02:00
Michael Natterer
6938486471 app: make warp honor the layer offset 2013-05-22 02:21:07 +02:00
Michael Natterer
8e95b72b64 app: reorder GimpWarpOptions properties so "behavior" is first 2013-05-22 01:10:30 +02:00
Michael Natterer
27fbc0a05e app: remove a bunch of unneded #includes from warp 2013-05-22 01:06:55 +02:00
Michael Natterer
a7eb1ee1a2 app: #ifdef warp debug printfs away 2013-05-22 01:04:29 +02:00
Michael Natterer
9426a94617 app: fix default tool order, warp is at the end of transform tools 2013-05-22 00:49:29 +02:00
Michael Natterer
b63be0e79a app: reorder warp tool functions to be in standard order 2013-05-22 00:47:43 +02:00
Michael Natterer
2264dc8d63 app: add gimp_warp_tool_halt() and make the tool's life cycle sane
Particularly, don't start any graph and imagemap madness in
oper_update().
2013-05-22 00:33:50 +02:00
Michael Natterer
78f6369114 app: general cleanup and formatting attack in the warp tool 2013-05-22 00:08:14 +02:00
Michael Natterer
199565f765 app: flush the display less aggressively, new GimpImageMap style 2013-05-21 23:46:33 +02:00
Michael Natterer
dff3f85c0d app: fix some warp tool brokenness and make it build 2013-05-21 23:36:42 +02:00
Michael Muré
35888a3848 warp tool: fix undo when imagemap is busy 2013-05-21 23:28:43 +02:00
Michael Muré
e5545f4a4f warp tool: range the range of the strength to 1-->100 2013-05-21 23:28:43 +02:00
Michael Muré
7193cdd72c warp tool: fix the undo to update the whole dirtied area 2013-05-21 23:28:43 +02:00
Michael Muré
877c2ef96e warp tool: fix one reason that make the outline not moving along the stroke 2013-05-21 23:28:43 +02:00
Michael Muré
a260039ec9 warp tool: fix wrong computation of the area to update and remove an uneeded anymore preview timer 2013-05-21 23:28:43 +02:00
Michael Muré
6abf634189 warp tool: fix commiting the deformation not working 2013-05-21 23:28:43 +02:00
Michael Muré
afa98e6ece warp-tool: temporary fix to update the preview with imagemap apply_region, not totally working 2013-05-21 23:28:42 +02:00
Michael Muré
81647f3531 warp-tool: probably bad change to use the apply_region of imagemap 2013-05-21 23:28:42 +02:00
Michael Muré
c3bb13ce26 warptool: enable the caching in imagemap 2013-05-21 23:28:42 +02:00
Michael Muré
7aa7c5814c warptool: use the warp operator imported to gegl 2013-05-21 23:28:42 +02:00
Michael Muré
57adfee72b warptool: some quick cleaning 2013-05-21 23:28:42 +02:00
Michael Muré
061a6ad85e gimpoperationwarp: add a hardness property
and use it to compute influence with a gaussian like curve
implementation use a lookup table to speed things gimpwarpoptions: add
a hardness property and UI
2013-05-21 23:28:42 +02:00
Michael Muré
5b5e9e30ae warp-tool: remove unneeded options_notify 2013-05-21 23:28:42 +02:00
Michael Muré
34117fdba0 warptool: change range value for strength to 0-1, max 10 2013-05-21 23:28:42 +02:00
Michael Muré
379b0586e3 warp tool: implement basic undo 2013-05-21 23:28:42 +02:00
Michael Muré
0b93770745 gimpwarptool: add basic UI to choose the behavior 2013-05-21 23:28:41 +02:00
Michael Muré
017995fcf3 gimpwarptool: achieve good interpolation along the stroke 2013-05-21 23:28:41 +02:00
Michael Muré
8d1df4bc65 gimpwarptool: ask for exact motion event 2013-05-21 23:28:41 +02:00
Michael Muré
1769750542 gimpwarptool: use a second timer to refresh the preview 2013-05-21 23:28:41 +02:00
Michael Muré
20174d4afb gimpwarptool: use a timer to add regularly point to the stroke 2013-05-21 23:28:41 +02:00
Michael Muré
eea8ff4ebc gimpwarptool: build a stroke to pass to the op 2013-05-21 23:28:41 +02:00
Michael Muré
990b02c8da gimpwarptool: move the test code to the gegl op 2013-05-21 23:28:41 +02:00
Michael Muré
df0416b4bc gimpwarptool: create a gegl graph to render the transformation, and
insert warp operation for each stroke
2013-05-21 23:28:41 +02:00
Michael Muré
ea2c7e7be1 gimpwarptool: use gimp_draw_tool_add_arc instead of gimp_draw_tool_add_handle to draw the effect size 2013-05-21 23:28:40 +02:00
Michael Muré
bcbc30c2a3 gimpwarptool: draw the effect size with taking care of zoom level 2013-05-21 23:28:40 +02:00
Michael Muré
ab42a60998 gimpwarptool: add logic to commit the transformation 2013-05-21 23:28:40 +02:00
Michael Muré
e6d05c6352 gimpwarptool: start the tool if the cursor is over an image and not started somewhere else 2013-05-21 23:28:40 +02:00
Michael Muré
7bc094a443 gimpwarptool: draw a circle around the cursor to indicate the size of the effect 2013-05-21 23:28:40 +02:00
Michael Muré
33f000d15c gimpwarptool: add strenght and size in the tool's options 2013-05-21 23:28:40 +02:00
Michael Muré
4f24f703ab gimpwarptool: proof of concept code to act on the coords buffer 2013-05-21 23:28:40 +02:00
Michael Muré
901a148760 gimpwarptool: add gegl infrastructure and image map for preview 2013-05-21 23:28:40 +02:00
Michael Muré
d6ed13ef6c GimpWarpTool: skeleton of the tool, with options 2013-05-21 23:28:40 +02:00
Michael Natterer
741792875e app: add the GimpApplicator back for painting, but make its use optional
Default to using the new code. This is out of pure curiosity how
GEGL changes affect painting with a purely graph-based method.
2013-05-21 18:55:03 +02:00
Michael Natterer
b2f318de57 app: add a description label to the GEGL tool dialog 2013-05-20 17:42:32 +02:00
Michael Natterer
f48aacee18 app: add gegl:emboss to Filters -> Distorts 2013-05-20 02:20:09 +02:00
Michael Natterer
94294cd114 app: add gegl:whirl-pinch to Filters -> Distorts 2013-05-19 23:28:06 +02:00
Michael Natterer
dd648b1c12 app: add gegl:cubism to Filters -> Artistic 2013-05-19 22:21:38 +02:00
Michael Natterer
31f7b7fd63 app: add gegl:red-eye-removal to Filters -> Enhance 2013-05-19 20:51:35 +02:00
Michael Natterer
042a2400ad app: blacklist "gegl:softglow" in the GEGL tool because it's in the menus 2013-05-19 19:06:46 +02:00
Michael Natterer
ef917b2c5c app: add an "area" parameter to gimp_image_map_apply()
and only update the drawable in that area if it's not NULL. Useful for
expensive interactive operations like warp, where the tool exactly
knows which area has changed.
2013-05-18 01:45:01 +02:00
Michael Natterer
e3180de960 app: remove GimpPickable implementation from GimpImageMap
It's not needed because we don't modify the drawable's
pixels any more.
2013-05-17 02:02:28 +02:00
Michael Natterer
775ba72d7e app: cleanup in GimpSeamlessCloneTool
- fix some leaks
- actually free the op, seems to cause a crash
- formatting cleanup
- remove lots of comments
2013-05-17 00:53:55 +02:00
Michael Natterer
0b37c9e374 app: some general minor seamless-clone cleanup, and make it build 2013-05-15 00:39:06 +02:00
Clayton Walker
32c129ded7 Update seamless clone tool to use new image map functions 2013-05-15 00:25:32 +02:00
Barak Itkin
a3e136ab7f Fix: The offset for seamless cloning should be relative to the drawable 2013-05-15 00:25:32 +02:00
Barak Itkin
c9134ab55f Make gimp use the all in one seamless clone GEGL operation 2013-05-15 00:25:32 +02:00
Barak Itkin
3f0cb773a6 Make the seamless clone tool compile again (update on API changes) 2013-05-15 00:25:31 +02:00
Barak Itkin
9e4e027ab0 Fix the the preview to redraw correctly! Also clean-up the code 2013-05-15 00:25:31 +02:00
Barak Itkin
ef235c389a Fix the preprocessing. It now works without UV caching.
This gimp commit uses gegl commit 2d2d01d47f84, which still passes the
preprocessing result as a gpointer (and not a GObject*), and still does
not cache the UV cordinates into a buffer.
The result of the preprocessing currently isn't freed!
2013-05-15 00:25:31 +02:00
Barak Itkin
9390247c33 Add work in progress for preprocessing before rendering the op 2013-05-15 00:25:31 +02:00
Barak Itkin
35255505fd Quick-Fix to the previous commit - return the right value on key press 2013-05-15 00:25:31 +02:00
Barak Itkin
a416acfe08 Fix bug in tilemanager unreffing and support committing the result
Unreffing the tilemanager of a GimpBuffer is wrong, since the function
to get the tilemanager of a buffer doesn't ref it.
Also, the operation of the tool can now be saved ("committed") using
the Enter key, and the tool can be halted using the Escape key. Note
however that we should do these in a nicer way, that does not require
restarting the tool to use it afterwards.
Finally, this commit removes the debug printing.
2013-05-15 00:25:31 +02:00
Barak Itkin
cab47522b7 Image map interaction works, and so are movement and drawing 2013-05-15 00:25:31 +02:00
Barak Itkin
8f2de693a7 Another WIP commit. There is a known tile manager leak, rest is OK 2013-05-15 00:25:31 +02:00
Barak Itkin
d745f85293 Another WIP commit. It now compiles, and runs with no runtime errors. 2013-05-15 00:25:31 +02:00
Barak Itkin
cacca4b317 commit of a WIP, introducing some of the actual tool logic 2013-05-15 00:25:31 +02:00
Barak Itkin
5fa0df17dd Add a skeleton for the seamless clone tool, based on the cage tool 2013-05-15 00:25:30 +02:00
Michael Natterer
5baabf87fd app: add gegl:exposure to Colors, and fix glitch in previous commit 2013-05-14 22:26:16 +02:00
Michael Natterer
de12010107 app: add gegl:box-blur to Filters/Blur 2013-05-14 21:34:03 +02:00
darkraid1
ac5428787e Bug 598523 - Protect hidden layers from editing
Don't allow tool operations on invisible items, just like we do for
group layers or locked items.

Cleaned up and enhanced the patch a bit --Mitch
2013-05-13 23:29:43 +02:00
Michael Natterer
8320381885 app: add untested infrastructure for tool-internal undo/redo
Add virtual functions GimpTool::undo(), ::redo(), ::get_undo_desc()
and ::get_redo_desc() and corresponding wrappers in tool_manager.

Make the edit-undo and edit-redo actions check tool undo/redo first
before invoking image undo/redo.
2013-05-12 19:51:52 +02:00
Jehan
3496e178ef Bug 699185 - when moving the pointer fast out of guide scope, do not keep it highlighted.
When a drawing timeout happens too close from the previous drawing, we don't want to cancel
the timeout function (FALSE), but simply retry later (TRUE).

In our case in particular, if you move your pointer very fast over a guide, the highlighting
drawing was happening less than MINIMUM_DRAW_INTERVAL before the un-highlighting drawing,
hence canceling the later, which caused the drawing bug.
2013-05-12 05:24:12 +09:00
Miroslav Talasek
1cd1541b2d app: port the foreground select tool to the GEGL matting ops
This is work in progress and needs the fixed GEGL ops too.
2013-05-08 00:00:48 +02:00
Miroslav Talasek
b893993e7b app: add new enums GimpMattingDrawMode and GimpMattingEngine 2013-05-07 23:09:55 +02:00
Michael Natterer
0255a01f95 app: add gegl:checkerboard to <Image>/Filters/Render/Pattern 2013-04-30 19:20:18 +02:00
Michael Natterer
abbe2ecba9 app: build the foreground select tool again, minus the calls to SIOX
the interaction is completely there again, it just doesn't nothing
fancy with the mask :)
2013-04-30 00:04:28 +02:00
Michael Natterer
f6ec4f4af2 app: remove the image map tool overlay before hiding it again
Which means I have given up finding that last bug (for now).
2013-04-28 14:57:57 +02:00
Michael Natterer
2a0472b57e app: don't forward key events to the curves tool graph if the tool isn't active 2013-04-26 00:11:51 +02:00
Michael Natterer
595f52bf09 app: more cleanup in GimpImageMapTool's overlay dialog handling
gimp_image_map_tool_initialize(): clean up adding the overlay.

gimp_image_map_tool_dialog_hide(): hide the overlay before removing it.
2013-04-25 22:46:05 +02:00
Michael Natterer
8230e948a8 app: allow to call gimp_image_map_tool_dialog_hide() multiple times
don't try to remove a GimpOverlayDialog from the canvas twice.
2013-04-25 22:23:32 +02:00
Michael Natterer
325d7541c7 app: always show the tool progress in the center of the canvas
getting rid of one more untransform_viewport().
2013-04-25 09:41:21 +02:00
Michael Natterer
62c5a737fd app: fix conditions for guide and sample point moving/removing
Simply check the transfomred coords against the canvas extents and the
untransformed against the image contents instead of using
untransform_viewport(). The code is easier to read now, and
untransform_viewport() is still broken and can't really be implemented
properly when the canvas is rotated.
2013-04-25 09:30:46 +02:00
Michael Natterer
37d589335f app: consolidate all transform API in gimpdisplayshell-transform.[ch]
Added complete API for zoom/unzoom (scale and scroll) and
rotate/unrotate, with the same set of functions as the existing
transform/untransform. Moved some special case functions to the
namespaces they belong.
2013-04-25 00:29:58 +02:00
Michael Natterer
aea94211b1 app: add an unrotated canvas item group to GimpDisplayShell
and put the software cursor and the tool progress there.
2013-04-24 00:01:01 +02:00
Mikael Magnusson
8cc53bbbdf app: forgot to invert the matrix in corrective mode when transforming the selection. 2013-04-23 17:15:23 +02:00
Michael Natterer
a80795e222 app: remove "GeglRectangle visible" from gimp_image_map_apply()
because we now use a filter and the image projection updates
the visible part only.
2013-04-22 00:29:38 +02:00
Michael Natterer
f1b5012f23 app: fix gimp_draw_tool_on_handle() on rotated views
Unrotate the display coords, then compare rectangles.
2013-04-20 15:30:23 +02:00
Michael Natterer
52b92e740f app: rename gimpdisplayshell-style to gimpcanvas-style
because it doesn't and shouldn't depend on GimpDisplayShell at all.
In the future, it will take its defaults from the canvas' theme.
2013-04-18 16:46:01 +02:00
Michael Natterer
b71ffeca60 app: do more stuff generically in gimp_image_map_tool_initialize()
- reset the config object if it exists
- trigger the first preview of the filter
- remove the same stuff from all subclasses
2013-04-16 23:28:02 +02:00
Michael Natterer
9bb4c3d484 app: pull some GEGL operation logic from subclasses into GimpImageMapTool
- connect to the config object's notify generically and update the preview
- allow to properly exchange the operation at runtime to remove major
  uglyness from GimpOperationTool
- return undo_desc from GimpImageMapTool::get_operation() so we have
  proper strings in the undo history, not always "GEGL operation"
- simplify all get_operation() implementations
2013-04-16 22:06:48 +02:00
Michael Natterer
9994a4d514 app: remove the notify::use-gegl callback from GimpImageMapTool 2013-04-16 20:38:40 +02:00
Michael Natterer
e3b2a54da7 app: add a stock_id to GimpImageMap and use it for its filter
Refactor GimpImageMapTool and GimpOperationTool to set the stock_id,
and to be a bit smarter with the image map's undo string.
2013-04-16 20:32:58 +02:00
Michael Natterer
1e17f0aed1 app: port GimpImageMap to use the new drawable filters
which makes live update more responsive and removes tons of code, but
adds a delay with progress when finally committing the effect.
2013-04-12 14:35:27 +02:00
Michael Natterer
46f74d9f46 app: return GeglBuffer from gimp_image_contiguous_region_foo()
now all intermediate masks should be in "Y float" and avoid all
conversions.
2013-04-09 01:38:24 +02:00
Michael Natterer
71c88aebdc app: add gegl:vignette to Filters -> Decor 2013-03-27 01:35:49 +01:00
Mikael Magnusson
a2e8da357e transformtool: flip cursor if needed 2013-03-24 23:13:56 +01:00
Michael Natterer
a6862af834 app: shorten the labels of the cage tool options by adding newlines
This is an exception because the tool only has three option widgets.
2013-03-24 22:11:20 +01:00
Michael Natterer
cdf2c7ba4b app, menus: add CIE lch noise to the menus 2013-03-09 22:59:13 +01:00
Michael Natterer
c76a23075d app: blacklist some more useless ops in the GEGL tools 2013-03-09 22:23:52 +01:00
Michael Natterer
06a4d2e29f app: have proper titles in the GEGL filter settings import/export dialogs
"Import foo" and "Export foo" were just not good enough...
2013-03-09 20:34:15 +01:00
Michael Natterer
54778783ed app: make a hack in GimpOperationTool slightly worse, but clearer 2013-03-09 20:27:02 +01:00
Michael Natterer
69c897a118 app: fix crash in GEGL tool when an operation specific tool was used before
gimp_image_map_tool_initialize(): add the saved settings combo only if
we have a config object.
2013-03-09 20:16:24 +01:00
Michael Natterer
edec6ac8cc app: add some more gegl ops to the menus (wip) 2013-03-09 18:10:14 +01:00
Michael Natterer
448722c849 app: blacklist some more ops in the GEGL tool, they are in the menus 2013-03-08 17:24:02 +01:00
Michael Natterer
931ea102f8 Bug 693978 - GIMP crashes after changing text preset
Applying a preset overwrites all the tool option's properties, also
temporarily its name. This name change gets auto-synced with the
option's text proxy object which also inherits from GimpObject and has
a name. Make sure we don't queue that name change for being applied to
the text layer's text object, because that code only handles
properties of GimpText itself.
2013-02-16 20:38:15 +01:00
Téo Mazars
f6e64b9ed9 Bug 688068 - Rect selection: "Fixed: Aspect Ratio" doesn't work when...
Use current aspect when creating rectangle tool from a selection.
2013-02-13 00:36:44 +01:00
Téo Mazars
4a5a6ef914 Bug 684330 - Rectangle tool's "fixed size" option is off-by-one
ROUND() is consistent only on positive values, and bad rounding
creates an offset when negative values are involved. Introduce
SIGNED_ROUND() and use it in gimprectangletool.c. It should probably
be used in much more places.
2013-02-13 00:08:39 +01:00
Ville Skyttä
6b0d1038cc Bug 692641 - Various spelling fixes 2013-01-27 18:59:02 +01:00
Michael Natterer
e5112fa540 Bug 690900 - Typo in GIMP UI
Fix typo in gimptransformtool.c
2012-12-30 20:38:37 +01:00
Michael Natterer
593ddb741f Bug 688746 - Select tool Alt+Shift and Alt+Ctrl dragging modifies...
Check for layer groups and locked layers in gimp_selection_tool_start_edit()
and show the usual warning instead of allowing the forbidden operation.
2012-12-14 23:02:56 +01:00
Michael Natterer
908f727f0a Chain up unconditionally in GObject::constructed()
It's supported since GLib 2.28.
2012-11-12 21:51:22 +01:00
Michael Natterer
5efd56c1c8 Bug 679223 - "Rate" in tool options needs translation context
Add translation contexts for "Rate" of airbrush, convolve and smudge.
2012-11-12 01:06:58 +01:00
Michael Natterer
76b05c2afc app: make Tab, Shift+Tab and Escape move the focus back to text editing
when it was in the floating text style editor. While this doesn't fix
anything by itself, it enables fixing text style setting to behave
reasonably when there is no selection.
2012-11-09 22:06:51 +01:00
Michael Natterer
d4933b3052 Bug 674160 - Redesign of "Lock panel"
Apply and heavily modify patch from remyDev which adds "lock position"
to GimpItem, similar to "lock content". Lock position disables all
sorts of translation and transform, from the GUI and the PDB.

Cleaned up some aspects of the lock content code as well because a
second instance of similar code always shows what went wrong the first
time.
2012-11-09 11:17:25 +01:00
Michael Natterer
6a33951aa6 Bug 687851 - Gimp crashes on Colors > Desaturate
Don't install the frame rate limiting draw timeout when resuming a
draw tool that is not active, so accidential timeout installation from
whatever tool dispose code can't happen.
2012-11-07 23:21:13 +01:00
Michael Natterer
eba022f01b Bug 687375 - Text tool: unnecessarily insists on having a layer before working
There is no reason to disallow the text tool from working on a
previously empty image, so allow it.
2012-11-06 22:22:02 +01:00
Michael Natterer
66bd90c9f2 Bug 533590 - Perspective clone of a pattern doesn't apply perspective
Implement perspective cloning from a pattern. This needed quite some
refactoring, so GimpSourceCore would be able call its get_source()
vfunc also for a GimpClone subclass: essentially this commit adds a
new GimpSourceCore::use_source() vfunc that replaces the
source_options->use_source flag hack, and makes sure the graph used in
GimpPerspectiveClone's get_source() impl reads from the pattern
instead the drawable.

This version does not properly tile the pattern yet, so you can only
clone one copy of the pattern (gegl:tile is not quite doing the right
thing, so it's disabled).
2012-11-01 21:39:14 +01:00
Massimo Valentini
9b58e2ba0c Bug 684483 - Text tool: crash after double clicking text
It seems that when the undo action reverts a text -> mark-up change
(or v.v.)  the notifications are inverted, first is emitted the new
value notification and successively the property becoming NULL. The
result is that gimp_text_buffer_set_{text,mark-up} is called last with
NULL, unsetting both text_buffer text and mark-up.

The right way to do it is to always prefer "markup" over "text" if
markup is present, no matter if the notification was for "markup" or
"text".
2012-10-22 15:40:55 +02:00
Michael Natterer
2b3e5ebd78 Bug 686523 - Text tool: text editor not shown on empty text box
gimp_text_tool_options_notify(): always show the editor, also when no
text object exists yet. There was no reason for this limitation.
2012-10-21 23:30:34 +02:00
Michael Natterer
438fc4221e app: remove unused variable in gimp_unified_transform_tool_init() 2012-10-12 22:39:11 +02:00
Michael Natterer
52d933a1cc Bug 663582 - Brush outline is too slow
Even less drawing: let the timeout running if it triggers within the
50ms since the last drawing, so it's reduced to its actual purpose of
updating to the actual cursor position after framerate-limiter skipped
drawing.
2012-10-06 16:39:14 +02:00
Michael Natterer
4218d9342f Bug 663582 - Brush outline is too slow
One more try: merge the spirit of Alexia's patch, but don't disable
the timeout, only make sure the minimum fps is also applied when
drawing is triggered by gimp_draw_tool_resume().
2012-10-06 00:27:49 +02:00
Michael Natterer
db5c952c4e Bug 663582 - Brush outline is too slow
Don't confuse microseconds with milliseconds: the 20 fps interval
is 50000, not 50, sigh.
2012-10-06 00:03:47 +02:00
Michael Natterer
fd4e220c28 Bug 663582 - Brush outline is too slow
Keep around the last drawing time in GimpDrawTool and make sure we
draw at least with a frame rate of around 20 fps, which feels
reasonably non-laggy.
2012-10-04 20:43:58 +02:00
Michael Natterer
303e554ab1 app: remove "gboolean active_layer_only" from gimp_image_crop()
Also a very historic API, it doesn't belong there. Instead, simply
call gimp_item_resize() in GimpCropTool.
2012-09-22 15:08:05 +02:00
Michael Natterer
c1811d6bdf app: gimp_image_crop_auto_shrink() -> gimp_pickable_auto_shrink()
It was in gimpimag-crop only for historic reasons. Clean up API
and code to do simpler and more reasonable stuff.
2012-09-22 14:56:52 +02:00
Mikael Magnusson
da795c1267 gimptransformtool: Restore code that apparently was for the flip tool 2012-09-20 15:18:00 +02:00
Michael Natterer
9b927ba0cd Bug 683791 - Free select tool constraint key
Fix condition that constrains angles to 15°, its bracketing was wrong.
2012-09-14 11:04:21 +02:00
Michael Natterer
2c3a046d83 Bug 683553 - Spinscale scrollvalues in Brushsize are much too smal
Set the step/page increments to 1.0/10.0 for brush size and to 0.1/1.0
for aspect ratio. the previous values were way too small.
2012-09-11 20:28:20 +02:00
Michael Natterer
e546f2b43b Bug 683462 - cropping with rectangular select tool leaves misaligned...
Reset the tool on image changes again, but not if only the active
drawable changes, so keep bug #678890 closed:

Introduce new dirty flag GIMP_DIRTY_ACTIVE_DRAWABLE and set it on all
tools' dirty_mask except for rect select. Check the new flag when
reseting the active tool because of a drawable change.
2012-09-06 23:55:35 +02:00
Mikael Magnusson
0f380eba53 transformtool: actually use the correct index for the angle vector 2012-08-27 15:12:29 +02:00
Mikael Magnusson
6396e83057 transformtool: use new corner and side cursors appropriately considering current transform 2012-08-27 15:07:15 +02:00
Mikael Magnusson
11a9fe33d9 app: another minor cleanup in gimpunifiedtransformtool.c
you missed a spot
2012-08-23 02:16:06 +02:00
Mikael Magnusson
b11a705203 transformtool: rotate handles along with frame 2012-08-22 22:53:59 +02:00
Mikael Magnusson
e83b40982f transformtool: adjust handles a bit
Since the move handle is gone, the pivot can be normal sized and circle again,
also put shear handles at 3/4 rather than 3/5.
2012-08-22 22:49:45 +02:00
Michael Natterer
5d711be340 app: formatting cleanup in gimpunifiedtransformtool.c 2012-08-22 20:45:16 +02:00
Michael Natterer
95584e5548 app: re-format a comment in gimptransformtool.c 2012-08-22 20:41:44 +02:00
Mikael Magnusson
8dfc72dca9 transformtool: Make real_pick_function and real_draw_gui implementations of vfuncs 2012-08-21 20:59:15 +02:00
Michael Natterer
b1acd93f5e Some formatting cleanup in the unified transform tool commits 2012-08-21 19:50:01 +02:00
Mikael Magnusson
08cd798ec6 transformtool: Set the cursor and tool cursor properly on each handle by way of the new cursor_update method 2012-08-20 20:28:21 +02:00
Mikael Magnusson
d789cbff9d transformtool: Fix indent of switch statement 2012-08-20 20:28:19 +02:00
Mikael Magnusson
6af6218c2b transformtool: Remove now unused variables 2012-08-20 16:57:58 +02:00
Mikael Magnusson
4c22ed8128 transformtool: Use the same method for frompivot for shearing as everything else 2012-08-20 16:42:29 +02:00
Mikael Magnusson
3f72695a80 transformtool: kill rotate and move handle, instead rotate when outside frame (move already works inside) 2012-08-20 15:46:48 +02:00
Mikael Magnusson
0f6709d2d0 transformtool: Be a bit more strict about the pivot being inside the transform frame to use it, to protect against it flying away to infinity 2012-08-20 15:46:47 +02:00
Mikael Magnusson
574df2b6db transformtool: We show corrective preview for selections and paths, so why not drawables 2012-08-20 15:46:47 +02:00
Mikael Magnusson
4e57571103 transformtool: Remove some annoying duplication and draw perspective handles differently 2012-08-20 15:46:47 +02:00
Mikael Magnusson
b27c33f13c transformtool: Add back statusbar code (but more helpful) that was deleted when I made pick_function 2012-08-20 15:46:47 +02:00
Mikael Magnusson
c37619ade7 transformtool: Pick move operation anywhere inside polygon 2012-08-20 15:46:47 +02:00
Mikael Magnusson
a0d79634ed transformtool: Add one more rotation handle, in case the point you want to pivot around is close to the first one 2012-08-20 15:46:47 +02:00
Mikael Magnusson
62525e090b transformtool: use GimpFrame + GtkBox to group the options instead of just putting GtkLabel between them 2012-08-20 15:46:46 +02:00
Mikael Magnusson
f84987de73 transformtool: Add the bunch of 8 separate options for 3 things 2012-08-20 15:46:46 +02:00
Mikael Magnusson
03117bdf40 transformtool: Update modifier keys for options, solves problem with perspective frompivot + constrain 2012-08-20 15:46:46 +02:00
Mikael Magnusson
f2099fbb28 transformtool: Check if new transform is convex and don't involve the pivot if it isn't 2012-08-20 15:46:46 +02:00
Mikael Magnusson
501c15f910 transformtool: Add a pick_function method to the TransformTool class and remove some more hack duplication 2012-08-20 15:46:46 +02:00
Mikael Magnusson
293600c579 transformtool: Add a draw_gui method to the TransformTool class and remove some hack duplication 2012-08-20 15:46:46 +02:00
Mikael Magnusson
01142f248d transformtool: some more cleanup + comments 2012-08-20 15:46:45 +02:00
Mikael Magnusson
03d9a75c30 transformtool: Rename p to d because p is a weird name for a delta/diff 2012-08-20 15:46:45 +02:00
Mikael Magnusson
eb65b09ebd transformtool: move assignment of coords to after the logic code, this somehow fixes frompivot perspective 2012-08-20 15:46:45 +02:00
Mikael Magnusson
ed29503f28 transformtool: Deduplicate code, use more vector representations, fix style and warnings 2012-08-20 15:46:45 +02:00
Mikael Magnusson
70671f2967 transformtool: Factor out getpivotdelta() function 2012-08-20 15:46:45 +02:00
Mikael Magnusson
bad3c0d86c transformtool: Add frompivot for perspective handles too 2012-08-20 15:46:45 +02:00
Mikael Magnusson
9be0d2b029 transformtool: Add option for locking pivot to canvas, add code to transform the pivot along with all transformations 2012-08-20 15:46:24 +02:00
Mikael Magnusson
52dd46f9d3 transformtool: Copy the corner scale non-aspect frompivot code to side scale 2012-08-20 15:41:55 +02:00
Mikael Magnusson
76f23aa8a0 transformtool: Use better method for keepaspect side scaling 2012-08-20 15:41:55 +02:00
Mikael Magnusson
051775eb0d transformtool: Fix frompivot for cornerscale, only problem is the handle doesn't end up at mouse cursor 2012-08-20 15:41:55 +02:00
Mikael Magnusson
615b5fabfd transformtool: Add the five options instead of just two 2012-08-20 15:41:55 +02:00
Mikael Magnusson
6dac9e84f9 transformtool: Show an incredibly helpful message in the statusbar when a handle is hovered over 2012-08-20 15:41:55 +02:00
Mikael Magnusson
5cfa57ae87 transformtool: how to draw in screen coords 2012-08-20 15:41:54 +02:00
Mikael Magnusson
b0dbaaae54 transformtool: Add todo about pivot point
Move pivot with frame, needs to do so for all operations
2012-08-20 15:41:54 +02:00
Mikael Magnusson
be3f42c401 transformtool: implement aspect constraint for scaling via side handle 2012-08-20 15:41:54 +02:00
Mikael Magnusson
e762764a1d transformtool: Make basic scale op via side handle behave as spec, no constrain or frompivot 2012-08-20 15:41:54 +02:00
Mikael Magnusson
3367a415c4 transformtool: corner scale: use full transform machinery to keep pivot constant position, missing some offset maybe 2012-08-20 15:41:54 +02:00
Mikael Magnusson
d5220e7d42 transformtool: nonworking naive frompivot for corner scale
This just scales the distance to the pivot from the handle in x and y
separately, which turns out to only work sometimes.
2012-08-20 15:41:54 +02:00
Mikael Magnusson
c5b4beff65 transformtool: Make corner scale op behave as spec, no frompivot 2012-08-20 15:41:53 +02:00
Mikael Magnusson
948cf1801c transformtool: implement fromcenter constraint for shearing (old spec)
This doesn't keep the pivot in place, it merely moves the opposite edge
by the same amount (but in the opposite direction).
2012-08-20 15:41:53 +02:00
Mikael Magnusson
9a58e878be transformtool: Make shear op behave as spec, no frompivot 2012-08-20 15:41:53 +02:00
Mikael Magnusson
5ed30efc49 transformtool: remove unneeded old stuff, cleanup 2012-08-20 15:41:53 +02:00
Mikael Magnusson
ce2c959408 transformtool: Make perspective op behave as spec 2012-08-20 15:41:53 +02:00
Mikael Magnusson
a532c77bca transformtool: Make rotation axis behave as spec 2012-08-20 15:41:33 +02:00
Mikael Magnusson
81cb334d94 transformtool: Make rotate op behave as spec 2012-08-20 15:22:22 +02:00
Mikael Magnusson
dd470c9259 transformtool: Make move op behave as spec 2012-08-20 15:22:22 +02:00
Mikael Magnusson
003ccf2aec transformtool: Enable hit detection for new handles 2012-08-20 15:22:22 +02:00
Mikael Magnusson
a8a8450b6e transformtool: Add temporary new handles
put perspective handles on the outside instead (if you invert the frame,
they'll switch place with the scale handles, oh well)
2012-08-20 15:22:22 +02:00
Mikael Magnusson
9e330e432b transformtool: temp hack to fiddle with drawing interface 2012-08-20 15:22:22 +02:00
Mikael Magnusson
c4143ff209 transformtool: Remove shift-clicking to accept transform since shift is used as a modifier 2012-08-20 15:22:22 +02:00
Mikael Magnusson
362afb122a transformtool: Try to straighten out modifiers 2012-08-20 15:22:21 +02:00
Mikael Magnusson
2967e4fbfd transformtool: remove unused function shearvector() 2012-08-20 15:22:21 +02:00
Mikael Magnusson
99f9d4d219 transformtool: add old "new" unified transformation tool
This is the proof of concept code I wrote before gsoc, with very naive
behaviour and simple interface.
2012-08-20 15:22:21 +02:00
Mikael Magnusson
f5b08f33aa transformtool: Infinite undo
add undo and redo buttons, can undo all interactions. The reset button
is equivalent to undoing all operations and lets you press redo to get
back to before you reset. Doing something after undo will of course
clear all redo events.
2012-08-20 15:22:21 +02:00
Mikael Magnusson
c883c761df transformtool: calculate center handle position correctly, add pivot handle
and use pivot handle in rotatetool so it works as before.
2012-08-20 15:22:21 +02:00
Mikael Magnusson
7baaaa4867 app: remove useless function call in gimp_tool_motion 2012-08-20 15:22:20 +02:00
Michael Natterer
47c987b09e Bug 676270 - cppcheck report
Fix a couple of harmless stuff pointed out in the report, and one
real bug: gimp_plug_in_close() was killing each process 10 times
on windows.
2012-08-04 03:20:36 +02:00
Michael Natterer
078128bb09 Bug 678890 - Selection box handles do not respond after changing layer
Make sure that temporarily setting/unsetting tool->control's "preserve
tool across image changes" does not mess up the default value:

Introduce gimp_tool_control_push/pop_preserve() which restores the old
state automatically, and use it in all tools, instead of saying
set_preserve(TRUE/FALSE) around image changes.
2012-07-26 18:17:01 +02:00
Massimo Valentini
c743a4fc0a app: don't pass a NULL widget to gtk_widget_event
<Alt>C C <Ctrl>1 <ESC> used to print:

(gimp-2.8:1): Gtk-CRITICAL **: IA__gtk_widget_event:
                assertion `GTK_IS_WIDGET (widget)' failed
2012-07-05 18:08:01 +02:00
Michael Natterer
3de48e6570 app: experiment with different UI value ranges for different image precisions
in the levels tool. This clearly needs a generic solution for the many
places that need such changes.
2012-06-07 21:47:07 +02:00
Michael Natterer
ccae8cffc3 app: add color-reduction to the colors menu 2012-05-23 12:56:24 +02:00
Michael Natterer
7d280abd9a Bug 676585 - Gimp crashes when writing in Arabic and clicking right arrow
Check for pango_layout_move_cursor_visually() returning a new index of
G_MAXINT, which indicates that we moved beyond the end of the layout,
and do nothing instead of trying to access the memory there.
2012-05-23 09:44:51 +02:00
Michael Natterer
513e3b6a78 app: disable the foreground select tool properly: #if 0 everything
so it's not in the way of further cruft removal.
2012-05-21 03:09:08 +02:00
Michael Natterer
d93b7e5e54 app: the TileManager in gimptransformtoolundo.h needs porting 2012-05-21 02:27:03 +02:00
Michael Natterer
d80182cf25 app: disable the IScissors tool, if you want it back, please go ahead 2012-05-20 20:38:12 +02:00
Michael Natterer
e5fc441433 app: GimpIscissorsTool: move one-time initializations to class_init() 2012-05-20 19:19:12 +02:00
Michael Natterer
2d882dd64f Bug 676279 - Ctrl or Shift causes selection tools to reset...
Make sure to not override the logic that separates the tool option's
selection mode from the one determined by modifiers, by blindly
calling gimp_modifiers_to_channel_op(state) on a zero state.
2012-05-17 23:34:22 +02:00
Michael Natterer
c4142d0574 app: change the value to render in the GimpScanConvert API to a 0..1 double 2012-05-13 23:13:53 +02:00
Alexandre Prokoudine
eb48617a38 Replaced old Difference of Gaussians, Laplace and Sobel filters with new GEGL operations 2012-05-13 06:41:19 +04:00
Alexandre Prokoudine
ac85c84a0f Replaced old Ripple and Lens Distortion filters with new GEGL operations 2012-05-13 06:15:24 +04:00
Alexandre Prokoudine
20ae491b21 Replaced the old Unsharp Mask filter with the new GEGL operation 2012-05-13 05:38:24 +04:00
Michael Muré
bec5a7e805 cage tool: fix handle added in the wrong side of the cage
This happened when:
1) cage still open
2) clicking on the edge between the first and the last handle
2012-05-11 12:34:53 +09:00
Michael Muré
d9ba8b81da Bug 675825 - (cage) simply using cage transform tool makes gimp to crash.
Just check if there is enough handles before closing
2012-05-11 12:02:58 +09:00
Michael Natterer
7101ee191a app: move all GEGL operations to new directory app/operations/ 2012-05-10 21:22:44 +02:00
Michael Natterer
69893e4f72 app: remove GimpPickable::get_tiles()
and change some legacy places to get their tiles from the buffer
returned by GimpPickable::get_buffer().
2012-05-06 01:01:54 +02:00
Michael Natterer
e7e8c9ef0a app: don't call gimp_image_flush() when cancelling GimpImageMapTool
because the tool might be cancelled from some other place opening an
undo group, so flushing the image would update menus and whatnot while
that other operation is running, with unforeseeable side
effects. Also, flusing the image here is not needed because we didn't
change anything in the image. Instead, make sure manually that the
display is updated correctly after restoring GimpImageMapTool's
temporary editing.
2012-05-05 21:47:17 +02:00
Michael Natterer
d198c9d85c app: don't use g_str_has_prefix() for blacklisting GEGL ops
so we don't accidentially blacklist things.
2012-05-05 20:49:27 +02:00
Michael Natterer
5ea928b3df app: use our gtk_box_new() wrapper instead of gtk_vbox_new() 2012-05-04 17:23:17 +02:00
Michael Natterer
c1259daa54 app: blacklist gegl:sdl-display in the GEGL tool 2012-05-03 15:06:45 +02:00
Michael Natterer
84745b48e8 app: add a color button and picker to the colorize tool dialog 2012-05-03 15:02:34 +02:00
Michael Natterer
cf43a09626 app: clamp the return value of gimp_operation_levels_map_input()
before putting it into 8 bit for rendering UI stuff, because the
function itself doesn't clamp any longer.
2012-05-02 17:51:23 +02:00
Michael Natterer
1ea3bb827e app: add a dedicated menu entry for gegl:color-temperature 2012-05-02 17:51:23 +02:00
Michael Natterer
3db9deed1c app: add color pickers to all GEGL tool color properties
The way to make gimp_prop_table_new() create tool pickers is
disgusting, but works.
2012-05-02 17:51:22 +02:00
Michael Natterer
50439e812e app: move GimpLevelTool's color picking stuff into GimpImageMapTool
so all subclasses can use it.
2012-05-02 17:51:22 +02:00
Michael Natterer
662bba9fb3 app: generalize some Babl format hardcoding in GimpLevelsTool 2012-05-02 17:51:22 +02:00
Michael Natterer
981f039053 app: don't disable the blend tool on indexed drawables 2012-05-02 17:51:21 +02:00
Michael Natterer
fa0faf4254 app: replace the polar-coords plug-in by gegl:polar-coordinates 2012-05-02 17:51:19 +02:00
Michael Natterer
c57b4f0fa3 app: port by color select and fuzzy select to float
so it works nicely on all precisions, disable HSV color matching for
now, need to decide what to do with it.
2012-05-02 17:51:18 +02:00
Michael Natterer
1bbd3d40a8 app: make the GimpTempBuf struct private and add accessors 2012-05-02 17:51:12 +02:00
Michael Natterer
7d9cd6a413 app: don't hardcode "Y u8" when checking whether to clip transformed buffers
instead, check if the format has alpha.
2012-05-02 17:51:08 +02:00
Michael Natterer
85bd6b0dd9 app: pass a format, not bpp, to gimp_viewable_get_dummy_pixbuf()
and add tons of <gegl.h> includes.
2012-05-02 17:51:08 +02:00
Michael Natterer
3e9fdf1815 app: change GimpBoundary to find the boundary a float component
Require passing in a Babl format that will extract the float component
the algorithm should run on.
2012-05-02 17:51:07 +02:00
Michael Natterer
3ea0e3f090 app: return double not int from GimpPickable::get_opacity_at()
and fix GimpLayer's impl to honor the mask also for layers without
alpha.
2012-05-02 17:51:07 +02:00
Michael Natterer
ca6323f382 app: fix signal signature of GimpColorTool::picked()
A Babl format is not of GIMP_TYPE_IMAGE_TYPE, this would have horribly
crashed on 64bit, I guess...
2012-05-02 17:51:02 +02:00
Michael Natterer
bdf6b48138 app: move GimpTempBuf from base/ to core/
and forget about include policy in base/, it's scheduled for removal
anyway.
2012-05-02 17:51:01 +02:00
Michael Natterer
dccb909009 app: make GimpTempBuf reference counted
and remove the "take_ownership" parameter from
gimp_temp_buf_create_buffer(), simply always ref the buf.
2012-05-02 17:51:00 +02:00
Michael Natterer
d5d8e36d21 app: gimp_-namespace all GimpTempBuf functions 2012-05-02 17:51:00 +02:00
Michael Natterer
42a5f01be3 app: rename TempBuf to GimpTempBuf 2012-05-02 17:51:00 +02:00
Michael Natterer
9285529f9b app: silence compiler warning in GimpBucketFillTool 2012-05-02 17:50:59 +02:00
Michael Natterer
7441a1f6f7 app: turn the TempBuf's "bytes" into "format" and port everything to it 2012-05-02 17:50:59 +02:00
Michael Natterer
d743bae6a7 app: remove temp_buf_resize()
and fix its only user by simply reallocating the buf.
2012-05-02 17:50:58 +02:00
Mikael Magnusson
3406bf0b69 gimpbucketfilltool: Fix switch block always falling through to pattern fill 2012-05-02 17:50:54 +02:00
Michael Natterer
aebf55d799 app: blacklist gegl:threshold 2012-05-02 17:50:52 +02:00
Michael Natterer
64cd825796 app: blacklist all ops that are in gimp menus now, and some useless ones 2012-05-02 17:50:52 +02:00
Michael Natterer
797e622734 app: remove obsolete include 2012-05-02 17:50:52 +02:00
Michael Natterer
75f2bc1aac app: resurrect the operation tool's title 2012-05-02 17:50:49 +02:00
Michael Natterer
cf37aa7dba app: add a GimpSettingsBox to all GEGL operation filter dialogs
so they store all recently used settings, and explicitly added ones,
just like the color tools.
2012-05-02 17:50:49 +02:00
Michael Natterer
9031cdc645 app: add a ton of parameters to GimpImageMapTool::get_settings_ui()
so they can be passed in instead of being looked up in the class
struct, which enables freely configuring the settings stuff from
subclasses, such as soon GimpOperationTool.
2012-05-02 17:50:48 +02:00
Øyvind Kolås
818739a0e3 app: remove superfluous frame and label from GEGL tool 2012-05-02 17:50:47 +02:00
Øyvind Kolås
ebd419d4d5 app: use a gamma of 1.7 for brush radius slider 2012-05-02 17:50:45 +02:00
Michael Natterer
8bc6f1ee09 app: add parent_type parameter to gimp_gegl_get_config_proxy()
and derive from that type. Use GimpImageMapConfig as base class for
GimpOperationTool's config.
2012-05-02 17:50:42 +02:00
Michael Natterer
e8cc9d1bf5 app: turn gimp_image_map_tool_add_settings_gui() into a virtual function
and change it to return the settings ui, not add it.
2012-05-02 17:50:42 +02:00