Commit Graph

4537 Commits

Author SHA1 Message Date
Michael Natterer 76782e622d app: add "gboolean convert_profile" to GimpDrawable::convert_type()
also add "GType old_type" to GimpItem::convert() so implementations
can do things depending on the type of the original item.

In gimp_layer_convert(), if the original item is also a layer, and
color management is not off (with a FIXME because this is the wrong
check), pass convert_profile = TRUE to gimp_drawable_convert_type().

There is no color profile conversion anywhere behind this, this is
just an API change commit.
2015-08-16 15:56:28 +02:00
Michael Natterer 1ca3812396 app: rename gimpimage-profile.[ch] to gimpimage-color-profile.[ch] 2015-08-02 22:18:43 +02:00
Michael Natterer fd873465af app: use better filenames when saving via the XDS protocol
Like IMG_0001.xcf instead of Untitled.xcf if the image was imported
from IMG_0001.JPG.
2015-07-13 03:48:18 +02:00
Michael Natterer c102dde92b libgimpcolor, *: change GimpColorProfile to be a GObject
it used to be a typedef to gpointer and actually was a cmsHPROFILE.

Change its API to be more "standard", remove the public close()
function. The object caches both the cmsHPROFILE and the data/length
ICC blob, so conversions between the two become obsolete (simply call
get_lcms_profile() or get_icc_profile()).

Adapt everything to the new API, but port it in a naive way for now,
the code doesn't take advantage of the new possibilities yet (like
refcounting).
2015-07-10 22:53:59 +02:00
Michael Natterer df3f7b01e6 Bug 751645 - tagbox dialog not showing lower tags
gimp_tag_popup_constructed(): calculate the height of the scrollable
area correctly.
2015-07-04 14:04:35 +02:00
Michael Natterer db09d0f3d3 app: move functions to create layers to new files gimplayer-new.[ch] 2015-06-17 13:21:01 +02:00
Michael Natterer aeb2a6e4ff Bug 646511 - Having the possibility to remove ICC profiles
Add Image -> Color Management -> Discard Color Profile which simply
removes the profile without any conversion.

Also added actions and callbacks for "Assign" and "Convert" but these
are only stubs to be filled as replacement for the remaining code in
the lcms plug-in.
2015-06-15 20:19:32 +02:00
Jehan 0aae50cfe2 Bug 750556 - validate a tree cell modification on focus out.
For instance, modifying a layer and going directly to draw in the canvas
should not cancel the layer name.
You can still cancel a layer renaming in progress with ESC.
2015-06-14 14:03:16 +02:00
Michael Natterer 31aa1269ec Bug 749777 - Deleting current gradient from script leads to...
GIMP_IS_TAGGED error and possible Gimp crash (core segfault)

Fix again by restoring code I accidentially deleted in
ae708d6419. I don't really understand
what it is doing but better not remove it without understanding.
2015-06-06 23:06:20 +02:00
Michael Natterer 4910c28957 libgimpcolor: rename the gimp_lcms_*() functions to gimp_color_profile_*()
because it doesn't make sense to call the typedef GimpColorProfile
but the function namespace gimp_lcms_*().
2015-06-03 09:41:23 +02:00
Thomas Manni a7b84ded8e Bug 325564 - Use CIE LCH instead of HSL for layer mode Color
Add Hue, Chroma, Color and Lightness layer modes in LCH color space.
2015-06-02 01:37:26 +02:00
Michael Natterer ae708d6419 Bug 749777 - Deleting current gradient from script leads to...
GIMP_IS_TAGGED error and possible Gimp crash (core segfault)

Remove the object from GimpTagEntry's selected_items when it is
removed from the GimpContainer.
2015-05-31 00:31:40 +02:00
Michael Natterer 281a529b0c app: use gimp_color_managed_get_color_profile()
instead of gimp_image_get_color_profile() and remove all fallback
code, GimpColorManaged always returns a profile.
2015-05-30 00:58:22 +02:00
Michael Natterer e06a620d11 app: rename gimp_image_get_profile() to _get_color_profile() 2015-05-30 00:47:13 +02:00
Øyvind Kolås 7e6320497e follow gegl api changes from commit af5361ca8d, with an abyss policy argument
to gegl_buffer_copy.
2015-05-25 01:27:31 +02:00
Simon Budig 6ce2a2b3ad app: more actions for display rotation 2015-05-17 04:13:43 +02:00
Michael Natterer 6b0b774302 libgimpwidgets: add gimpwidgetsutils.[ch]
Move some functions from libgimpwidgets/gimpwidgets.[ch]
and from app/widgets/gimpwidgets-utils.[ch]. Newly add
gimp_widget_get_color_profile() which is extracted from
modules/display-filter-lcms.c.
2015-05-06 22:15:30 +02:00
Michael Natterer 6c800db1cc Use the newly added profile utility functions all over the place 2015-05-06 16:38:57 +02:00
Michael Natterer 072cb068b2 app: add a "detach" button to all on-canvas tool dialogs
which turns them from being automatically attached/detached (depending
on canvas size) into always being a separate window.
2015-05-01 18:00:05 -04:00
Michael Natterer bc4cf9918f Bug 673501 - Issue with Overlay
GIMP's OVERLAY mode was identical to SOFTLIGHT. This commit fixes the
issue and introduces a NEW_OVERLAY mode and enum value.

- change gimp:overlay-mode to be a real (svg-ish) overlay mode
- when compositing, map OVERLAY to gimp:softlight-mode
- when compisiting, map NEW_OVERLAY to gimp:overlay-mode
- bump the XCF version when NEW_OVERLAY is used
- map OVERLAY to SOFTLIGHT when loading and saving XCF
- map OVERLAY to softlight in all PDB setters
- map OVERLAY to softlight when deserializing a GimpContext
- change all paint mode menus to show an entry for NEW_OVERLAY
  instead of OVERLAY
- change PSP, PSD and OpenRaster to use NEW_OVERLAY

These changes should (redundantly) make sure that no OVERLAY enum
value is used in the core any longer because it gets mapped to
SOFTLIGHT at all entry points, with the downside of introducing a
setter/getter asymmetry when OVERLAY was set in a PDB api.
2015-04-29 13:32:58 -04:00
Michael Natterer 9d510d8fff app: make the MyPaint brush path configurable in Prefs -> Folders
Keep the config values around even if compiled without MyPaint brush
support, so we remember the values between sessions of differently
compiled GIMP versions.
2015-04-25 21:14:22 -04:00
Michael Natterer 8fd282dd28 app: fix typo in "cursor-side-top.png" to make that cursor work again 2015-04-15 21:51:45 +02:00
Michael Natterer 7c36f94f7f cursors,app,libgimpwidgets: include cursors using GResource
instead of deprecated inline pixbufs. Require on gdk-pixbuf >= 2.30.8.
2015-04-14 22:55:10 +02:00
Michael Natterer 6ea9b5c3cf app: connect the MyPaint brush radius to the tool tip size action 2015-03-30 22:38:35 +02:00
Michael Natterer 071ede915a app: first draft of GimpMybrushTool, which uses MyPaint brushes 2015-03-30 22:38:34 +02:00
Hartmut Kuhse ef66ea296d app: don't assign variable before checking the validity 2015-03-09 08:28:33 +01:00
Johannes Matschke 2989bad35a Bug 721009 - new transform tool with freely placeable handles
Add new tool GimpHandleTransformTool which allows to freely place up
to 4 handles on the image, then move any one of them, which transforms
the image so that the remaining handles keep their position.

Did quite some cleanup on the code before pushing --Mitch
2015-03-05 12:36:59 +01:00
Marek Dvoroznak f15a7bc71d app: add NPD tool basics 2015-02-27 20:21:51 +01:00
Michael Natterer dcfe0b8925 app: fix uninitialized boolean in gimp_paned_box_drag_drop() 2015-02-24 23:29:39 +01:00
Michael Natterer f425f539f8 app: fix the brush editor to not dirty every brush set on it
gimp_brush_editor_update_brush(): only set the brush property whose
GtkAdjustment has changed, and only set it if it is different from the
current value. Before, simply setting a brush on the editor would
cause all properties to be written back to the brush unconditionally.

gimp_brush_editor_notify_brush(): unrelated cleanup: use brush
accessors instead of direct struct access, remove an update of the
radius property from the shape updating code that was probably left
over from copy and paste.
2015-02-24 20:23:55 +01:00
Michael Natterer 1af244b39c app: same fix as below in GimpDataFactoryView
gimp_data_factory_view_tree_name_edited(): change the GimpData's name
only if it actually changed.
2015-02-24 19:17:50 +01:00
Michael Natterer 1105e6455e app: change a GimpData's name only if it actually changed
gimp_data_editor_name_activate(): don't set a new name if it's the
same as the old one.
2015-02-24 19:07:39 +01:00
Michael Natterer 29456b96f9 Bug 744127 - Restore tab hover delay during drag-n-drops
Fix the return values of drag_motion() and drag_drop() callbacks.

Commit 7b85cf4de8 started mixing up
the two unrelated concepts

- the widgets has handled the event
- a drop here would do something / did something successfully

into one boolean value being both the function's return value and
a success indicator for the DND operation.

Untangle the concepts again by returning FALSE when
gimp_paned_box_will_handle_drag() returns TRUE (indicating that the
docking DND mechanism will kick in), and always returning TRUE
otherwise; and by using the state "drop was / would be successful"
only for calling gdk_drag_status() and gtk_drag_finish().

This way we make sure that:

- drag_leave() is called reliably again (because we return TRUE if no
  other widget will handle the event)
- drag data is freed reliably again (because we always call
  gtk_drag_finish())
2015-02-19 22:42:18 +01:00
Michael Natterer d3600ab379 app: add File -> Copy Image Location 2015-02-17 13:33:10 +01:00
Michael Natterer 39db88d0a5 app: add much more "Show in file manager" menu items
Brushes, patterns, documents, ...
2015-02-16 20:29:31 +01:00
Michael Natterer e448cc3173 libgimpbase, app: implement File -> Show in File Manager
Add gimp_file_show_in_file_manager() to libgimpbase and a menu item
in app which shows the image's file (if any) in the file manager.

Implemented calling the org.freedesktop.FileManager1 interface
and dropped snippets found on stackoverflow for somebody to
turn into working code for OSX and Windows.
2015-02-16 18:40:26 +01:00
Michael Natterer c2371a2de9 app: implement Dilate and Erode as wrappers around gegl:value-propagate
Add them to the "drawable" actions. Remove menu registration for
the value-propagate plug-in's dilate and erode procedures.
2015-02-08 19:56:45 +01:00
Michael Natterer 9d75844b7a app: add a custom GUI for gegl:diffraction-patterns 2015-02-06 19:43:49 +01:00
Massimo Valentini 09c5fcc32b Bug 742775: Crash when editing text with certain fonts 2015-02-03 18:33:12 +01:00
Kristian Rietveld e2d2bdf65c app: ifdef out functions that are unused
Silences compiler warnings.
2015-01-10 00:03:04 +01:00
Kristian Rietveld cea42c73d8 app: fix implicit enum casting
Silences clang.
2015-01-10 00:02:28 +01:00
Kristian Rietveld 6b6baa6b91 app: fix function signature 2015-01-09 23:47:13 +01:00
Kristian Rietveld dd7d332fb8 Bug 736746 - Alt+Number only switches to lower-numbered windows
Add "action-group" signal to GimpActionGroup, such that we can
properly set the accel group and connect the accelerator on actions
that are created after the initial setup of the menus.
2015-01-09 23:02:24 +01:00
Michael Natterer 47595b5615 app: use GimpFrames in _gimp_prop_gui_new_channel_mixer() 2014-12-07 20:12:29 +01:00
Alexia Death 44be17a8c1 app: Custom gui for channel mixer 2014-12-07 19:57:28 +02:00
Michael Natterer 16d2031136 Bug 739369 - Rendering artifacts in the tool in-canvas UI with opacity
Don't disable double buffering in GimpOverlayBox, we don't do it for
the canvas any longer, and removing that code fixes the artifacts.
2014-12-01 21:50:57 +01:00
Michael Natterer 73e4828556 app: use g_signal_connect_object() to connect the history to the color dialog
It crashed when the history changed after a dialog way destroyed.
2014-11-29 13:48:00 +01:00
Michael Natterer c0365c04e7 app: connect GimpColorDialog to the history palette's "dirty" signal
instead of having a ton of convoluted legacy code doing the same
manually. Simpler and more obvious code.
2014-11-29 13:33:56 +01:00
Michael Natterer bebdcbe0bf app: change enum GimpColorPickState to { START, UPDATE, END }
It used to be { NEW, UPDATE } but that didn't allow to distinguish the
final END update, which we will soon need for automatic color history
updating. Make sure all places that handle motion events on colors
(pick from canvas, gradient editor) correctly send and handle END
events.
2014-11-28 12:00:53 +01:00
Michael Natterer 09628cfa4c Bug 739489 - Add palette of recently used colors
Add a generated palette which contains the color history. For now it's
only updated when the color dialog's color history gets updated, but
should be updated whenever a color is chosen in any way.
2014-11-26 23:48:19 +01:00