Commit Graph

1726 Commits

Author SHA1 Message Date
Michael Natterer e8a5f285a7 app: change GimpBuffer to keep around an actual GimpColorProfile
not an icc_data blob. This simplifies the code using GimpBuffers
together with color profiles.
2015-08-16 13:14:56 +02:00
Michael Natterer fa5d28aad3 plug-ins, pdb: remove "set" and "set-rgb" from the lcms plug-in
and add PDB compat procedures.
2015-08-05 01:03:33 +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 96749a440e pdb, libgimp: add gimp_image_convert_color_profile_from_file() 2015-07-28 23:11:54 +02:00
Michael Natterer b0735c9448 pdb, libgimp: add gimp_image_set_color_profile_from_file()
which sets the profile from a file containing an ICC profile.
2015-07-28 23:01:18 +02:00
Michael Natterer ccd2264a4c pdb: reorder procedures in image_color_profile.pdb 2015-07-27 23:45:25 +02:00
Michael Natterer 597a438f07 app: remove gimp_image_set_filename()
- gimp-image-set-filename PDB wrapper: implement the same there in
  a few lines
- xcf-load.c: use gimp_image_set_file() instead, and get rid of the
  last use of filename in xcf/ in favor of GFile
2015-07-13 22:43:22 +02:00
Michael Natterer 0693298d63 libgimpcolor, *: change all GimpColorConfig getters to return const gchar*
instead of a gchar* which has to be freed. Cache all the strings in
the GimpColorConfig instance.
2015-07-12 14:10: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 d6c578c567 app: change gimp_image_crop() to use x, y, width, height 2015-07-03 19:38:08 +02:00
Michael Natterer e90e90265b app: port everything from gimp_channel_bounds() to gimp_item_bounds()
except gimpchannel.c itself.
2015-07-03 19:38:08 +02:00
Michael Natterer 4552319336 pdb: fix plug-in-autocrop compat wrapper to work like in 2.8
even if it's weird, compat is compat...
2015-07-03 17:59:08 +02:00
Thomas Manni 82223783a3 plug-ins, pdb: remove the bump-map plug-in and add 2 PDB compat procs 2015-06-30 12:02:48 +02:00
Thomas Manni 3436ae4674 plug-ins, pdb: remove the displace plug-in and add 2 PDB compat procs 2015-06-30 10:02:28 +02:00
Michael Natterer 3c706d00c6 Bug 735906 - Transform tools give unexpected results when transforming...
...certain sets of linked layers

Fix for translating layers from the PDB, and with the cursor keys
for gimpeditselectiontool. Moving layers with the mouse is still broken.

The approach is exactly the same as in 25a696c7.
2015-06-26 12:00:45 +02:00
Michael Natterer 09cd5f6720 app: add ICC data/length parameters to gimp_layer_new_from_gegl_buffer()
and pass them where we know the buffer could be from another image.
Pass "NULL, 0" if we know it's the same image.

Add gimp_layer_new_convert_profile() which takes the newly created
layer and the ICC data/length; call it from both
gimp_layer_new_from_gegl_buffer() and gimp_layer_new_from_pixbuf().

gimp_layer_new_convert_profile() is empty, this is just
infrastructure.
2015-06-20 00:39:44 +02:00
Michael Natterer 6446c007cf app: rename gimp_layer_new_from_buffer() to gimp_layer_new_from_gegl_buffer()
and add new function gimp_layer_new_from_buffer() which takes a
GimpBuffer. This will make sense soon :)
2015-06-20 00:02:11 +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 bf10da29fa app: remove GError** argument from gimp_image_get_color_profile()
we validate everything when setting it, so this function always
returns either a valid profile, or NULL.
2015-06-17 00:45:43 +02:00
Thomas Manni 769bc933d4 plug-ins, pdb: remove the wind plug-in and add a PDB compat proc 2015-06-11 11:31:36 +02:00
Michael Natterer c632ffad18 pdb, app, libgimp: add gimp_image_convert_color_profile() PDB wrapper
This commit is more complex than a usual PDB procedure because it
needs to make the enums from libgimpconfig/gimpcolorconfig-enums.h
known to the PDB.
2015-06-10 01:38:20 +02:00
Michael Natterer d1102d2be9 pdb, plug-ins: remove two procedures from lcms.c and add PDB compat procs
The lcms plug-in is on its way out: add compat procedures implementing
plug-in-icc-profile-info and plug-in-icc-profile-file-info and remove
that code from lcms.c.
2015-06-07 12:52:37 +02:00
Michael Natterer 16749cd395 pdb, app, libgimp: add gimp_image_get_effective_color_profile()
which returns the profile that is actually used for the image. And
some cleanup and fixes in image_color_profile.pdb.
2015-06-07 01:38:50 +02:00
Michael Natterer 80093a85df pdb, app, libgimp: add new PDB group image_color_profile
Which will have proper API to deal with an image's color profile (no
parasites, no ICC blobs). So far contains gimp_image_get_color_profile()
and gimp_image_set_color_profile().
2015-06-05 12:51:46 +02:00
Michael Henning 9a969fb463 Bug 750377 - Fix a typo in the .pdb file
Not in the generated file, as e708f41970 did.
2015-06-04 18:48:54 -04: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 8005eea835 Remove the "GIMP" from all "Since: GIMP 2.x" API doc comments
because it confuses gtk-doc and breaks some links. Also change the
"Index of new symbols in GIMP 2.x" sections to be what seems to be the
modern standard (looked at the GLib and GTK+ docs), and update some
other stuff.
2015-05-31 21:18:09 +02:00
Michael Natterer 4ef3c918a0 pdb, app, libgimp: move the image transform procedures to their own PDB group
because image.pdb is way too large.
2015-05-30 23:55:58 +02:00
Michael Natterer b9773efa5e pdb, app, libgimp: rename the "guides" PDB group to "imageguides"
This only renames files, no code changes.
2015-05-30 15:27:16 +02:00
Michael Natterer 3b70fb8d3a pdb, app, libgimp: rename the "grid" PDB group to "imagegrid"
This only renames files, no code changes.
2015-05-30 15:19:11 +02:00
Michael Natterer b34ed029ac pdb, app, libgimp: rename the "convert" PDB group to "imageconvert"
This only renames files, no code changes.
2015-05-30 15:09:57 +02:00
Michael Natterer f269651cc6 pdb, app, libgimp: rename the "undo" PDB group to "imageundo"
This only renames files, no code changes.
2015-05-30 15:01:50 +02:00
Michael Natterer e6703aa6b8 plug-ins, pdb: remove the papertile plug-in and add a PDB compat proc 2015-04-30 17:18:01 -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 573f0f69bb plug-ins, pdb: remove the edge plug-in and add a PDB compat procedure 2015-03-03 23:18:53 +01:00
Michael Natterer b856a8ba76 plug-ins, pdb: remove the value-propagate plug-in and add PDB compat procedures 2015-02-08 23:09:06 +01:00
Michael Natterer 9be37aaa91 plug-ins, pdb: remove the diffraction plug-in and add a PDB compat procedure 2015-01-21 22:51:49 +01:00
Michael Natterer b87d97ae68 plug-ins, pdb: remove the lens-flare plug-in and add a PDB compat procedure 2015-01-08 23:39:03 +01:00
Michael Natterer 4d5e42ac1a plug-ins, pdb: remove the engrave plug-in and add a PDB compat procedure 2014-12-15 23:54:35 +01:00
Alexia Death 6f582ba527 pdb: make channel-mixer compat function use mono-mixer for monochrome mode
This is preparation of removing monochrome mode from the channel
mixer op, as there is already mono mixer doing the exact same thing
2014-12-11 00:30:23 +02:00
Michael Natterer 7313cb559e plug-ins, pdb: remove the illusion plug-in and add a PDB compat procedure 2014-12-04 20:42:15 +01:00
Michael Natterer fabbc9ac48 pdb: fix the doc_title of plug_in_compat.pdb 2014-11-22 23:11:23 +01:00
Michael Natterer 212b44cf2f plug-ins, pdb: remove the Solid Noise plug-in and add a PDB compat procedure 2014-11-22 21:04:31 +01:00
Michael Natterer b49e8098d4 plug-ins, pdb: remove the sinus plug-in and add a PDB compat procedure 2014-11-21 22:11:15 +01:00
Michael Natterer b94ba871ac plug-ins, pdb: remove the nova plug-in and add a PDB compat procedure 2014-11-18 21:05:32 +01:00
Michael Natterer a101ed2aef app, pdb: change range of brush-spacing to 0.01..5.0
And only use percent in the GUI.
2014-11-17 23:56:16 +01:00
Michael Natterer b4f721cdfb pdb: set value ranges on PDB brush parameters/return values
Also fix a few glitches and spelling.
2014-11-17 23:18:22 +01:00
Alexia Death bac099e71b pdb: remove copy-paste error 2014-11-17 21:48:03 +02:00
Alexia Death 60cf10f581 pdb: add pdb calls for hardness and force 2014-11-17 15:29:45 +02:00
Michael Natterer e78540e581 plug-ins, pdb: remove the video plug-in and add a PDB compat procedure 2014-11-16 22:08:51 +01:00
Michael Natterer 78120dcb87 pdb: new procedures get the next stable version, so 2.10 not 2.9 2014-11-15 22:15:27 +01:00
Alexia Death 6f4fb84645 pdb: pdb definitions for spacing in tool options 2014-11-13 14:49:12 +02:00
Michael Natterer effeefb84a plug-ins, pdb: remove the color-exchange plug-in
and add a PDB compat procedure.
2014-11-10 22:40:58 +01:00
Michael Natterer e47ded9420 pdb: fix gimp-file-open and gimp-file-save for GIO-ported file procedures
Pass URIs instead of filenames to the procedures if they are ported to GIO.
2014-10-18 01:14:58 +02:00
Michael Natterer 5d8824f42e app: move all GimpBrush members to a private struct
Add and use accessors for width, height, x_axis and y_axis.
2014-10-12 01:16:32 +02:00
Michael Natterer e4171c5bff plug-ins, PDB: remove edge-sobel and add a PDB compat procedure 2014-10-11 19:41:49 +02:00
Michael Natterer bda1cd049d Bug 735516 - Crop to content fails
Return a new enum GimpAutoShrink { SHRINK, EMPTY, UNSHRINKABLE } from
gimp_pickable_auto_shrink() because a simply boolean FALSE doesn't
distinguish between "not further shrinkable" and "no content". Change
the callers accordingly add a special "already cropped" message where
we only had a "no content" message before.
2014-08-31 17:41:54 +02:00
Michael Natterer 1326cc5562 pdb: fix uninitialized variable warning in the convmatrix compat wrapper 2014-08-29 21:37:17 +02:00
Mikael Magnusson 8b9696a7fa plug-ins, pdb: Add missing break statements to switch in correct file 2014-08-18 01:34:00 +02:00
Michael Natterer 14c39816d8 app: keep the theme directories around a GFiles
and change gimp_get_theme_dir() to return a GFile.
2014-07-20 17:09:25 +02:00
Michael Natterer a6601d563b app: some GimpProgress cleanup
- change start() and set_text() to use "format" and "..." instead of
  "message", allowing to format progress messages in place
- s/cancelable/cancellable/
- move "cancellable" to be the second argument of start()
2014-07-12 23:45:20 +02:00
Michael Natterer a4b807905c app: change gimp_get_temp_filename() to gimp_get_temp_file() 2014-07-10 22:32:09 +02:00
Michael Natterer c1f7ec52a8 app: add gimp_pdb_image_get_guide() and use it in the guide PDB wrappers
It returns a proper error message if a guide ID doesn't exist.
2014-07-10 20:24:10 +02:00
Michael Natterer ad9fd33915 app: guide cleanup
- Move all GimpGuide members to a private struct
- Remove cruft checks for position < 0, we don't keep removed guides
  around in the image's guide list since a long time ago
- Add #define GIMP_GUIDE_POSITION_UNDEFINED G_MININT and use that
  instead of -1 (this is also a prerequisite for having guides
  outside of the image)
2014-07-10 00:20:57 +02:00
Michael Natterer c3573c3c45 app: keep the plug-in executable path around as GFile 2014-07-08 21:09:35 +02:00
Michael Natterer c884c4f630 app: change file_utils_filename_to_uri() to file_utils_filename_to_file() 2014-07-08 10:25:25 +02:00
Michael Natterer d0a6d95dad app: remove a bunch of file-utils.h includes 2014-07-08 00:23:34 +02:00
Michael Natterer ff6ea69569 app: change the image's various URIs to GFiles
which gets rid of a lot of temporarily added GFile code again because
we don't need to convert between URI and GFile any longer.
2014-07-07 23:58:11 +02:00
Michael Natterer 0f8d84d5e9 app: port all file_open() and file_save() functions to GFile 2014-07-07 23:58:11 +02:00
Michael Natterer 249041d927 Bug 732698 - Select > Shrink/Grow/Border not working in GIMP master
Always pass level = 0 to gegl_buffer_set(). This actually makes a
difference since GEGL's level processing got some fixes.
2014-07-03 20:47:02 +02:00
Michael Natterer 70e6d86bdf app: port gimp_pdb_dump() to GIO 2014-07-03 14:52:27 +02:00
Michael Natterer 3687e1b32b app: change filename in gimp_vectors_import_file() to GFile 2014-07-02 14:54:56 +02:00
Michael Natterer 632b64fedf app: change filename in gimp_vectors_export_file() to GFile 2014-07-02 14:47:11 +02:00
Michael Natterer 98f97a9580 libgimp, pdb: port gimp_drawable_curves_explicit,spline() to double
and deprecate gimp_curves_explicit,spline().
2014-06-17 22:37:46 +02:00
Michael Natterer f5e4f01c52 app: make gimp_curves_config_new_spline,explicit() handle variable #points
Also, append _cruft to the function name because they take guint8*
arrays, will add proper ones next.
2014-06-17 21:10:33 +02:00
Michael Natterer a5fe6c244f app: same fix for gimp_drawable_curves_explicit()
whch is about to change anyway, but better start refactoring from
a correct state.
2014-06-17 20:31:25 +02:00
Michael Natterer fabcf2ccfe pdb: actually create a free curve in the gimp_curves_explicit() wrapper
It was creating a spline curve that was entirely broken.
2014-06-17 20:23:02 +02:00
Michael Natterer e2628b9bd0 app: revive gimpdrawable-foreground-extract
Move the extraction graph from the foreground select tool there.
Enable the PDB wrapper again, using default values for now.
Some sytle cleanup in the foreground select tool.
2014-06-03 23:05:23 +02:00
Michael Natterer ee3846cc8b app: make the gimp_drawable_fill*() API symmetric to gimp_edit_fill*() 2014-06-03 14:11:59 +02:00
Michael Natterer 38c86da8e9 app: factor out utility function gimp_get_fill_params()
which returns an error if there is no pattern for GIMP_FILL_PATTERN.
Use it instead of having the same code in 3 variants, and make error
handling consistent with bucket fill.
2014-06-03 14:00:01 +02:00
Michael Natterer 1416743b5c app: use GimpFillType in gimp_drawable_bucket_fill()
GimpBucketFillMode is now tool- and pdb-only.
2014-06-03 01:34:51 +02:00
Michael Natterer 425748dab0 libgimpbase, *: rename GimpFillType values: GIMP_FOO_FILL -> GIMP_FILL_FOO
Change all users accordingly and add compat enum values and compat
constants to script-fu and pygimp.
2014-06-03 01:11:32 +02:00
Michael Natterer f15b48b3c8 plug-ins, pdb: remove convolution-matrix and add a PDB compat procedure 2014-05-29 16:27:35 +02:00
Michael Natterer 4fbaff92a1 pdb: replace \1 \2 \3 by $1 $2 $2 as suggested by perl warning 2014-05-29 16:26:16 +02:00
Ed J 345bf01c01 Doc that gimp-display-new gives execution error if no GIMP GUI. 2014-05-27 00:56:05 +01:00
Michael Natterer 3e6a7f4012 pdb, plug-ins: remove the rotate plug-in and add a PDB compat procedure 2014-05-24 22:46:11 +02:00
Michael Natterer 41fc19e7b3 pdb: fix workarea of some plug-in compat procecures
If the removed plug operated on the selection bounds, translate and
crop the GEGL op accordingly to get the same result. Also adapt to
new relative coordinates in some GEGL ops.
2014-05-24 00:47:23 +02:00
Michael Natterer 40030e084b plug-ins, pdb: remove the deinterlace plug-in and add a PDB compat proc 2014-05-20 21:30:42 +02:00
Michael Natterer c452f12519 pdb: normalize the compat motion blurs' angles to -180..180 2014-05-18 22:33:11 +02:00
Michael Natterer 2ce79d3b13 plug-ins, pdb: remove the tile-glass plug-in and add a PDB compat procedure 2014-05-16 22:11:28 +02:00
Michael Natterer 6c7fae9e11 app, libgimp*, pdb: move more enums from app/core to libgimpbase 2014-05-14 00:06:01 +02:00
Michael Natterer 9dde82b215 libgimpbase: sort gimpbaseenums.h alphabetically 2014-05-13 23:29:17 +02:00
Michael Natterer f636b4ad34 app, libgimpbase: move lots of enums from app/core to libgimpbase
It makes little sense to keep them in one header and parse them with a
pile of perl, just to generate them in another header. Simply keep
them in a place everybody depends on.
2014-05-13 00:27:29 +02:00
Michael Natterer de08267f06 libgimpbase, *: add enum value GIMP_ICON_TYPE_ICON_NAME
and keep GIMP_ICON_TYPE_STOCK_ID as a deprecated alias. Change all
plug-ins accordingly and increase the pluginrc file version number so
it gets regenerated with "icon-name" instead of "stock-id".
2014-05-11 23:56:30 +02:00
Michael Natterer d9cf36d07d app: remove gimp:cast-format and use gegl:cast-format 2014-05-05 19:30:21 +02:00
Michael Natterer 64290145a2 pdb. plug-ins: remove the noise-rgb plug-in and add PDB compat wrappers 2014-05-04 23:43:02 +02:00
Michael Natterer ff59aebbe8 pdb, plug-ins: remove the blur-gauss plug-in and add compat procedures
Add a utility function to wrap PDB compat nodes in gimp:cast-format
ops, so we can use ops that are now implemented in linear RGB for
plug-in compat procedures, which are all supposed to work on gamma
corrected RGB.
2014-05-04 22:53:29 +02:00
Ed J 7338c0309e Document other layer_group-relevant procedures in gimp_layer_group_new. 2014-05-03 03:38:38 +01:00
Michael Natterer 7f23fbec34 app: add screen and monitor to all display and image window constructors
so they appear on the proper monitor as well.
2014-05-02 20:21:41 +02:00
Michael Natterer b60e1779cd app: pass a GimpGradient to gimp_drawable_blend(), not a GimpBlendMode
The blend mode is now only a PDB compat enum, translate between
GimpBlendMode and the built-in gradients in the gimp-edit-blend PDB
wrapper.
2014-04-30 09:17:42 +02:00
Michael Natterer a4223766f2 all,libgimp*: move GimpConvolveType and GimpInkBlobType to libgimpbase
and make GimpConvolveType's values sane.
2014-04-29 22:44:58 +02:00
Michael Natterer f7d71e2eda pdb: don't scan headers that don't contain PDB-exported enums 2014-04-29 21:08:34 +02:00
Michael Natterer 22c222291d libgimpbase,*: clean up enum values in gimpbaseenums.h
GIMP_ADD_foo_MASK -> GIMP_ADD_MASK_foo
GIMP_foo_MODE -> GIMP_BLEND_foo
GIMP_foo_CLONE -> GIMP_CLONE_foo
GIMP_foo -> GIMP_DODGE_BURN_TYPE_foo
GIMP_foo -> GIMP_TRANSFER_foo

Add compat values for the old names and compat code to script-fu
and pygimp.
2014-04-29 20:58:30 +02:00
Michael Natterer bcce8c95ec Bug 729158 - Internal inconsistent state with gimp_image_get_selection...
+ gimp_channel_copy

Make gimp-channel-copy always return a GimpChannel, and fail the
prodecure if the input channel is not of image size.
2014-04-29 09:16:19 +02:00
Michael Natterer 2ff414d799 app,libgimp,pdb: remove enum GimpConvolutionType from the public API
It was exported accidentially and never used for anything.
2014-04-27 23:05:12 +02:00
Michael Natterer 8ce94d23b9 libgimpbase: move GIMP_REPEAT_TRUNCATE to the end of the enum
New values must go to the end to avoid ABI break.
2014-04-24 23:08:33 +02:00
Michael Natterer 0a9dc8b297 libgimpbase: exclude GIMP_INTERPOLATION_LANCZOS from the PDB again
An unmentioned fix in the previous commit to this file made it visible
to the PDB.
2014-04-24 23:04:52 +02:00
João S. O. Bueno ad4862c60b Adds new blending mode 'Truncate blend'
Bring repeat behavior on par with GEGL and Cairo,
and sane ways of creating square or circular gradient
shapes.
2014-04-24 12:18:26 -03:00
Michael Natterer 36ca865aaa pdb: use boolean not int32 for booleans in the apply lens compat wrapper 2014-04-14 13:05:28 +02:00
Michael Natterer 260a4a51b1 plug-ins, pdb: remove the lens-apply plug-in and add a compat procedure 2014-04-13 21:18:35 +02:00
Michael Natterer 60f23afde2 app: add a small infrastructure to validate known parasites
when they are added to items, images or globally, from the PDF or an
XCF file. None of the validation functions does anything currently,
they simply return TRUE.
2014-03-22 00:18:48 +01:00
Michael Natterer fea22c345c Bug 706361 - Printer queue dosn't show the filename of the printing image
Change the gimp-image-get-name procedure to return the same string
as shown in the image title, and mention in its API docs that this
string is meant for annotating UI elements only.
2014-03-15 17:53:10 +01:00
Michael Natterer e7ff0589cb app: shuffle precision enum values around to make room for U64
and add code to handle the old values from XCF files < version 7.
2014-03-09 01:46:08 +01:00
Michael Natterer 3c918353fb app: add double precision support, for completeness
and because it makes us look utterly cool.
2014-03-09 00:43:55 +01:00
Michael Natterer 4d6640ff79 Bug 721249 - pdb.gimp_context_set_brush_size() dont't work
Port selection/path stroking to using the PDB-controllable
paint options that live in GimpPDBContext.

Change gimp_item_stroke()'s "use_default_values" boolean which was
introduced at a time where we had no better way by a GimpPaintOptions
parameter. If a non-NULL paint_options is passed (when called from the
PDB), use it for stroking; if NULL is passed, use the actual paint
tool options from the GUI (when called from the menus or the stroke
dialog). In the PDB wrappers, get the right paint options object from
the PDB context associated with the calling plug-in.
2014-02-06 23:26:53 +01:00
Michael Natterer 9fe869236b Bug 721249 - pdb.gimp_context_set_brush_size() dont't work
Don't reset the brush size before each PDB paint stroke.
2014-02-03 23:05:56 +01:00
Michael Natterer a96a0d0bed pdb: add translation context to the newly added PDB functions 2014-01-13 01:27:37 +01:00
Michael Natterer b4462e9e19 app,libgimp,pdb: add a "drawable_color" PDB group
Which contains all the API from the "color" group, but with a
gimp_drawable namespace and with support for high bit depths. The
group is actually a copy of "color" with cruft removed and some API
ported to using float instead of integer API.

Deprecated all "color" functions that already have a ported version in
"drawable_color".

This is unfinished WIP, some functions in "drawable_color" still have
the old API.
2014-01-12 23:12:21 +01:00
João S. O. Bueno 9c4995d7b0 Adds a hue-saturation PDB call with the 'overlap' parameter. Fixes #634008 2014-01-06 00:43:07 -02:00
Michael Natterer ef85845372 app: add gimp_paint_options_set_default_brush_size()
and use it globally instead of two different methods, one of which was
forgotten to be ported to the new aspect ratio range where 0.0 means
1:1. Add a FIXME comment in paint_tools.pdb where I think setting the
default size is a bug, see #721249.
2014-01-04 15:48:34 +01:00
Michael Natterer 2ea1c6e9a1 plug-ins, pdb: remove the apply-canvas plug-in and add a compat procedure 2014-01-01 19:21:00 +01:00
Michael Natterer 29d95f4c39 pdb: fix gimp_layer_new_from_drawable() PDB wrapper
We must always call gimp_item_convert() even if the source drawable is
in the same image, or we might end up with a layer of wrong pixel
format. This was probably broken for years.
2013-11-19 21:39:13 +01:00
Téo Mazars c41c2452c5 app,pdb: add a compatibility wrapper for contrast-stretch-hsv
... and remove the old plugin
2013-11-16 16:50:49 +01:00
Téo Mazars 120e9ccf39 app,pdb: add a compatibility wrapper to contrast-stretch
... and remove the old plug-in
2013-11-15 19:12:56 +01:00
Hartmut Kuhse 21bed1e2fb Completely rewrite metadata handling using gexiv2
Based on original patches from Hartmut Kuhse and modified
by Michael Natterer. Changes include:

- remove libexif dependency and add a hard dependency on gexiv2
- typedef GExiv2Metadata to GimpMetadata to avoid having to
  include gexiv2 globally
- add basic GimpMetadata handling functions to libgimpbase
- add image and image file specific metadata functions to libgimp,
  including the exif orientation image rotate dialog
- port plug-ins to use the new APIs
- port file-tiff-save's UI to GtkBuilder
- add new plug-in "metadata" to view the image's metadata
- keep metadata around as GimpImage member in the core
- update the image's metadata on image size, resolution and precision
  changes
- obsolete the old metadata parasites
- migrate the old parasites to new GimpMetadata object on XCF load
2013-10-27 01:02:17 +02:00
Téo Mazars f3d40dceec plug-ins,pdb: Add a compatibility wrapper for lens-distortion
... and remove the old plug-in
2013-10-11 08:48:09 +02:00
Téo Mazars 786b21ee10 app,pdb: Sort compatibility wrappers in alphabetical order 2013-10-11 08:03:51 +02:00
Jehan 008a40b877 pdbgen: fix trailing whitespaces in generated C doc in empty lines. 2013-10-05 19:48:39 +13:00
Jehan 1351226c80 pdb: gimp-image-new's doc updated.
Add the precision that indexed images must be set a colormap after
creation, otherwise colors won't be right.
2013-10-05 01:47:05 +13:00
Téo Mazars e1fe2e35cb plug-ins,pdb: Add a compatibility wrapper for edge-laplace
... and remove the old plug-in
2013-10-01 17:10:31 +02:00
Jehan cca6772714 Bug 709048 - improvement of gimp-layer-add-mask procedure's doc.
The documentation was missing information about GIMP_ADD_CHANNEL_MASK
mask type, also about possible failure cases, and had an unclosed
bracket typo.
Also make nicer output and list formatting with the new pdb paragraph
feature.
2013-10-01 01:02:49 +13:00
Michael Natterer 4f3d29e95d tools: remove some doc newlines in context.pdb 2013-09-27 18:55:01 +02:00
Jehan 9563a614f2 Bug 708033 - Add paragraph support for the long description in pdbgen
Single newlines in procedure descriptions are still considered normal
spaces. But 2 newlines are transformed into 1 newline. 3 newlines into
2 newlines. And so on.
This allows for a start of nicer output in the procedure browser or C
file comments (and consequently in generated html doc).
2013-09-27 18:39:21 +02:00
Téo Mazars 8e25b5407d plug-ins,pdb: Add a compatibility wrapper for noise-hsv
... and remove the old plugin
2013-09-26 19:31:13 +02:00
Michael Natterer 39bcc5883d pdb: use if defined $proc->{outargs} not if exists $proc->{outargs}
in app.pl and lib.pl because pdbgen copies this stuff round so
generically that it always exists. Fixes a ton of perl warnings.
2013-09-26 14:09:08 +02:00
Téo Mazars 5063aada1d plug-ins,pdb: Add compatibility wrappers for mosaic
and remove the old plug-in
2013-09-23 15:52:08 +02:00
Michael Natterer 125cf2a2a3 app: use the image instead of the projection for accessing a pickable 2013-09-13 23:29:06 +02:00
Jehan 8fe1f65374 pdb: clean out \n from procedure descriptions in previous commit a7f1129.
If we want better output for long description, this will have to be implemented
in the pdbgen.
2013-09-14 02:58:39 +12:00
Jehan a7f11290a4 pdb: update several channel creation function's descriptions.
More informative, detailed description or better wording.
Also adds some newlines for better rendering.
2013-09-14 02:19:46 +12:00
Jehan ee8827d645 pdb: minor glitch in gimp-image-set-active-channel's description.
s/previous active channel or channel/previous active channel or layer/
2013-09-13 22:21:55 +12:00
Michael Natterer 3582625ce0 app: remove the over from the plug_in_plasma() compat wrapper
because gimp_drawable_apply_operation() supports src ops now.
2013-09-13 09:43:19 +02:00
Téo Mazars a481065f2e pdb: Use svg:src in plasma's compatibility wrapper
instead of svg:src-over
2013-09-13 02:12:02 +02:00
Téo Mazars 6fefd5af0c plugins: Add compat wrappers for plasma.c
... and remove the old plugin.
2013-09-13 01:30:29 +02:00
Michael Natterer c32c1208b0 app: return a GError when flattening the image failed 2013-08-09 21:35:36 +02:00
Téo Mazars 145c9a86d5 plugins: Add compat wrappers for channel-mixer
And remove the old plugin
2013-08-06 21:45:16 +02:00
Téo Mazars 2b58fb4e69 plugins: Add compat wrappers for antialias
And remove the old plugin
2013-08-04 09:09:41 +02:00
Téo Mazars fc6c605cd5 plugins: Effectively fix wrong names in compatibility wrappers
plugin_compat_cmds.c is a generated file
2013-07-30 07:26:50 +02:00
Téo Mazars b0645cf559 plugins: add pdb compat wrappers for tile-seamless
and remove the old plugin
2013-07-28 19:15:25 +02:00
Téo Mazars 409fa79ec2 plugins: follow alien-map's parameter name change 2013-07-20 01:08:39 +02:00
Téo Mazars 95c235f81f plugins: Add compat wrappers for alien-map
And remove the old plugin
2013-07-19 22:32:10 +02:00
Téo Mazars ec6720c897 plugins: add compatibility wrappers to motion-blur
and remove the old plugin.
2013-07-05 20:09:13 +02:00
Jehan ba9fbde288 Bug 679083: proper documentation for plug-in-autocrop-layer
The current documentation have users think the argument layer is going
to be cropped, whereas it actually only serves as a base for determining
cropping extents. The active layer is the one to be cropped.
Slightly more complete documentation explaining this.
2013-07-05 23:20:56 +09:00
Michael Natterer f56f6d1255 app: follow the GEGL invert -> invert-linear vs. invert-gamma change
and invert masks using invert-linear and other drawables using
invert-gamma. drawable_invert_cmd_callback() still always uses
invert-gamma even though it can be used on layer masks.
2013-06-24 00:45:04 +02:00
Michael Natterer caf73f5f35 Add support for both gamma-corrected and linear for all bit depths
- Add new enum GimpComponentType which contains u8, u16, u32 etc.
- Change GimpPrecision to be u8-linear, u8-gamma, u16-linear etc.
- Add all the needed formats to gimp-babl.c
- Bump the XCF version to 5 and make sure version 4 with the old
  GimpPrecision enum values is loaded correctly

This change blows up the precision enums in "New Image" and
Image->Precision so we can test all this stuff. It is undecided what
format will be user-visible options in 2.10.
2013-06-23 16:51:24 +02:00
Alexandre Prokoudine 5290963912 Really fix the incorect blurb in PDB.
It still said "specified specified".
2013-06-22 11:18:47 +04:00
Michael Natterer 571350270b app: return 0.0..1.0 from gimp_histogram_get_mean(), median(), std_dev()
Display the float values in the histogram dockable and add a compat
hack to the gimp_histogram() PDB wrapper.
2013-06-12 02:01:24 +02:00
Michael Natterer a7f42de4c0 app: turn GimpHistorgram into a GimpObject, no other changes 2013-06-11 21:23:32 +02:00
Michael Natterer 0ced7458cc Revert "pdb: Mark unused args as dead"
This reverts commit d2cac94a49
and commit 7241a35b93.

gimp-drawable-foreground-extract will be revived before 2.10, the
warnings are a nice reminder :)
2013-06-10 11:25:16 +02:00
Mukund Sivaraman d2cac94a49 pdb: Mark unused args as dead 2013-06-10 14:41:21 +05:30
Michael Natterer 64887fe06c Bug 701594 - gimp-image-select-item does not recognize path transformations
pdb: Need to gimp_vectors_freeze()/thaw() around stroke modifications
so the vector's preview and the cached GimpBezierDesc are invalidated.
2013-06-04 16:48:41 +02:00
Michael Natterer 7d544e25fe plug-ins, pdb: remove plugin waves and add a PDB compat procedure 2013-06-01 16:04:43 +02:00
Michael Natterer 3b68ae0f3c app, pdb, libgimp: Remove all traces of the supersampling recursion level
from all transform APIs. This is no longer used since we use GEGL to
transform, the value was only passed around and never used.
2013-05-31 01:15:32 +02:00
Michael Natterer 52dc7fb800 plug-ins, pdb: remove plug-in whirl-pinch and add a PDB compat procedure 2013-05-30 17:52:11 +02:00
Michael Natterer 894d7568ac plug-ins, pdb: remove plug-in noise-spread and add a PDB compat procedure 2013-05-29 19:54:42 +02:00
Michael Natterer a77d9223df plug-ins, pdb: remove shift plug-in and add a PDB compat procedure for it 2013-05-27 02:34:04 +02:00
Michael Natterer fc38bc300e plug-ins: remove plug-in cubism and add a PDB compat proc for it 2013-05-19 22:38:03 +02:00
Michael Natterer b8dace7a75 plug-ins: remove plug-in red-eye-removal and add a PDB compat proc for it 2013-05-19 21:11:03 +02:00
Michael Natterer cf3d234f88 Bug 672487 - Impeove API docs of gimp_image_get_channels()
Point out that the image's components are not "channels".
2013-05-10 22:11:14 +02:00
Miroslav Talasek 02505451b1 libgimpbase: enum GimpForegroundExtractMode: add GIMP_FOREGROUND_EXTRACT_MATTING 2013-05-07 23:00:57 +02:00
Michael Natterer e21e3bce5c plug-ins, pdb: remove plug-in noise-randomize
and implement its procedures as compat wrappers around GEGL ops.
2013-03-08 17:06:53 +01:00
Ville Skyttä 6b0d1038cc Bug 692641 - Various spelling fixes 2013-01-27 18:59:02 +01:00
Nicolas Robidoux dc19ead94f Add the Nohalo sampler (previously called Lohalo, which now does something different 2012-12-31 15:27:07 -05:00
Mukund Sivaraman 914f04dcac pdbgen: Word-wrap return description
Also add punctuation where missing.
2012-12-05 08:46:25 +05:30
Sven Neumann 9b2e301c87 pdbgen: programmatically add hint about using g_strfreev()
Add the note about the need to free the returned string array
to the generated libgimp code. This way it will show up in the
libgimp documentation but not in the general PDB API.
2012-12-04 21:07:34 +01:00
Sven Neumann c8209ddb4c Revert "pdb: update documentation for all pdb functions whose return can be freed with g_strfreev()."
Such comment should not be included in the general PDB
documentation as it is specific to the C bindings and can
be easily added by the pdbgen infrastructure.

This reverts commit c9888f2222.
2012-12-04 21:07:34 +01:00
Jehan c9888f2222 pdb: update documentation for all pdb functions whose return can be freed with g_strfreev(). 2012-12-04 00:16:08 +09:00
Michael Natterer e61b1f7603 pdb: return NULL terminated stringarrays from libgimp PDB wrappers
so they can be freed with g_strfreev().
2012-11-27 20:50:21 +01:00
Jehan d8456b5d47 pdb - update documentation comments the right way.
PDB functions must be updated from *.pdb files as *_pdb.c files are
generated by make.
2012-11-28 00:57:23 +09:00
Michael Natterer 07f77e5ec8 pdb: allow file procedures to register themselves for handling URIs
and store the flag in pluginrc. There are no URIs passed to procedures
yet and no procedure registers as such, this is just preparation.
2012-11-17 16:01:52 +01:00
Michael Natterer fe19ad9706 Bug 683694 - Spelling errors
Reworded all places that used to say "allows to".
2012-11-11 15:50:25 +01:00
Michael Natterer a7223bbd2d Bug 352823 - Changing image mode discards text layer information
For conversions that have no dither options (like RGB -> GRAY or u8 ->
u16), always preserve text editability, for conversions that have
dither options (like RGB -> INDEXED or u16 -> u8), give the user the
choice whether to enable dithering.
2012-11-10 18:56:44 +01:00
Michael Natterer d4933b3052 Bug 674160 - Redesign of "Lock panel"
Apply and heavily modify patch from remyDev which adds "lock position"
to GimpItem, similar to "lock content". Lock position disables all
sorts of translation and transform, from the GUI and the PDB.

Cleaned up some aspects of the lock content code as well because a
second instance of similar code always shows what went wrong the first
time.
2012-11-09 11:17:25 +01:00
Michael Natterer 5732088b0c pdb: replace gimppdb-utils' "writable" boolean by a bitmask
called GimpPDBItemModify that currently has one member
GIMP_PDB_ITEM_CONTENT, in order to be prepared for adding
the "lock position" feature from bug 674160.
2012-11-08 20:46:18 +01:00
Michael Natterer 0ca03e8827 app: add a "Convert Precision" dialog for choosing dithering options
Does absolutely nothing yet.
2012-09-23 23:47:28 +02:00
Michael Natterer 6452a95125 Remove plug-in crop-auto and add compat PDB wrappers to replace it 2012-09-22 20:59:17 +02:00
Michael Natterer 303e554ab1 app: remove "gboolean active_layer_only" from gimp_image_crop()
Also a very historic API, it doesn't belong there. Instead, simply
call gimp_item_resize() in GimpCropTool.
2012-09-22 15:08:05 +02:00
Kevin Cozens a2e037fb00 Corrected spelling errors spotted by Ari Pollak (Mostly fixes bug #683694)
Still need to address the "allows to" grammatical error.
2012-09-10 12:22:12 -04:00
Michael Natterer 1f9965879b pdb: add missing breaks in switch() so we don't always pattern-fill
Same as 439c5a7814, just missed
the other function.
2012-08-04 03:13:52 +02:00
Michael Natterer e620eb8cef Bug 678732 - gimp-image-insert-layer inserts into a wrong place...
Fix the docs, the function does what it's supposed to do.  Passing
"0, -1" actually means "insert where the ui would insert" and is
supposed to be used when e.g. scripts create layers.
2012-08-04 02:18:15 +02:00
Michael Natterer 01dffdc276 Bug 680531 - Function gimp-context-get-brush-size takes size argument...
The context getters need PDB @outargs, not @inargs. This "API change"
is OK in stable because the API was totally unusable before this fix.
2012-07-26 16:26:14 +02:00
Michael Natterer 220b28677b Bug 676566 - Window title becomes "Untitled" after exporting without saving
Fix this and other issues more globally by moving the logic that
formats the image's display name into the GimpImage object, and return
the properly formatted name, e.g. "Foo.xcf", or "[Foo] (imported)"
from gimp_image_get_display_name().

Also add gimp_image_get_display_path() which returns the full path
instead. Use the two functions for formatting the image title, and
apply various other fixes that make sure the UI always uses the same
string to identify the image.

Call gimp_object_name_changed() whenever the save/export status
changes, so the image's cached display name and path get cleared.
2012-07-17 22:52:49 +02:00
Michael Natterer fbb2afdf1d app: rename gimpimage-convert.[ch] to gimpimage-convert-type.[ch] 2012-06-26 14:38:33 +02:00
Michael Natterer a3f12f7180 pdb: minor formatting fix in generated PDB wrappers 2012-05-28 19:55:28 +02:00
Michael Natterer 513e3b6a78 app: disable the foreground select tool properly: #if 0 everything
so it's not in the way of further cruft removal.
2012-05-21 03:09:08 +02:00
Michael Natterer 439c5a7814 pdb: add missing breaks in switch() so we don't always pattern-fill 2012-05-17 21:56:45 +02:00
Michael Natterer 3867731b03 pdb: same fix as for XCF loading below 2012-05-11 14:30:38 +02:00
Michael Natterer 7101ee191a app: move all GEGL operations to new directory app/operations/ 2012-05-10 21:22:44 +02:00
Michael Natterer 20f3cba2b6 app: rename gimp_image_base_type() to gimp_image_get_base_type() 2012-05-07 21:57:33 +02:00
Michael Natterer f1a771439a Replace the semi-flatten plug-in by a GEGL operation 2012-05-04 23:56:10 +02:00
Michael Natterer f24445efbc Replace the threshold-slpha plug-in by a GEGL operation 2012-05-04 17:59:36 +02:00