Commit graph

5251 commits

Author SHA1 Message Date
Sabri Ünal
a02958c5ce Missing mnemonics on several file dialogs
This path corrects missing mnemonics on several save/open/export dialogs.

save: file
open: file, dds, fits, tiff
export: bmp, dds, fli, gbr, gih, mng, pat, pnm, pdf, raw, sunras, sgi, webp
2019-09-05 12:46:14 +00:00
Sabri Ünal
35df110a05 Missing mnemonics on several dialogs
paste as brush, paste as pattern, select to new brush, select to new pattern
fill selection outline, fill path, stroke selection, distort, rounded rectangle
indexed color conversion, merge visible layers, new guide, new guide (by percent)
image properties, newsprint, fractal explorer, sample colorize, new layer

metadata editor (just a button), spyroplus (only common buttons)
2019-09-05 12:44:17 +00:00
Ell
877acad596 app: fix a few compilation warnings 2019-09-04 20:56:24 +03:00
Ell
5e59e5c002 app: add support for color picking in "show all" mode
Add a show_all parameter to gimp_image_pick_color(), which, when
TRUE, allows picking colors outside the canvas bounds in sample-
merged mode.  Forward the display's "show all" mode through this
parameter where applicable (in particular, in the color-picker tool
and the pointer dockable).
2019-09-04 20:56:24 +03:00
Ell
4eef2297b6 app: show full image contents in GimpNavigationEditor
In GimpNavigation{Editor,View}, show the full image contents when
the corresponding display is in "show all" mode.  Additionally,
when the display's "show canvas boundary" is active, show the
canvas boundary in the navigation view as well.
2019-09-04 20:56:23 +03:00
Ell
61535e0756 app: handle GimpImageViewable in GimpViewRendererImage
Allow using a GimpImageViewable as the source for a
GimpViewRenderer, by allowing GimpViewRendererImage to handle this
type of viewables.
2019-09-04 20:56:23 +03:00
Ell
214cda5403 app, menus: add "show canvas boundary" display option
Add a "show canvas boundary" display option, and a corresponding
"View" menu item and default-apperance preferences option.  When
enabled (the default), the canvas boundary is shown as an orange/
black dashed line in "show all" mode.
2019-09-04 20:56:23 +03:00
Ell
162665e42b app, menus: add "show all" mode to GimpDisplayShell; "View -> Show All" toggle
Add a "show all" mode to GimpDisplayShell, controlled through a
corresponding "View -> Show All" menu item.  When enabled, the
entire image content is displayed, instead of cropping the image
to the canvas size.  More generally, the display behaves as if the
canvas were infinite.  The following commits improve the overall
behavior in this mode.

Add a prefernces option to control the default "show all" state.
2019-09-04 20:56:23 +03:00
Michael Natterer
f3f3d066a6 app: better error reporting in gimp_pdb_dialog_run_callback()
Display the error returned from trying to run the temp procedure.

(cherry picked from commit 910828bf51)
2019-08-03 17:32:35 +02:00
Ell
f020569caa app: add assigned-threads variable to the dashboard
Add an assigned-threads variable to the dashboard's misc group,
showing the number of worker threads which currently have work
assigned.  See commit
gegl@fc532f06773bd292c86abee31ac18f62e26d39df.

(cherry picked from commit e92732f7cf)
2019-07-23 17:15:19 +03:00
Ell
65fb2859c4 app: add active-thread variable to the dashboard
Add an active-thread variable to the dashboard's misc group,
showing the number of active worker threads.  See commit
gegl@6a3a6314d4d4cd668e0f6164afc0fde8b9c7c001.

(cherry picked from commit 2cc77e6927)
2019-07-21 00:00:57 +03:00
Michael Natterer
5b5374c8fb app: add gegl:mean-curvature-blur to Filters -> Blur
(cherry picked from commit ed64fda6e5)
2019-07-19 14:42:11 +02:00
Michael Natterer
d503212f9d app: add gegl:newsprint to Filters -> Distorts
and add a custom GUI constructor that does nothing special (yet).

(cherry picked from commit d718da27a8)
2019-07-17 18:31:33 +02:00
Michael Natterer
d9349a5730 app: get rid of a few more GtkAction warnings, and a little cleanup
(cherry picked from commit f7007d5161)
2019-07-05 12:36:26 +02:00
Michael Natterer
9c0085c7ec app: don't warn in gimp_action_history_action_activated()
if there is no "gimp". Happened after the action changes when invoking
the "quit" action.

(cherry picked from commit 87b1a27459)
2019-07-04 17:06:40 +02:00
Michael Natterer
ff7ca87c09 app: GtkAction -> GAction madness part two
Change all action callbacks so they can be invoked by a GAction:

- add GimpActionCallback typedef:
  void (* cb) (GimpAction*, GVariant*, gpointer)
- change all action callbacks to the GimpActionCallback signature
- add "gimp-activate" and "gimp-change-state" signals to GimpAction,
  with the same signature as the resp. GAction signals
- remove all other custom action signals and only use the new
  GimpAction signals
- pass around appropriate GVariants containing booleans, int32,
  strings
- badly hack around to force a GimpProcedure pointer into a
  uint64 variant
- remove all G_CALLBACK() casts from all action callbacks,
  they all have the same signature now

(cherry picked from commit 3b6b3fc189)
2019-07-04 01:32:18 +02:00
Michael Natterer
29b300378d Issue #3599 - Crash when creating channel
Must use a GIMP_TYPE_ACTION_IMPL in GimpColorPanel, not just a
GIMP_TYPE_ACTION which is only an interface now.

(cherry picked from commit 998bd04bd4)
2019-07-02 16:54:01 +02:00
Michael Natterer
4a8417fa4c app: fix some warnings in gimpactiongroup.c
They were not deprecation warnings, just hidden between them.

(cherry picked from commit f20b873396)
2019-07-02 14:58:21 +02:00
Michael Natterer
417d0dccd7 app: start porting away from GtkAction and friends
Step one: get rid of all those deprecation warnings that make
it hard to see any other warnings:

- add a lot of dummy API to GimpAction, GimpActionGroup, GimpUIManager
  etc. which simply forwards to the deprecated GTK functions, they
  will all go away again later
- rename GimpAction to GimpActionImpl
- add interface GimpAction that is implemented by all action classes,
  creates a common interface and allows to remove some duplicated
  logic from GimpToggleAction and GimpRadioAction, and at the same
  time adds more features

(cherry picked from commit 86e07c16b5)

Merged to gimp-2-10 to keep the diff to master as small as possible
2019-07-02 14:57:45 +02:00
Michael Natterer
90d0fb4a6e app: get rid of manual object type registration
and all deprecated use of private instance registration.

(cherry picked from commit e72a9d88a5)
2019-06-29 16:43:12 +02:00
Michael Natterer
12b8d75ff1 app: add gegl:bayer-matrix and gegl:linear-sinusoid to the menus
in Filters -> Render -> Pattern. Also depend on GEGL from git.

(cherry picked from commit 928b85d25c)
2019-06-28 15:50:40 +02:00
Michael Natterer
7b7e2ebecf Issue #3503 - Display Preset names on Filter Dialogs
Don't clear the preset combo right after a preset was selected.
Instead, clear it as soon as any change is made to the settings in the
dialog. This way the last chosen preset's name stays in the combo as
long as the current settings are identical to the preset.

(cherry picked from commit 0afcaefec5)
2019-06-26 14:58:30 +02:00
Jehan
6a854e45fa Issue #2194: Action search dialog behaves as a full window using a...
... tiling window manager.
Completing commit e6364ffa81 by additionally making sure the search
dialog is non-modal. Otherwise it prevents positionning it wherever we
want and it stays in the center, potentially hiding the canvas and
darkening the main window.

(cherry picked from commit aa1171ada2)
2019-06-11 02:23:07 +02:00
Ell
257e35dda1 app: avoid duplicate offset actions
Blacklist the "tools-offset" action in the GUI, and only keep
"filters-offset", to avoid duplication.  Update gimp:offset's
description, so that "filters-offset" gets a proper tool-tip.

(cherry picked from commit 42d4255262)
2019-06-06 04:52:32 -04:00
Ell
175e3ea7d9 app: various fixes/cleanups to last commits
(cherry picked from commit 30429e30e2)
2019-06-06 03:10:03 -04:00
Ell
ca4612cc43 Issue #40 - Layer offset tool
Add a new Offset filter tool, as a front-end to gimp:offset.  The
tool replaces, and provides the same interface as, the drawable-
offset dialog, while also providing live preview and on-canvas
interaction.

Note that we don't simply use a custom propgui constructor for
gimp:offset, since we need a little more control.

(cherry picked from commit 3a4a00c71e)
2019-06-05 19:10:52 -04:00
Michael Natterer
645d987e07 Issue #2957 - Gimp crashes when I attempt to change the icon size
Simplify GimpDockbook's signal connect/disconnect to
GimpGuiConfig::size-changed a lot, most likely to a point where some
connection doesn't get leaked, so this bug is probably fixed.
2019-06-02 03:29:19 +02:00
Michael Natterer
a624010931 Issue #2194 - Action search dialog behaves as a full window...
...using a tiling window manager

Set GimpSearchPopup's type hint to GDK_WINDOW_TYPE_HINT_DIALOG.

(cherry picked from commit e6364ffa81)
2019-06-01 17:40:37 +02:00
Michael Natterer
8d05d01820 app: fix undoing image parasite attach/detach to emit the right signals
Add "gboolean push_undo" parameters to gimp_image_parasite_attach()
and _detach() and use the API also from undo, instead of implementing
attaching/removing manually and forgetting about the signals.

Fixes updating of the image properties color profile page.

(cherry picked from commit 710cfc1f47)
2019-05-30 16:58:53 +02:00
Michael Natterer
159a0a779f Issue #2986 - Input controller configuration window is too small by default
Set a minimum size on the event list's scrolled window.

(cherry picked from commit 476cf19747)
2019-05-29 23:37:06 +02:00
Michael Natterer
de568a0f61 app: use g_clear_pointer() in more places
(cherry picked from commit 901350ba20)
2019-05-27 17:51:14 +02:00
Michael Natterer
23c1e0328a Issue #3398 - colour map picker isn't positioned on the correct...
...-last positioned- monitor

Use gimp_dialog_factory_position_dialog() in GimpColormapEditor and
GimpPaletteEditor so the color dialogs appear where they were before.

(cherry picked from commit 765abcd316)
2019-05-27 14:58:08 +02:00
Michael Natterer
eb99c1a82f app: add gimp_dialog_factory_position_dialog()
which is the logic that used to be in color_area_color_clicked()
factored out to proper API. It makes sure that a dialog that was
visible before (and was only hidden not destroyed) appears at the same
point on the same monitor as before. See issue #1093.

(cherry picked from commit ebb6b08e62)
2019-05-27 14:33:04 +02:00
Ell
3097978f4e app: in GimpDashboard, improve legend logic
(cherry picked from commit 088827e563)
2019-05-11 05:14:31 -04:00
luz.paz
ce92efa82e Add a few more misc. source comment typos
(cherry picked from commit 1c91b8d97e)
2019-05-10 01:42:22 +09:00
Ell
89495f457d app: add tile-alloc-total variable to the dashboard
Add a tile-alloc-total varaible to the dashboard's memory and misc
groups, showing the total amount of memory used by the tile
allocator (see commit
gegl@137e66e45138e8316f6403e53e8aa9a02ad523e7.)

(cherry picked from commit cf54f790fd)
2019-05-08 04:22:50 -04:00
Ell
cb4e9b92bc app: in GimpDashboard, don't show legend for groups with no meter
in GimpDashboard, don't show field legend colors in groups without
a meter.

(cherry picked from commit 8434ae42a3)
2019-05-08 04:22:49 -04:00
Ell
2d91f1ca02 Issue #3353 - Gimp 2.10.10 freezes while changing Background color ...
... in LCh colorspace

In gimptoolbox-color-area, when setting the context's background
color in response to a color-dialog change, block the right signal
handler, to avoid re-setting the color dialog's color, which would
cause the GtkAdjustment's "value-changed" signal (assuming it was
the source of the change) to be restarted if the new value doesn't
match the current one exactly, which can happen due to conversion
errors.

(cherry picked from commit c7a29e5f98)
2019-05-08 03:45:16 -04:00
Jehan
7b1af1f0cb app: round curve point position when displaying it as int.
Int casting results to truncation. First this is a bit counter-intuitive
as we usually expect rounding to the nearest integer. Moreover with the
new GUI updates on curve and curve tool, we end up with a mismatch as
the new Input/Output spin buttons where indeed showing rounded integers
whereas the coordinate indicator was showing truncated integers.

Make all these show same rounded value.
2019-05-08 13:58:45 +09:00
Ell
95ea4e4272 Issue #3284 - Wrong layer renamed when switching images
In gimp_container_tree_view_clear_items(), temporarily unset the
tree-view's model before clearing it, so that name editing is
stopped beforehand.  Otherwise, name editing is stopped once the
corresponding item is removed from the store, causing us to rename
the wrong item.

(cherry picked from commit bb8648a2e9)
2019-04-21 10:35:08 -04:00
Ell
6de686bd50 Issue #3275 - Crash when opening an image after closing existing image
In gimp_open_dialog_set_image(), use a weak pointer for storing the
current image, to avoid a segfault in file_open_dialog_response()
if the active image at the time of the open action has been closed
before confirming the dialog.

(cherry picked from commit b01113741e)
2019-04-20 14:53:26 -04:00
Ell
001acb7d18 app: add smooth/corner curve-point types
Allow setting the type of GimpCurve control-points to either SMOOTH
or CORNER.  Smooth points produce a smooth curve, while corner
points produce a sharp curve (previously, all points were smooth).

In GimpCureView, display corner points using a diamond shape,
instead of a circle.

In the Curves tool, allow changing the curve's point types.

(cherry picked from commit 33e47c85a2)
2019-04-19 10:36:28 -04:00
Ell
9861ea8e87 app: add "selection-changed" signal to GimpCruveView
... which gets emitted when the selected point changes.

(cherry picked from commit 91ecca7e10)
2019-04-19 10:36:27 -04:00
Ell
b5da9918f1 app: streamline GimpCurve
In GimpCurve, replace the use of a fixed-length control-point array
with a dynamically-sized array.  Adapt GimpCurve's interface, and
the rest of the code.

In addition to simplifying the code, this fixes a bug where the
curve object could be broken by moving the mouse too fast (yep...),
and allows more accurate point placement, both in the GUI editor,
and through canvas interaction in the Curves tool (see issue #814).

(cherry picked from commit b6d829a1b2)
2019-04-19 10:36:25 -04:00
Ell
65a2a2fd8b app: in GimpCurveView, snap to curve when holding Ctrl
In GimpCurveView, when holding down Ctrl while adding/dragging a
point, snap the y-coordinate to the original curve (at the start of
the drag).  This is particularly useful for adding points along the
curve, without changing their y-coordinate.

Likewise, have the coordinate indicator show the snapped
coordinate.

(cherry picked from commit 8357c9ad64)
2019-04-17 18:00:25 -04:00
Ell
1ecb868821 app: in GimpCurveView, use relative motion when dragging point
In GimpCurveView, when dragging an existing curve point, don't
immediately move the point to the cursor position uppon button
press, but rather move it relative to its current position as the
cursor moves.  This allows selecting a point without moving it, and
adjusting its position more easily.

Additionally, when the cursor hovers above a point, or when
dargging a point, have the coordinate indicator show the point's
position, rather than the cursor's.

(cherry picked from commit 0b9737a3ed)
2019-04-17 18:00:25 -04:00
Ell
8c7e2a9e03 Issue #3025 - "File/New" doesn't honor "precision" choice ...
... for "Edit/Preferences/Default Image"

In GimpTemplateEditor, don't use gimp_prop_enum_combo_box_new() for
the "Precision" combo-box, and rather synchronize the combo-box and
the template manually, since we only want to update the "Gamma"
combo-box according to the precision when it changes through the
UI, and not when the template's precision otherwise changes.

This fixes an issue where we'd always set the default gamma value
when resetting the editor's template, overwriting the template's
original gamma value.

(cherry picked from commit 033082dd9a)
2019-03-31 15:18:59 -04:00
Ell
f19ebb6269 app: revert combo-box drop-down changes
Revert the use of gtk_combo_box_set_wrap_width() to change the
combo-box drop-down style, except for the status-bar unit combo.
See https://gitlab.gnome.org/GNOME/gimp/issues/2828#note_421312 for
the rationale.

This reverts commits 1d984542e9,
68a33ab5bd, and
6dfca83c2a.

(cherry picked from commit 846d242f30)
2019-03-27 20:14:45 -04:00
Alex Samorukov
8f3da0e8c4 Allow compilation on MacOS 10.5 leopard: issues #2923, #2924 and #2925 2019-03-23 23:33:07 +00:00
Ell
f8aec23e33 app: avoid pushing undo while updating colormap entries
In GimpColormapEditor, while updating a colormap entry, only push
an undo step when confirming the new color.

(cherry picked from commit 506f412a05)
2019-03-13 10:57:19 -04:00