Commit Graph

47248 Commits

Author SHA1 Message Date
Andre Klapper b89e815489 Fix broken markup in Malay user help 2021-08-21 22:27:50 +02:00
Andre Klapper e50d844a58 Fix broken markup in Galician user help 2021-08-21 22:26:53 +02:00
Andre Klapper eae6e9a6ad Fix broken markup in Dzonghka user help 2021-08-21 22:25:44 +02:00
Andre Klapper a3d7f71095 Fix broken markup in Bulgarian user help 2021-08-21 22:25:10 +02:00
Jehan c3e3c68a01 libgimpconfig: free a GimpValueArray on deserialization failure.
Thanks to Massimo.
2021-08-21 19:19:23 +02:00
Jehan 9a0876b9bd app: forgotten GList freeing.
Thanks to Massimo for the report.
2021-08-21 19:06:14 +02:00
Jehan 1ece3675c9 app: another leaked GtkTreePath.
Thanks to Massimo, again and again. ;-)
2021-08-20 22:00:03 +02:00
Jehan 025cebf76f app: free an unusing allocated string when not used as a result.
Another leak reported by Massimo.
2021-08-20 21:53:41 +02:00
Jehan ef56fed9cb app: string allocated by gtk_tree_path_to_string() must be freed.
Thanks again to Massimo for the report!
2021-08-20 21:43:55 +02:00
Jehan 411c279610 app: return value of gtk_tree_path_new_from_string() must be freed.
Thanks to Massimo for reporting this leak.
2021-08-20 21:37:45 +02:00
Jehan f5ea8e9b2a app: fix leak of a GdkPoint and improve stable zoom centering logics.
This started as yet another report of leak by Massimo. But really the
leak of the GdkPoint created by the function
gimp_display_shell_push_zoom_focus_pointer_pos() is not only when
delta_y is 0. There are a few code paths in gimp_display_shell_scale()
when we would not pop this point. One of them is for instance when
window resizing in multi-window mode is allowed. There might be more
(but the code is convoluted enough not to be 100% sure if these are
possible with our specific case).

This specific function was initially created only to be used for unit
testing code (commit 7e3898da09), but it ended up being also used
internally (commit 792cd581a2). Since I see that the test for which
this code was initially created even seem broken right now (the assert
part for position check is commented out!), I even wonder if we should
keep it. We could indeed instead just add optional start_x|y arguments
to gimp_display_shell_scale(), which would be much cleaner. But I leave
it for now.

Instead I just make sure we clean the created GdkPoint after calling
gimp_display_shell_scale(). Also I get rid of the GQueue. It is clear in
the code that we are not expecting queuing interaction of several
positions. Worse right now, we could end up in weird cases where the
pushed points are not used when they should, then could end up being
used later in totally unrelated interactions (this would make the shell
position jump here and there). So let's just make it a single point.
Finally adding some appropriate comments in parts which are still a bit
wrong.
2021-08-20 20:51:29 +02:00
Matej Urbančič 23da87aab4 Update Slovenian translation 2021-08-17 20:00:01 +00:00
Matej Urbančič 7489418d95 Update Slovenian translation 2021-08-17 19:57:36 +00:00
Matej Urbančič 2ba8c2f8a4 Update Slovenian translation 2021-08-17 19:51:48 +00:00
Matej Urbančič 60fc2cbb7b Update Slovenian translation 2021-08-17 19:46:14 +00:00
Anders Jonsson bde62cef8e Update Swedish translation 2021-08-16 20:49:17 +00:00
Jehan 24e44c13cd app: fix leaking a GimpMybrushSurface struct.
Reported by Massimo, as again and again! \o/
2021-08-16 22:39:06 +02:00
Jehan 0359427756 app: allow image_merge_layers_callback() to be called with NULL dialog.
This function is not only used as "response" callback to the merge
dialog, but also called directly with a NULL dialog in
image_merge_layers_last_vals_cmd_callback().

This commit fixes:
> (gimp-2.99:130330): Gtk-CRITICAL **: 22:17:59.774: gtk_widget_destroy: assertion 'GTK_IS_WIDGET (widget)' failed

Reported by Massimo.
2021-08-16 22:20:07 +02:00
Jehan 3603441037 app: return of gimp_image_get_selected_drawables() must be freed.
One more report by Massimo.
2021-08-16 20:22:44 +02:00
Jehan 140652a478 app: free GList (leak reported by Massimo). 2021-08-16 19:29:46 +02:00
Jehan b93c416e42 app: free a GimpPixPipeParams value (reported by Massimo). 2021-08-16 19:15:48 +02:00
Jehan 968cc3c758 app: free unused return value of gimp_procedure_execute().
Another leak reported by Massimo.
2021-08-16 19:08:40 +02:00
Jehan 4336b7a8e3 app: fix memory leak reported by Massimo. 2021-08-16 18:57:21 +02:00
Jehan abb904d64d app: improve/fix the most-recently used layers stack management.
A few issues existed in the code:
- When the layers selection is changed, make sure we remove all
  duplicates (not only the first one). This should not be a problem
  anyway because we also do this duplication cleanup elsewhere now, but
  still…
- Fix gimp_image_layer_stack_cmp(): we were comparing a GList element to
  the data of another, so we were actually never finding duplicates.
- Add gimp_image_clean_layer_stack() for internal layers stack
  management/cleanup. It takes care of recursively making sure we don't
  leave duplicates, and remove all empty lists.
- Now use this new cleanup function inside
  gimp_image_remove_from_layer_stack() instead of doing some incomplete
  and broken element removal. This was especially broken as we were
  removing a GSList element from a list we were iterating on (so we were
  dereferencing a now freed element). This last issue was reported by
  Massimo, and this is how I found the more general failure in this
  layers stack management.
2021-08-16 15:06:00 +02:00
Jehan 70f2192bff app: fix leaked queue created at init() (as reported by Massimo). 2021-08-16 12:16:52 +02:00
Jehan 2d1d2340db app: fix one more ugly leak.
This one was definitely tricky. Thanks again to Massimo for catching it!
2021-08-15 01:44:46 +02:00
Jehan a10bb056ed app: fix 2 possible leaks.
In some cases, the `src_viewables` and `drop_path` variables may leak.
Thanks to Massimo for the report on `src_viewables`!
2021-08-14 19:57:00 +02:00
Jehan b1afc33971 app: fix list leak, as reported by Massimo. 2021-08-14 19:02:29 +02:00
Jehan ee09ae7245 app: fix gimp_plug_in_cleanup_item_new().
This fixes a memory leak as reported by Massimo.
But even more, we fix the code logics, as the cleanup items were never
added to the `item_cleanups` list.
2021-08-14 18:20:49 +02:00
Jehan c7b3c3c629 app: free leaking drawable list (as reported by Massimo). 2021-08-14 13:35:48 +02:00
Jehan 4f7dceff15 app: fix string array leak as reported by Massimo. 2021-08-14 12:54:13 +02:00
Luca Bacci ac0a084e6e Show message dialogs in preferences dialog 2021-08-13 20:45:15 +00:00
Stanislav Grinkov 6892326e8e Remove use of custom marshallers in favor of GLib ones 2021-08-13 18:01:13 +00:00
Stanislav Grinkov 428b944334 Remove unnecessary linking with genmarshal from meson build rules 2021-08-13 18:01:13 +00:00
Stanislav Grinkov 619cb91230 Remove unnecessary gimpmarshal.h and gimpwidgetsmarshal.h includes. 2021-08-13 18:01:13 +00:00
Yuri Chornoivan dc89adf563 Update Ukrainian translation 2021-08-11 20:01:19 +00:00
Jordi Mas 2b59006135 Fix to Catalan translation 2021-08-11 19:11:15 +02:00
Massimo Valentini dd03716fae Issue 7128: Mouse wheel zoom when cursor is over the zoom scrolldown. 2021-08-10 15:01:14 +02:00
Jacob Boerema 317b5d9cff app: improve error message loading pattern that is too large
As noted in issue #6032 the error message when trying to open a pattern
file with dimension larger than supported could be a little clearer.

We do this by adding the maximum allowed dimensions to the error message.
2021-08-09 18:08:33 -04:00
Jacob Boerema f130fe1917 app: disallow saving of patterns larger than max allowed dimensions
For GIMP patterns we have maximum allowed dimensions which we check when
loading a pattern. However, we did not check this when saving a pattern.
See issue #6032.

This commit adds a check when saving a pattern and adds a descriptive
error to make clear why saving fails.
2021-08-09 16:37:28 -04:00
Jacob Boerema 7bb892f3d5 plug-ins: fix #5313 Exporting to "Gimp pattern" i.e. pat format fails
After the change that allows multiple layers to be selected exporting to
a pattern fails.

Patch this as suggested by Lloyd Konneker by doing the same as for brushes:
do not allow multiple layers, instead only send the first drawable.
2021-08-09 16:28:33 -04:00
Jacob Boerema 65950de735 libgimpbase: fix #1350 Failure to load metadata importing image with non-latin unicode path
On Windows loading metadata from images with non ASCII characters in their
path failed. Part of the fix is in gexiv2 that now converts the path from
utf-8 to utf-16 on Windows.

However we were still sending a localized path to gexiv2 where it was
expecting utf-8. This caused the conversion and thus loading of metadata
to fail. Fix is to remove the special handling for Windows and use the
utf-8 filename.
2021-08-08 19:31:40 -04:00
Jacob Boerema 4f86d8088d plug-ins: fix #2655 Can't open EPS-files with german Umlauts
Due to differences between Windows and most other platforms Ghostscript
didn't correctly load files with special characters on Windows.

First we needed to make sure that the filenames we use are in utf-8
format and then tell gsapi that we use utf8 encoding.
2021-08-08 19:31:40 -04:00
lloyd konneker c324ec3e8c Fix #6980 /app/pdb/gimppdb.c unnecessarily includes core/gimpmarshal.h 2021-08-06 14:21:51 +00:00
Jacob Boerema d94a0c00af plug-ins: add non interactive support for extra parameters in file-bmp-save
When exporting to bmp using a script or plug-in we could not set the
parameters use-rle, write-color-space-info, and rgb-format when used
non-interactively.

This is discussed in issue #491. The patch there does not work for master,
so I came up with this.
2021-08-05 16:18:36 -04:00
Michael Bazzinotti 4d528f297f Issue #5415: compensate for null byte
When exporting a C source file with runtime length encoding, the
C-string's array size does not accomodate for the null byte. However,
GIMP accomodates for the NULL byte in it's NON-RLE export, suggesting
that this has been a mere oversight for RLE.

This can cause at the worst a compile-time error and at least a warning
from the compiler.
2021-08-05 19:49:55 +02:00
Jehan 7982a5d18c Issue #5386: Gimp crashes when setting AdobeRGB image to Indexed colors.
Similar to the fix of commit c0e605ef for RGB images with a profile as
notified by Massimo.
2021-08-05 18:53:15 +02:00
Massimo Valentini 3b2a8f79f0 Issue #5267: Cage transform tool causes artifacts.
I somewhat bisected GEGL commits between 0.4.20 and 0.4.24 and found
that the one that introduced the env var GEGL_OPERATION_INIT_OUTPUT is
the first showing the problem.

Reviewer (Jehan) note: so it would be commit 6e9610e65c on GEGL repo.
This fix makes sense as it means that since this commit, the output
buffer could have random values. It's not a problem for any operation
where we fill every value, but I guess it's not the case for
"gimp:cage-coef-calc" which was likely relying on the old behavior of
being 0-initialized.
2021-08-05 16:58:55 +02:00
Jehan 2749706442 devel-docs: update release-howto file. 2021-08-05 00:14:22 +02:00
Des McGuinness 4f9b7373e6 Issue #5989 - performance improvement patches for gtk and gimp
Reviewer comment (Jehan): we have used this patch successfully on our
installers since start of 2021 (see commit b4d665d of our gtk-osx fork)
and it really improved the situation. I only fixed minor coding style
stuff in the patch.
Looking at what it does, I guess it is not ideal long-term if related to
10-bit display (as I understand from the comment), which a graphics app
would want to support properly. But for now, this is better than
extra-slow display until we get macOS developers able to look at this
more in depth in the future (I don't think that our dependencies are
really ready yet for 10-bit display support anyway, though I may be
wrong).
Some other forums seem to say it comes from macOS invalidating now more
than it should (i.e. the whole area instead of only the changed area)
and this NSViewUsesAutomaticLayerBackingStores flag would disable this
behavior. It might be one of these reasons, the other or both. This is
anyway a good first start for future contributors.
2021-08-04 21:47:26 +02:00