Commit Graph

43479 Commits

Author SHA1 Message Date
Ell
b1c9173b1f app: use gimp_gegl_node_get_key() in GimpFilterTool
... instead of doing the same thing manually.  This was supposed
to be part of the previous commits.

(cherry picked from commit 10a528ed2f)
2020-01-17 16:45:22 +02:00
Ell
9ee4091738 pdb: add missing change to last commit 2020-01-17 12:21:34 +02:00
Ell
b55afe8703 Issue #4366 - Color-to-alpha unnecessarily grayed out for grayscale images
Don't disable color-to-alpha for grayscale drawable, since the
operation is applicable to grayscale images (in particular, it
doesn't add color where there was none), and since we no longer
distinguish between layers and channels according to the drawable
format when updating the filters actions.
2020-01-17 12:12:57 +02:00
Ell
75d5eb7800 Issue #1975 - Color to alpha now requires an alpha-channel ...
... (used to add one automatically)

In GimpFilterTool and gimp_drawable_apply_operation(), use
gimp_drawable_filter_set_add_alpha() to add an alpha channel when
applying an operation that specifies "needs-alpha" to a drawable
that can have alpha.

Don't disable gegl:color-to-alpha (which has "needs-alpha") when
the drawable doesn't have an alpha channel, if one can be added.
2020-01-17 12:12:57 +02:00
Ell
868a64c0f8 app: in GimpFilterTool, consolidate drawable-filter option setup
In GimpFilterTool, move all the drawable-filter option setup to a
new gimp_filter_tool_update_filter() function, and call it whenever
the drawable-filter's options need to be updated.  This avoids
duplicating logic in various places.
2020-01-17 12:12:57 +02:00
Ell
8a54c78e6b app: add gimp_gegl_node_get_key()
... which gets an operation-class key for the operation associated
with the node, if any.
2020-01-17 12:12:57 +02:00
Ell
29a02b2949 app: add GimpDrawable::supports_alpha() vfunc
Add a new GimpDrawable::supports_alpha() virtual function, and a
corresponding gimp_drawable_supports_alpha() function, which
determine if the drawable supports an alpha channel.  The default
implementation returns FALSE, and GimpLayer overrides it to return
TRUE.
2020-01-17 12:12:57 +02:00
Ell
6c0d20c9e6 app: silence warning in gimp_transform_resize_crop()
The crop-to-result and crop-with-aspect transform-boundary
algorithms seem to consistently fail in some cases, and spit out a
warning, which can be too verbose if it triggers the debug dialog.

Demote the warning to a g_printerr(), with an eye to just dropping
these algorithms altogether.

(cherry picked from commit 0103fe2c19)
2020-01-17 00:29:46 +02:00
c696cc0a10 Update NEWS to match recent changes 2020-01-16 20:35:24 +00:00
Ell
f2715936cc app: add "Synchronous preview" option to transform tools
Add a "Synchronous preview" option to the transform-grid tools,
which renders the composited preview synchronously.  This reduces
the lag for painting the preview, but can harm responsiveness for
bigger images, where rendering the preview is slow.

This is mostly an experimental option for now; it will become more
interesting once we have mipmap rendering.

(cherry picked from commit 52cd27f0d3)
2020-01-16 11:41:17 +02:00
Ell
456ede52e8 app: in GimpTileHandlerValidate, fix tile-data pointer for negative coords
In gimp_tile_handler_validate_validate_tile(), when validating a
partial tile with negative coordinates, make sure to adjust the
result of the modulo when calculating the tile-realtive coordinates
so that they're non-negative, to fix the tile-data pointer offset.

(cherry picked from commit d39822bcd7)
2020-01-16 01:58:58 +02:00
Ell
0077eabce5 app: add "Composited preview" option to transform tools
Add a "Composited preview" option to all transform-grid tools,
which displays the transform preview as part of the image
composition (i.e., as it would actually look when applying the
transformation, keeping the layer at the right position in the
stack, and with the right layer mode), instead of using an overlay.

This option is off by default, since it's generally slower to
render than an overlay, due to the lack of mipmap rendering.  We're
also still using an overlay when transfoming a selection, and not a
whole layer.
2020-01-16 00:35:06 +02:00
Ell
c4a621d1dc app: freeze drawable preview in transform tools
In GimpTransformGridTool, when transforming a drawable, freeze the
drawable's preview while the tool is active, so that its ancestors'
previews don't get unnecessarily updated in response to hiding it.
2020-01-16 00:35:06 +02:00
Ell
54a95ab75b libgimpmath: add gimp_matrix3_equal()
... which compares two matrices.
2020-01-16 00:35:06 +02:00
Ell
6d7e18ff8a app: add gimp_drawable_filter_set_override_constraints()
In GimpDrawableFilter, add a
gimp_drawable_filter_set_override_constraints() function, which
allows bypassing certain constraints applied to the filter, based
on the drawable type and state.

Yes, this is a bit of a hack, added mostly as a quick-and-dirty way
to allow us to add filters to layer masks that affect their
bounding box, in preparation for composited transform previews.
2020-01-16 00:35:06 +02:00
Ell
1485e1d143 app: add gimp_drawable_filter_set_add_alpha()
Add an optional "format" parameter to gimp_drawable_merge_filter(),
which specifies the format to use for the output, possibly changing
the drawable's format.

In GimpDrawableFilter, add a gimp_drawable_filter_set_add_alpha()
function, which allows the filter to add an alpha channel to the
drawable when committed (by passing an appropriate format to
gimp_drawable_merge_filter()).
2020-01-16 00:35:06 +02:00
Ell
41ca26523c app: calculate drawable bounding box according to graph by default
Change the default implementation of
GimpDrawable::get_bounding_box() to return the drawable source
node's bounding box, instead of the drawable's item bounds.  This
allows filters to affect the size of all drawables, including, in
particular, layer masks.

Change GimpLayer's implementation of get_bounding_box() to return
the intersection of the layer's own bounding box, and the layer
mask's bounding box (if it has one), and update the layer's
bounding box when the mask is enabled/disabled, or when its
bounding box changes.
2020-01-16 00:35:06 +02:00
Ell
a2654ef7ce app: implement GimpPickable::flush in GimpGroupLayer
... by synchronously flushing the group's projection.  This is
necessary for pass-through groups, since their projection is
normally flushed asynchronously.

(cherry picked from commit 7f84f10154)
2020-01-15 22:05:35 +02:00
Ell
e409f301fe app: handle GimpTileHandlerValidate::invalidated in gimp:buffer-source-validate
In gimp:buffer-source-validate, invalidate the node in response to
GimpTileHandlerValidate::invalidated, added in the previous commit,
in addition to GeglBuffer::changed.

(cherry picked from commit bb8ee0e686)
2020-01-15 21:50:21 +02:00
Ell
0a93f5609e app: add GimpTileHandlerValidate::invalidated signal
Add a new GimpTileHandlerValidate::invalidated signal, which is
emitted when a region of the buffer is invalidated.  This would
allow us to properly invalidate the graph in response; this
normally happens in response to GeglBuffer::changed, but this
signal is not emitted when a region is merely invalidated.

(cherry picked from commit 3ea391602e)
2020-01-15 21:50:20 +02:00
Ell
537ae20fa0 app: allow calling gimp_tile_handler_validate_validate() with a NULL rect
... and validate the entire buffer.

(cherry picked from commit ba6040bbcd)
2020-01-15 21:50:20 +02:00
df850fa394 Return FALSE on gimp_osx_focus_window to avoid endless loop
(cherry picked from commit 3e78c674d8)
2020-01-15 17:44:53 +01:00
Ell
628833426a libgimpmath: add version annotations to new matrix functions 2020-01-15 18:25:06 +02:00
Ell
4a4999082a icons: fix PNG 3D-transform icons in makefile 2020-01-15 18:15:31 +02:00
3f7bb5b934 Update Spanish translation 2020-01-15 15:01:49 +00:00
ef87fe9497 Update Japanese translation 2020-01-13 14:22:14 +00:00
676b8a77fe Update Polish translation 2020-01-12 19:28:55 +01:00
5b60aab22a Update Japanese translation 2020-01-12 16:15:03 +00:00
7a0c04b9f1 Update Japanese translation 2020-01-12 16:07:27 +00:00
a990b3f878 Update Russian translation 2020-01-12 13:03:50 +03:00
66b16949a6 Add macOS support for the GIMP dashboard 2020-01-12 07:35:05 +00:00
ec10b37421 Issue #4484: Add reflection option for mandala symmetry
(cherry picked from commit 36dd48aea6)
2020-01-11 23:57:25 +01:00
bed9294c97 Update Japanese translation 2020-01-11 16:21:33 +00:00
c315e32617 Update Japanese translation 2020-01-11 16:13:50 +00:00
Ell
e884af8f42 app: clip transform-tools preview according to clipping mode
Add a "clip" property to GimpCanvasTransformPreview, specifying the
transform's clipping mode, and clip the preview accordingly.

In GimpTransformGridTool, sync the tool's clipping mode with the
preview's clipping mode.

(cherry picked from commit 7b2e6b7595)
2020-01-11 17:13:11 +02:00
Ell
41a8be5b2a app: fix spacing in gimptooltransform3dgrid.c
(cherry picked from commit d79ef34f87)
2020-01-10 23:21:41 +02:00
Ell
87d3590054 app: add unified interaction mode to the 3D Transform tool
Add a "Unified interaction" option to the 3D Transform tool, and a
corresponding "unified" property to GimpToolTransform3DGrid.  When
active, all three interaction modes of the grid (camera, move, and
rotate) are available simultaneously, regardless of the active
dialog page.  In this mode, the inner and outer regions of the item
are used for moving and rotation, respectively, and the vanishing-
point is controlled through through a handle.

(cherry picked from commit 30132fc2da)
2020-01-10 23:21:41 +02:00
Ell
c4d0c0bd6d app: in 3D Transform tool, fix rotation direction when rotating arouns local Z axis
In GimpToolTransform3DGrid, fix the test for determining which side
of the plane is facing the viewer, affecting the direction of
rotation when rotating around the local Z axis.

(cherry picked from commit bcaaa453c4)
2020-01-10 22:18:09 +02:00
Ell
8143564627 app: improve placement of new tools with existing toolrc
When ordering tools according to an existing toolrc file (which
is always present in a pre-existing profile), preserve the default
placement of newly-added tools, instead of always adding them to
the bottom of the list.

(cherry picked from commit 58d04375c9)
2020-01-10 18:45:02 +02:00
0418bcc134 Update Turkish translation 2020-01-10 15:53:31 +00:00
e59d8ca75c Move the comment to match the function it explains 2020-01-10 14:56:33 +00:00
eb4b8fbd05 Move macos menu init to the gui related code and reparent it with a main window.
Closes #1258
2020-01-10 11:03:01 +01:00
7acebe298b NEWS: vastly better text for YUV 2020-01-10 11:57:28 +03:00
6d3c742b36 Update NEWS some more 2020-01-10 11:51:30 +03:00
661bab3f25 Update NEWS 2020-01-10 11:47:37 +03:00
2c785267ee Update Russian translation 2020-01-10 10:07:36 +03:00
46ee2d8438 Update Russian translation 2020-01-10 10:07:36 +03:00
Ell
4d5ea7fd95 Issue #4354 - When using color to fade dynamics and gradient with transparency ...
... brush does not have transparency

In the PAINT_MASK_TO_COMP_MASK paintcore-loops algorithm, used when
painting incrementally, multiply the paint mask values by the paint
opacity.  Previously, the paint opacity was ignored, breaking
various dynamics affecting the opacity.

(cherry picked from commit 9fe33702fb)
2020-01-09 22:36:45 +02:00
Ell
67b0279091 app: don't show context menu in compact spin scale without focus
Always enter relative adjustment mode when right-clicking an
unfocused compact GimpSpinScale, instead of showing the context
menu, since it otherwise leaves little room to enter relative mode
in narrow spin scales.  The context menu can still be activated for
focused spin scales.
2020-01-09 17:31:33 +02:00
d714508d8d Update Japanese translation 2020-01-09 15:03:13 +00:00