Commit Graph

40462 Commits

Author SHA1 Message Date
Michael Natterer 233ac80de1 script-fu: port all scripts to the new gimp-drawable-edit functions 2018-04-16 20:12:12 +02:00
Michael Natterer 90ef8b123c libgimp: properly sort gimp.defs 2018-04-16 16:13:46 +02:00
Ell ddfc7715cb app: make the airbrush tool thread-safe w.r.t. paint thread
GimpAirbrush currently performs painting and flushes the image on
its own during the airbrush timeout.  This is unsafe w.r.t. the
paint thread, since the timeout is run on the main thread, while
paint commands should run on the paint thread.

Add a "timeout" signal to GimpAirbrush, and simply emit this signal
during the airbrush timeout, rather than actually painting.

Connect to this signal in GimpAirbrushTool, and use
gimppaintool-paint to perform the actual painting, in a thread-safe
manner (see the previous commit.)
2018-04-16 09:56:39 -04:00
Ell e02a339e01 app: reorganize gimppainttool-paint, to allow use by subclasses
We'd like subclasses of GimpPaintTool to be able to issue paint
commands to the tool's paint-core (in particular, see the next
commit.)  Since paint commands should be executed on the paint
thread, the subclasses must not call the paint-core functions
directly, but should rather let gimppainttool-paint issue the
commands on their behalf.

Reorgainze gimppainttool-paint to make it usable for this purpose
by subclasses.  In particular, add
gimp_paint_tool_paint_core_paint() and
gimp_paint_tool_paint_core_interpolate(), which call the
corresponding paint-core functions on the paint thread.

Additionally, rename the {start,end,flush}_paint() virtual
functions of GimpPaintTool to paint_{start,end,flush}(), and rename
gimp_paint_tool_is_painting() to gimp_paint_tool_paint_is_active(),
so that all the gimppainttool-paint-related stuff are grouped under
the same namespace.
2018-04-16 09:56:39 -04:00
Michael Natterer 3f4995d3d7 pdb: add procedures to set the built-in gradients
gimp-context-set-gradient-fg-bg-rgb
gimp-context-set-gradient-fg-bg-hsv-cw
gimp-context-set-gradient-fg-bg-hsv-ccw
gimp-context-set-gradient-fg-transparent
2018-04-16 11:42:46 +02:00
Jehan 92a8978064 data: re-add 3 brushes of very questionable origin, but as "obsolete".
So I discover the concept of obsolete data in GIMP where some data can
be apparently unavailable in the GUI, but still selectable by script.
This somehow reverts commit 26cb87aa2d
then moves the brushes into the obsolete section instead of simple
deletion. This way, any script using the said brushes won't break at
least.

We will definitely remove the brushes for 3.0, but for now it's better
to keep scripts as compatible as possible.
2018-04-16 10:48:10 +02:00
Jehan 64bab848c3 NEWS, devel-docs: next release is RC2 + some fixes in release howto. 2018-04-16 09:13:37 +02:00
Sebastian Rasmussen d3124d980a Update Swedish translation 2018-04-16 07:11:27 +00:00
Michael Natterer 410e55c40c pdb: never pass bogus supersample values to gimp_drawable_gradient()
even when supersampling is not enabled, or we will get warnings about
out-of-range property values.
2018-04-16 01:18:05 +02:00
Marco Ciampa 055e61f065 Updated Italian translation 2018-04-15 17:53:37 +02:00
Marco Ciampa c30239c912 Updated Italian translation 2018-04-15 17:52:05 +02:00
Marco Ciampa bba7130cc2 Updated Italian translation 2018-04-15 17:50:36 +02:00
Alexandre Prokoudine dbf57b4494 Update Russian translation 2018-04-15 17:54:48 +03:00
Michael Natterer 5ee67deea5 pdb: deprecate all non-clipboard functions in the "edit" group
Still have to port script-fu scripts...
2018-04-15 16:39:59 +02:00
Michael Natterer 1305926f38 pdb: forgot to add drawable_edit.pdb 2018-04-15 16:15:58 +02:00
Tobias Ellinghaus c50449670b
Fix build with vector icons enabled
The invert-svg tool was never built so generating the Symbolic-Inverted
icons failed. Thanks Ell for the hint how to fix this.
2018-04-15 16:10:04 +02:00
Michael Natterer ef3edece9b pdb: improve docs of deprecated functions
Don't unconditionally overwrite all the proc's description, author
etc.  Instead, try to preserve them and append the "Deprecated" notes
to the help texts and generated comments.

Only affects one procedure because we killed the meta info of all
other deprecated procs so far, but now we don't have to do that any
longer.
2018-04-15 16:06:00 +02:00
Michael Natterer 50536e1c38 Bug 795230 - Rename Blend tool and provide PDB compatibility
Add new PDB group "drawable_edit" which has all procedures from the
"edit" group which are not cut/copy/paste.

The new group's procedures don't have opacity, paint_mode
etc. arguments but take them from the context instead. Unlike the old
gimp-edit-fill, gimp-drawable-edit-fill now uses the context's opacity
and paint_mode.

The new gimp-drawable-edit-gradient-fill procedure uses even more
context properties which are also newly added with this commit
(gradient_color_space, gradient_repeat_mode, gradient_reverse).

And some cleanup in context.pdb.

This is still WIP, nothing in the edit group is depcreated yet.
2018-04-15 15:28:50 +02:00
Ell 1a277f2cc6 icons: s/gimp-tool-blend/gimp-tool-gradient/ in SVG icons
In particular, so that we use the correct element IDs, if we ever
extract the icons based on element ID.
2018-04-15 03:31:08 -04:00
Ell 02808e8072 Merge branch 'fix-gradient-history'
This fixes the history of app/core/gimpdrawable-gradient.h, and
app/tools/gimpgradienttool{.c,-editor.{c,h}}.
2018-04-15 03:30:52 -04:00
Michael Natterer 92330425c8 Bug 795230 - Rename Blend tool and provide PDB compatibility
Redo the part of commits b0beb0197a,
c3f98cccbd,
6b0f5136e0,
and 3736bfd189, reverted by commit
e30a32d56e.
2018-04-15 03:30:25 -04:00
Michael Natterer 2e69608a46 Bug 795230 - Rename Blend tool and provide PDB compatibility
Rename gimpblendtool{.c,-editor.{c,h}} to
gimpgradientool{.c,-editor.{c,h}}.  Note that this commit only
renames the files; the actual changes are done in the next commit,
so that git doesn't consider them new files.
2018-04-15 03:30:24 -04:00
Michael Natterer 721ce91d75 Bug 795230 - Rename Blend tool and provide PDB compatibility
Redo the part of commits 4f2e078ccb
and 5f6dfc7617, reverted by commit
e30a32d56e.
2018-04-15 03:30:07 -04:00
Michael Natterer 9fd44d5e44 Bug 795230 - Rename Blend tool and provide PDB compatibility
Rename gimpdrawable-blend.h to gimpdrawable-gradient.h.  Note that
this commit only renames the file; the actual changes are done in
the next commit, so that git doesn't consider this a new file.
2018-04-15 03:30:05 -04:00
Ell e30a32d56e Bug 795230 - Rename Blend tool and provide PDB compatibility
Partially revert commits 4f2e078ccb
and b0beb0197a, since the changes
they introduced to some of the renamed files were big enough for
git to consider them entirely new files, hence we lost their
history.  The next few commits fix this.

This commit also partially or entirely undoes followup commits
5f6dfc7617,
c3f98cccbd,
6b0f5136e0,
and 3736bfd189, which will be
restored by the next few commits as well.
2018-04-15 03:28:41 -04:00
Jehan 309d118f65 app, devel-docs: improve position of loading text on splash image.
The upper text will be centered on the top quarter of the bottom quarter
of the splash image, whereas the bottom text will be centered on the
bottom quarter of the bottom quarter of the splash (unless the splash is
too small, in which case the double of the layout pixel extents will be
used). Basically don't use absolute pixel values anymore for
positionning. This should all be done relatively since there are
nowadays all kind of display size (and positionning the text 6 pixels to
the bottom, as it was done, may be ok on low density displays, yet will
look ugly on high density screens).

Also write this down in the splash requirements in the release howto so
that splash designers are aware that the bottom quarter of their image
will have to be adapted for printing text.
2018-04-15 02:32:30 +02:00
Ell 09b16f6cc0 app: avoid copying the brush boundary on each brush tool flush()
In GimpBrushTool, remember the settings used for the last cached
brush boundary, and avoid creating a new copy if the settings
didn't change.  This should lower the overhead of
gimp_brush_tool_flush_paint() when not using dynamics.
2018-04-14 18:43:11 -04:00
Jehan 1806e56405 INSTALL: make clear not to install libmypaint from master.
Also add a note about installing possibly from the release tarball or
from the package manager of a distribution, since apparently some assume
it has to be installed from repository, making their own life harder
that it has to!
Finally split the libmypaint and mypaint-brushes into their own numbers
to make things even clearer.
2018-04-15 00:15:03 +02:00
Anders Jonsson 9674186bed Update Swedish translation 2018-04-14 20:19:18 +00:00
Anders Jonsson 7e82a24875 Update Swedish translation 2018-04-14 20:10:35 +00:00
Sebastian Rasmussen f505f57bd8 Update Swedish translation 2018-04-14 20:02:23 +00:00
Piotr Drąg f365de49a0 Update Polish translation 2018-04-14 21:18:03 +02:00
Michael Natterer d528f80c16 app: cast g_object_ref() argument in gimp_plug_in_proc_frame_init() 2018-04-14 21:14:52 +02:00
Michael Natterer 3661097c04 app: add gimp_pdb_context_get_paint_options_list()
Which returns the entire GimpContainer of paint options.
2018-04-14 21:11:05 +02:00
Michael Natterer 0c066f311e app: drop alpha from all fishes in gimpgradient.c
Alpha is calculated separately, ne need to run it through babl.
Also some formatting cleanup.
2018-04-14 21:09:01 +02:00
Michael Natterer 3736bfd189 app: even in a "gradient tool" its called "Blending" not "Gradienting" 2018-04-14 21:06:13 +02:00
Piotr Drąg 8cc1258444 Update Polish translation 2018-04-14 19:11:16 +02:00
Øyvind Kolås 6d6da684f1 app: add handling of CIE Lab blend space to gradient
Using CIE Lab yields gradients that more closely resemble the perceptual
gradients but without the gamma based blending problems of linear-RGB / CIE
XYZ.
2018-04-14 18:12:30 +02:00
Øyvind Kolås e007da2604 libgimpbase: add GIMP_GRADIENT_BLEND_CIE_LAB value to enum 2018-04-14 18:11:38 +02:00
Jehan f660d614f2 NEWS: keep up-to-date. 2018-04-14 16:18:54 +02:00
Ell 45c172a885 Bug 795257 - Segmentation fault crash using the clone tool
Commit f5cb1fed85, which performed
brush outline generation in GimpPaintTool in synchrony with the
paint thread, wasn't enough, since GimpSourceTool could still call
gimp_brush_tool_create_outline() directly during its
GimpDrawTool::draw() method, leading to the same race condition
when executed concurrently with the paint thread.

Partially revert the above commit, so that outline generation is
handled as before, as far as GimpPaintTool is concenered.  Instead,
add GimpPaintTool::{start,end,flush}_paint() virtual functions; the
first two are called when starting/ending painting using the paint
thread, while the third is called during the display-update
timeout, while the main thread and the paint thread are
synchronized.  This allows subclasses to perform non-thread-safe
actions while the threads are synchronized.

Override these functions in GimpBrushTool, and cache the brush
boundary in the flush() function.  Use the cached boundary in
gimp_brush_tool_create_outline() while painting, to avoid the above
race condition, both when this function is called through
GimpPaintTool, and through GimpSourceTool.
2018-04-14 10:14:58 -04:00
Jehan 3ac794816a Bug 724692 - Canvas rotation stuck with specific order of actions.
Commit b279c2d217 was breaking a specific use case, which I oversaw:
when space bar activates the move tool, you may want to release the
space bar while mouse button is pressed, and expect to still be able to
move the layer/selection/guide, but releasing space was stopping the
move immediately. The move tool must only be deactivated when both space
and button 1 are released, and the move itself must continue as long as
button 1 is pressed (when started while space was pressed).

As a nice side effect of this commit, panning and canvas rotation are
also improved since now they can be continued while releasing space
(respectively shift-space) if mouse button 1 was pressed, and up until
the mouse button is released. Pressing space again, then releasing the
mouse, back and forth, also work as expected (i.e. move tool stay
activated though the move stops; and panning or rotation continue).

Of course now we don't get anymore panning/rotation stuck while neither
space nor mouse buttons are pressed (which was the original bug). At
least one of these need to stay pressed for panning/rotation/move to
stay activated. And initial activation is obviously always through
(shift-)space only.
2018-04-14 15:36:08 +02:00
Jehan 6b0f5136e0 app: use "g" for gradient shortcut.
It makes more sense than "l" as a default, and "g" was currently unused.
So not much left to ponder.
2018-04-14 14:27:36 +02:00
Øyvind Kolås 5e98dade14 configure/app: depend on GEGL 0.3.32 2018-04-14 12:38:43 +02:00
Piotr Drąg 680da3ada8 Update Polish translation 2018-04-14 10:23:37 +02:00
Jehan c3f98cccbd app: fix menu path for gradient tool s/Blen_d/Gra_dient/.
This one string was still using the old name, which appeared in menus or
in the shortcut list.
2018-04-14 04:09:29 +02:00
Jehan 063a83c1ec app: migrate configuration files for s/Blend/Gradient/ tool renaming.
This includes migrating properly any custom shortcut (menurc), as well
as a few strings in tool-presets/, and finally "gimp-blend-tool" in
contextrc and devicerc.
File toolrc also has some occurrences, but we are already skipping it
anyway, same as whatever is under tool-options/.
Hopefully I missed nothing.
2018-04-14 04:01:32 +02:00
Michael Natterer 257eb95258 app: simpler and better-aligned packig in gimpviewablebox 2018-04-14 02:19:50 +02:00
Michael Natterer 4705684b0e po: fix typo in POTFILES.in 2018-04-14 02:18:56 +02:00
Michael Natterer 5f6dfc7617 app: add GimpGradientBlendColorSpace parameter to gimp_drawable_gradient() 2018-04-14 01:34:50 +02:00