Commit Graph

5419 Commits

Author SHA1 Message Date
b49c062fa4 New upstream version 2.10.34 2023-03-01 18:41:57 -05:00
aeb5eaa890 Issue #8359: GIMP crashes from "open the font selection dialog" button.
Apparently GDK/Win32 sends the "grab-broken-event" signal before the "clicked"
signal. This has only been changed since GTK4 so far.

Anyway the bottom line is that GimpContainerPopup would process a handled on
"clicked", using the object destroyed when "grab-broken-event" happened as
callback data. The solution is to make sure that the object stays alive long
enough. So I'm changing gimp_editor_add_button() to connect to signals with
g_signal_connect_object() (since all usage of this function was used with
GObject callback data, it was not a problem).

See discussion in !815.

As a side change, gimp_container_popup_dialog_clicked() should emit the
"cancel", not "confirm". This part was taken from MR !815 by Lloyd Konneker.

(cherry picked from commit f77f772f56)
2023-02-09 23:27:17 +01:00
2d59d233ef [app] Ensure calculated histogram spike height ...
is positive or zero. Sometimes the calculated `y` or `bg_y`
values are negative because the histogram value was divided
by zero (when max == 0.0).

Resolves: #9132 (Gnome/GIMP bug tracker)
(cherry picked from commit 9b517fbf7d)
2023-02-10 00:53:53 +06:00
49310e5943 Issue %8365: Ambiguous naming of "Lock path strokes".
(cherry picked from commit 8bd3d5e0bb)
2023-02-09 15:12:45 +01:00
233a014490 app: add eye icon to GimpItemTreeView header...
...visibility column.
Makes it much more obvious where you have to click for visibility, and
where each column is. Also it's more consistent.
Backport of Jehan's code.
2023-02-06 09:44:26 -05:00
78ec4d1495 app: update gimphelp-ids.h
Removed several help ids that are not in use anymore.
Fixed spelling of one help id, the spelling has also been fixed in
gimp-help.
2023-01-14 16:07:04 -05:00
f74ebc9c36 app: Disabled symmetry menu when no image is set
To improve discoverability, the symmetry dockable's combobox menu is now
shown (but disabled) when no image is set.
2022-12-24 03:43:35 +00:00
208912be08 app: use pre-defined help id GIMP_HELP_COLORSELECTOR_PALETTE
Instead of using the string directly. This ensures that possible updates
in the string don't go unnoticed in gimp-help.

(cherry picked from commit 8372220345)
2022-12-23 13:04:14 -05:00
0f5afa0f2e app: update available help ids for gimp-help
Add several missing help ids, remove those that are not used anymore,
and update "gimp-colorselector-water" to "gimp-colorselector-watercolor".

Also add a comment why some help ids are not used directly.
2022-12-23 13:04:02 -05:00
adc1419881 app: remove duplicate GIMP_HELP_TOOL_CURVES define
This caused a missing documentation warning for help id gimp-tool-curves
in gimp-help.

(cherry picked from commit 6cb58fbc8d)
2022-10-15 16:33:01 -04:00
2beaee0a65 app: remove unused GIMP_HELP_TOOLS_DIALOG help id
This help id was used in the past but all references to it were removed
long ago with commit c53113d0cc.

Let's remove this define too since it causes a warning in gimp-help when
checking for help id's without documentation.

(cherry picked from commit 4b4dd5ec38)
2022-10-15 14:05:50 -04:00
30c23df646 New upstream version 2.10.32 2022-08-01 09:14:18 -04:00
bfc59da987 Cppcheck fixes
(cherry picked from commit 3e35fe4d80)

# Conflicts:
#	app/widgets/gimpcolordialog.c
#	libgimpwidgets/gimpchainbutton.c
2022-05-06 15:10:06 -04:00
52519f1290 New upstream version 2.10.30 2021-12-27 21:32:02 -05:00
1ff0cc1f5c New upstream version 2.10.28 2021-09-19 12:12:14 -04:00
970059b644 New upstream version 2.10.26 2021-09-09 19:33:41 -04:00
6c74aa8490 New upstream version 2.10.24 2021-07-18 14:31:43 -04:00
6829274dde app: add a comment and some newlines before the debug data section.
The markdown triple-quote (```) has to be on its own at the start of a
newline. Schumaml was telling me that too many reporters would paste
just after some text, which would therefore break the markdown syntax.

Instead let's add 3 newlines before the triple-quote, so that even
people who would not hit the "Copy Bug Information" button (but instead
select and copy) have a hint that these newlines are made on purpose.
Also add a comment (which is discarded by Gitlab) to make this even more
obvious.

Then even when pasting just after some text on the same line, the
triple-quote will end up on its own line.

(cherry picked from commit d3105e5c72)
2021-07-05 16:45:52 +02:00
26baa0527d app: check if an item was already inserted by actually looking it up in…
… the container.

There was this weird case which we somehow could only reproduce on
Aryeom's computer/build, not mine, with the same code and reproduction
steps (reproducible at will on her build only). Basically when drag'n
dropping a duplicated layer inside a collapsed layer group, the
row-expanded handler would try to select the moved layer before it is
actually inserted. This would end up into crash-happy code.

I'm still unsure of why the order of operation is different here, but
anyway what is for sure is that the `inserting_item` boolean flag was
not protecting much. It's not like it's an actual mutex and anyway this
is not multi-threaded code either so this flag was mostly useless (which
is why we were crashing). Instead let's actually look if the item is in
the container or not.
2021-07-05 10:41:52 +02:00
f3c21c7e6e Issue #6850: support for memory in the dashboard under OpenBSD.
(cherry picked from commit 6dc98fe7f0)
2021-05-09 20:02:56 +02:00
b93dd4e0fe Revert "app: append insensitive reason to GimpAction proxy tooltip."
This reverts commit bf9a292723.

I messed up copying the commit to cherry pick.
2021-04-23 15:07:55 -04:00
bf9a292723 app: append insensitive reason to GimpAction proxy tooltip.
With my previous commit, I improved the search action display and search
algorithm (which was returning wrong results), but we had lost showing
the non-sensitive reason in menu item tooltips. This fixes it, by
actually appending the reason, but only in the end, on the GtkWidget
tooltip (not in the action's tooltip itself).

(cherry picked from commit 13a02aea23)
2021-04-23 15:02:12 -04:00
59bab76383 app: fix 3d transform tool not added to gimphelp-ids.h
(cherry picked from commit 4aaad4f749)
2021-04-09 18:04:49 -04:00
4ea7fb6f4f app: proper ellipsis & wrap on Image Properties label where it matters.
The color space label may be a bit long (depends on profile title which
may just be anything and we don't control it), so I allow it to wrap.

The file path on the other hand would not work well with wrapping. It
already has ellipsis in center, but GTK always gives the max size it can
as a default. So if the file is even just slightly deep in the file
tree, we end up with extra-wide Image Properties dialog.
My trick is to give a sensible max size at dialog creation (25
characters max) but to disable this max size as soon as the window gets
realized, hence allowing the label to actually grow up to the contents
actual max size, were one to manually resize the window.

(cherry picked from commit 377de0a65b)
2020-11-12 11:56:20 +01:00
18fa6d3a2f app: display profile name in "Color space" field of Image Properties.
"RGB color" is not a color space, only the model. To get full color
space information, we want to display the model and associated profile
name.
Of course, the "Image Properties" dialog also has a tab displaying
details about the color profile. Still it's better if the general info
displays not too wrong label contents.

Note: when the used color profile has no name, it will show "(unnamed
profile)" which is still more informative than just the color model.

(cherry picked from commit b9ab461977)
2020-11-12 01:02:56 +01:00
627ba9c288 New upstream version 2.10.22 2020-10-06 19:17:19 -04:00
c6b46b63b5 New upstream version 2.10.20 2020-08-26 11:05:56 +01:00
Ell
05341fada3 app: avoid dropping motion events in spin-scales
It looks like GDK motion hints are broken, at least on X, causing
us to drop motion events in GimpSpinScale, if the motion triggers
an operation that blocks the main thread for a significant amount
of time, such as projection invalidation.

Instead, disable motion hints for spin-scales, and use an idle to
perform ad-hoc motion compression.
2020-08-24 12:33:53 +03:00
Ell
638e05494a app: allow recording GLIB log messages in performance logs
Add a new "Messages" boolean parameter to performance logs, which,
when set, records GLIB log messages in the performance log as
markers, with an accompanying sample capturing their backtrace.
This option is enabled by default.

(cherry picked from commit 9e0fdc8e2c)
2020-08-02 11:08:46 +03:00
Ell
38b1298c2d app: in GimpDashboard, fix progressive-performance-log env-var
(cherry picked from commit d11cbbbbc9)
2020-07-30 01:14:42 +03:00
Ell
60ca611096 app: add progressive performance logs
Add an option to record progressive performance logs.  Progressive
logs contain complete information after each recorded sample, by
writing partial address maps at each sample, containing all new
addresses introduced by the sample.  Furthermore, when recording a
progressive log, the output stream is flushed after each sample.

This allows recording complete logs even in cases where they can't
be properly terminated, such as when GIMP crashes or freezes in the
middle of the log.

Progressive logs are disabled by default, since they potentially
increase the sampling cost.  They can be enabled through a toggle
in the log file-dialog, or through the
GIMP_PERFORMANCE_LOG_PROGRESSIVE environment varaible.

(cherry picked from commit 146c234350)
2020-07-30 01:06:55 +03:00
Ell
7e21f79270 app: allow controlling performance-log parameters through the UI
When recording a performance log, allow setting the log parametrs
through the file dialog.  Currently, this includes the sample
frequency, and the option to include backtraces.

These options are still controllable through the
GIMP_PERFORMANCE_LOG_SAMPLE_FREQUENCY and
GIMP_PERFORMANCE_LOG_BACKTRACE environment variables.  When set,
the variables override the values entered through the UI.

(cherry picked from commit 126002c5c9)
2020-07-30 01:06:54 +03:00
Ell
3212da715b app: increase idle priority for hiding on-hover tool-group menu
In GimpToolButton, when in "show menu on hover" mode, increase the
idle priority for hiding the the tool-group menu upon button/menu
leave-notify.  Make the priority one step below the normal event
priority, so that a subsequent button/menu enter-notify event
canceling the idle is processed beforehand, while the idle is
otherwise still processed before ordinary lower-priority sources,
in particular, before projection rendering timeouts.
2020-06-28 12:12:36 +03:00
Ell
00145da370 Issue #5226 - hover over toolgroup not working
In gimp_tool_button_enter_notify(), only mask-in the mouse-button
state for determining whether to show the tool-group menu.  This
avoids other bits of state -- in particular, certain keyboard
locks, including keyboard-layout state -- from preventing the menu
from showing.
2020-06-16 13:12:34 +03:00
0087167cb3 Misc. typos
Found via `codespell`

(cherry picked from commit ac282f2045)
2020-06-10 02:09:26 +02:00
4c08173025 app: make a tooltip translatable and translate device axis strings.
Thanks to Cristian Secară on the developer mailing list to notice them.

(cherry picked from commit 5302beb947)
2020-06-09 11:04:36 +02:00
Ell
8da94a5751 app, menus: add gegl:lens-blur to Filters -> Blur
gegl:lens-blur simulates an out-of-focus lens blur.
(cherry picked from commit 323355a708)
2020-06-02 23:29:12 +03:00
Ell
69b0d86713 app: add gimp_prop_range_set_ui_limits()
... which sets the limits of the range-widget's handle-bar
explicitly, instead of using the lower/upper properties' limits.

(cherry picked from commit ce8235e977)
2020-06-02 23:29:11 +03:00
Ell
e5916c81cc app: allow setting handle-bar limits explicitly
In GimpHandleBar, add gimp_handle_bar_{set,unset,get}_limits(), to
allow settings the handle-bar limits explicitly, rather than
inheriting the adjustment limits.

(cherry picked from commit fa5dd99559)
2020-06-02 23:29:11 +03:00
Ell
0c65fce18c app: add gimp_prop_range_new()
... which creates a widget controlling a pair of lower/upper range-
limit properties, comprised of a handle-bar and two spin-buttons.

If the "sorted" parameter is TRUE, the "lower" property is bounded
above by the "upper" property, and vice versa.

(cherry picked from commit e03b8e597b)
2020-06-02 23:29:11 +03:00
Ell
a974e71702 app: add gimp_gtk_adjustment_chain()
... which takes a pair of GtkAdjustments, and binds the value of
the first to the lower-limit of the second, and the value of the
second to the upper-limit of the first.

(cherry picked from commit 45e5c2231a)
2020-06-02 23:29:10 +03:00
Ell
4c924c1cb8 app: in gimp_accel_label_set_action(), emit notify
(cherry picked from commit 0ac2aa5130)
2020-06-02 11:03:29 +03:00
Ell
35d6d9e529 app: list all tool-group tools in tool-button tooltip
In tool-group GimpToolButton tooltips, in addition to showing the
description of the currently-active tool, list the other tools in
the group as well, to improve discoverability.

(cherry picked from commit 4d83c7a3fc)
2020-06-01 19:30:54 +03:00
Ell
a54704bcdc app: add GimpAccelLabel
Add a new GimpAccelLabel widget, which shows an accelerator label
for a given GimpAction.  Unlike GtkAccelLabel, GimpAccelLabel
doesn't show a user-provided label in addition to that.

Note that the size request of GtkAccelLabel doesn't include the
accelerator part, which is desirable in some contexts.
GimpAccelLabel doesn't suffer from that.

(cherry picked from commit 2259ad5fcc)
2020-06-01 19:30:09 +03:00
Ell
3e61ef9ae6 app: fix alignment of generic pixel buffers
Wherever we store arbitrary-format colors in an opaque buffer, use
double for the buffer, instead of char, so that it has a strict-
enough alignment to handle all our used pixel formats.

(cherry picked from commit a90f59d961)
2020-05-20 08:54:31 +03:00
Ell
b5353eb2eb app: in GimpPanedBox, don't accept drag contexts with unsupported targets
... to avoid highlighting the droppable areas during darg.

(cherry picked from commit e38010b2d1)
2020-05-18 18:19:47 +03:00
Ell
3bc1d6a31a app: add gegl:focus-blur to Filters -> Blur
gegl:focus-blur blurs the image around a focal point.  It can be
used to create fake depth-of-field effects.

Add a prop-gui constructor which uses a FOCUS controller to control
the focus geometry.

(cherry picked from commit 60d4d25b93)
2020-05-15 00:50:01 +03:00
Ell
8e96c6c1b2 app, menus: add gegl:variable-blur to Filters -> Blur
gegl:variable-blur applies a blur with a per-pixel radius
controlled by a mask.

(cherry picked from commit 721f2d8c27)
2020-05-15 00:49:57 +03:00
f274b139fc Issue #3533 - Tool preset doesn't restore opacity and paint mode
There is no non-hackish way of fixing this without adding a new
"use-opacity-paint-mode" property to GimpToolPreset and a new toggle
in GimpToolPresetEditor. Restoring opacity and paint mode can now be
controlled explicitly, and defaults to TRUE.

(cherry picked from commit 97b714d428)
2020-05-12 21:14:41 +02:00
ef217108a6 app: clear the clipboard after storing its contents, upon quitting.
If we don't do this, the clipboard owner doesn't get unreffed (also the
GtkClipboardClearFunc is not called either, but we don't set any so this
was not a big problem).

The main consequence was that copying was setting the Gimp object as an
owner, which kept a reference and prevent its finalize() method to run,
hence was leaking data (and in particular some GEGL buffers for
clipboard operations, which was how the issue became more visible upon
exit).

(cherry picked from commit fca6371e29)
2020-05-06 19:25:25 +02:00