Commit Graph

35 Commits

Author SHA1 Message Date
5f700549e7 Change the license URL from http://www.gnu.org/licenses/ to https:// 2018-07-11 23:29:46 +02:00
Ell
e1b1611ec4 app: add crop_input parameter to gimp_gegl_apply_operation()
Add a crop_input parameter to gimp_gegl_apply_[cached_]operation().
When TRUE, the functions crop the op's input to the destination
rect.  This is particularly useful for functions that process the
entire input in one go (by means of get_cached_region()).  See the
next commit.

Pass crop_input = FALSE at all call sites for now, to keep the
current behavior.
2018-03-22 13:46:28 -04:00
0cb3e75f79 app: use a lot of g_clear_object() and g_clear_pointer()
More than 2000 lines of code less in app/, instead of

if (instance->member)
  {
    g_object_unref/g_free/g_whatever (instance->member);
    instance->member = NULL;
  }

we now simply use

g_clear_object/pointer (&instance->member);
2017-07-15 18:42:44 +02:00
ef294f4a54 app: clean up how tools are COMMITed and HALTed
Call HALT generically in gimp_tool_control() after calling COMMIT, and
remove all hacks in tools that call both COMMIT and HALT or call
halt() from commit().

Some tools interact with their subclasses (e.g. filter tool and
operation tool), and it's essential that COMMIT runs through the
entire class hierarchy before HALT.

Probably breaks something, please test.
2017-07-09 16:25:42 +02:00
546bbe1e14 app: add a transform matrix to GimpCanvasPolygon and all API using it 2017-06-19 21:53:49 +02:00
91e861adcc libgimpwidgets, *: deprecating stock IDs for good, part one...
Remove all stock items added since 2.8, restore accidentially removed
ones, and rename the newly added GIMP_STOCK_* defines to GIMP_ICON_*.

(will move to having GIMP_ICON_* defines instead of magic hardcoded
strings for all icons).
2017-02-28 19:31:27 +01:00
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
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
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
06797982ba app: fix crash and cleanup in gimp_n_point_deformation_tool_key_press() 2015-03-01 20:30:17 +01:00
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
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
8a56234c9a app: npd-tool: let GEGL NPD operation destroy the model 2015-02-27 20:21:52 +01:00
415d7f2781 app: npd-tool: remove option to pause the deformation process 2015-02-27 20:21:52 +01:00
129c826d49 app: npd-tool: draw lattice using GimpDrawTool's functions 2015-02-27 20:21:52 +01:00
f80b126563 app: npd-tool: fix tool's options 2015-02-27 20:21:52 +01:00
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
10255eddbb app: npd-tool: add option to apply or cancel the deformation 2015-02-27 20:21:52 +01:00
c4e12fdd7c app: npd-tool: use canvas buffer preview 2015-02-27 20:21:52 +01:00
c1f8784ae3 app: npd-tool: deal with drawable's offset 2015-02-27 20:21:51 +01:00
b6b1d3c27a app: npd-tool: add option to pause/unpause deformation process 2015-02-27 20:21:51 +01:00
8fcf1e0015 app: npd-tool: update tool's start function 2015-02-27 20:21:51 +01:00
4af9bd5981 app: npd-tool: deformation runs in its own thread 2015-02-27 20:21:51 +01:00
2654fadc6c app: npd-tool: scale radius of a control point according to display shell's scale 2015-02-27 20:21:51 +01:00
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
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
ffecedf223 app: npd-tool: add option to remove selected control points 2015-02-27 20:21:51 +01:00
80adf02de8 app: npd-tool: add rubber band selection 2015-02-27 20:21:51 +01:00
6ea27ea690 app: npd-tool: add option to show mesh 2015-02-27 20:21:51 +01:00
b1059d9461 app: npd-tool: add provisional tool's options 2015-02-27 20:21:51 +01:00
b4ae7c7f61 app: npd-tool: display cursor and cursor modifiers 2015-02-27 20:21:51 +01:00
fe193f5d57 app: npd-tool: move (multi)selected control points 2015-02-27 20:21:51 +01:00
433194ee20 app: npd-tool: remove last added control point using backspace 2015-02-27 20:21:51 +01:00
1a0c8d5cb2 NPD tool uses GEGL NPD operation 2015-02-27 20:21:51 +01:00
f15a7bc71d app: add NPD tool basics 2015-02-27 20:21:51 +01:00