Add "image" parameter to gimp_pdb_item_is_attached() and if non-NULL,
make sure the item is attached to that image, and not only attached to
any image. Change wrappers to pass an image where it makes sense.
Fix totally broken value ranges of integer PDB parameters. Magically,
the bug was affecting only exactly the two cases mentioned in above
bug report.
* tools/pdbgen/pdb.pl (arg_parse): return <, <=, > and >= literally
instead of applying a mapping that was originally meant for
generated C code that would e.g. transform "0 <= int32 < 10" into
"if (value < 0 || value >= 10) fail". This inversion of all
operators is now wrong because PDB parameters have been turned into
GParamSpecs which always need inclusive ranges as min and max
values.
* tools/pdbgen/pdbgen.pl (arrayexpand): generated array length type
specs must be "0 <= int32", not "0 < int32".
* tools/pdbgen/app.pl: when generating integer param specs, check if
the value range is specified in terms of < instead of <=, and
add/subtract 1, resuting in the inclusive range needed for integer
GParamSpecs.
* app/pdb/color-cmds.c: regenerated, fixing the two broken ranges
mentioned in the bug report.
"lock-content" will be separate from "is-group" soon, so add separate
checks for groups. Also remove some checks that were added to make
wrappers invokable even though the group appeared locked.
* app/pdb/gimppdb-utils.[ch]: add "gboolean writable" parameter to
gimp_pdb_item_is_attached() because this function is called on
almost all items where a check for locked is needed.
* tools/pdbgen/pdb/*.pdb: pass writable = TRUE in all checks for items
that are modified. Add explicit calls to gimp_pdb_item_is_writable()
in some rare cases.
* app/pdb/*-cmds.c: regenerated.
2009-01-17 Michael Natterer <mitch@gimp.org>
* all files with a GPL header and all COPYING files:
Change licence to GPLv3 (and to LGPLv3 for libgimp).
Cleaned up some copyright headers and regenerated the parsers in
the ImageMap plugin.
svn path=/trunk/; revision=27913
2008-10-09 Michael Natterer <mitch@gimp.org>
Add GEGL_CFLAGS and #includes as if gimpdrawable.h and gimpimage.h
had a GEGL dependency (they will have in the next commit, but I
wanted to keep the commit separate).
* app/dialogs/Makefile.am
* app/file/Makefile.am
* app/gui/Makefile.am
* app/menus/Makefile.am
* app/paint/Makefile.am
* app/plug-in/Makefile.am
* app/text/Makefile.am
* app/vectors/Makefile.am
* app/widgets/Makefile.am
* app/xcf/Makefile.am: add GEGL_CFLAGS.
* app/actions/*.c
* app/core/*.c
* app/dialogs/*.c
* app/display/*.c
* app/file/*.c
* app/gui/*.c
* app/menus/*.c
* app/paint/*.c
* app/pdb/gimppdb-utils.c
* app/pdb/gimpprocedure.c
* app/plug-in/*.c
* app/text/*.c
* app/tools/*.c
* app/vectors/*.c
* app/widgets/*.c
* app/xcf/*.c: add <gegl.h> or replace <glib-object.h> by <gegl.h>
to all files which include a drawable subclass or gimpimage.h
* tools/pdbgen/app.pl: include <gegl.h> instead of <glib-object.h>
in all generated files.
* app/pdb/*-cmds.c: regenerated.
* data/images/gimp-splash.png: the goat is still sleeping.
By Aurore Derriennic.
svn path=/trunk/; revision=27202
2008-08-16 Sven Neumann <sven@gimp.org>
If a procedure call fails, pass a string describing the error as
the second return value. First step towars fixing bug #344818.
* app/pdb/gimpprocedure.[ch] (gimp_procedure_get_return_values):
added a GError parameter. If it is set, pass the error message
to
the return values.
* app/pdb/gimppdberror.h: added some more error codes.
* app/pdb/gimppdb.c
* app/xcf/xcf.c: pass errors to
gimp_procedure_get_return_values().
* app/plug-in/gimpplugin-message.c
(gimp_plug_in_handle_proc_run):
show a different error message for execution vs. calling errors.
* app/plug-in/gimpplugin-progress.c
(gimp_plug_in_progress_cancel_callback): pass the error
GIMP_PDB_CANCELLED to gimp_procedure_get_return_values().
* app/plug-in/gimppluginmanager-call.[ch]
(gimp_plug_in_manager_call_run): removed the
'destroy_return_vals'
parameter.
* app/plug-in/gimppluginprocedure.c: destroy the return values
here.
* app/plug-in/gimppluginprocframe.c: pass an error to
gimp_procedure_get_return_values().
* tools/pdbgen/app.pl
* tools/pdbgen/pdb/fileops.pdb: generate code that passes the
error to gimp_procedure_get_return_values().
* app/pdb/*-cmds.c: regenerated.
* plug-ins/pygimp/pygimp-pdb.c: extract the error message from
the
return values and pass it to the exception that is thrown.
svn path=/trunk/; revision=26593
2008-05-21 Sven Neumann <sven@gimp.org>
* app/core/Makefile.am
* app/core/gimpdrawable-process.[ch]: new file holding code to
apply a PixelProcessor to the full drawable.
* app/core/gimpdrawable-desaturate.c
* app/core/gimpdrawable-invert.c: use the new helper function.
* app/core/gimpdrawable-desaturate.[ch]
(gimp_drawable_desaturate):
take a GimpProgress parameter.
* tools/pdbgen/pdb/color.pdb: changed accordingly.
* app/pdb/color-cmds.c: regenerated.
svn path=/trunk/; revision=25734
2008-04-20 Michael Natterer <mitch@gimp.org>
* app/core/gimpdrawable-levels.[ch]: replaced unused parameter
"context" by "progress" and pass the progress on internally.
Factor common code out to gimp_drawable_levels_internal().
* tools/pdbgen/pdb/color.pdb: pass progress instead of context.
* app/pdb/color-cmds.c: regenerated.
svn path=/trunk/; revision=25501