Commit Graph

309 Commits

Author SHA1 Message Date
Michael Natterer 03feba0f35 libgimpbase, app: remove the plug-in menu_path compat code
Registering a full menu path as a procedure's menu label is now
forbidden and causes the procedure to be rejected.

Bump the plug-in protocol version so a pluginrc containing such cruft
is not used.
2018-07-13 14:07:44 +02:00
Michael Natterer 5f700549e7 Change the license URL from http://www.gnu.org/licenses/ to https:// 2018-07-11 23:29:46 +02:00
Jehan bc344a9991 Bug 750180 - Fix different ways of writing Plug-in Plug-In Plugin.
It was agreed that we should write "plug-in" consistently. Only possibly
user-visible strings were updated.
Thanks to scootergrisen for a first patch which could not make it
after changing decision on the canonical writing.
2017-03-21 17:52:22 +01:00
Michael Natterer c3573c3c45 app: keep the plug-in executable path around as GFile 2014-07-08 21:09:35 +02:00
Michael Natterer 6e3495ff69 app: treat an empty ("" not NULL) plug-in proc_install->menu_path as NULL
gimp_plug_in_handle_proc_install(): don't set the new procedure's menu
path nor its menu label if proc_install->menu_path is "", so we don't
run into action and menu creating confusion later. Do it here and not
later so the "" string never enters the system.
2013-10-20 18:28:13 +02:00
Michael Natterer 697572ccc0 app,libgimp*: fix includes to follow our include policy
- don't include <gdk-pixbuf/gdk-pixbuf.h> in headers in app/
- instead, include it in many .c files instead of <glib-object.h>,
  finally acknowledging the fact that app/ depends on gdk-pixbuf almost
  globally
- fix up includes as if libgimpbase depended in GIO, which it soon will
2013-10-15 01:58:39 +02:00
Jehan c7aa623a55 app: clean out a big bunch of leading tabs.
For some unknown reason, most calls to gimp_message_literal() were
indented with tabs.
2013-09-15 04:59:20 +12:00
Michael Natterer 7610e299ae Use GimpValueArray and GimpParamSpecValueArray
instead of the deprecated stuff from GLib.
2012-05-04 00:51:50 +02:00
Michael Natterer 926f746b66 app: add gimp_babl_compat_u8_format() instead of having this code 5 times 2012-05-02 17:51:18 +02:00
Michael Natterer 21dfb8bd9f app/libgimp: enable plug-ins on high precision images
Add gimp_plugin_enable_precision() in libgimp which switches the
plug-in to deal with the drawables' real precision, call it from the
libgimp GeglBuffer and Babl format APIs. If it's not enabled, let the
core's plug-in convert the tiles to legacy formats when sending them
over the wire.
2012-05-02 17:51:14 +02:00
Michael Natterer f0daec882f app: use an explicit tile format when talking to plug-ins 2012-05-02 17:51:06 +02:00
Michael Natterer 3e140fd105 app: factor out GimpPlugIn's tile access emulation code to app/gegl/
so it can be used to access a GeglBuffer's "tiles" in the XCF code.
2012-05-02 17:50:53 +02:00
Michael Natterer 2e33fc15b5 app: remove includes from app/plug-in/ 2012-05-02 17:50:37 +02:00
Michael Natterer acd3ce41b0 app: port the entire plug-in tile communication to using GeglBuffers
which means we are now completely independent of TileManager tile
sizes. The "tile" size used to talk to plug-ins is now defined as:
2012-05-02 17:50:37 +02:00
Michael Natterer 99ae46b4ed app: turn the drawable's shadow tiles into a shadow buffer 2012-05-02 17:46:10 +02:00
Michael Natterer bdc2d4520b app: make sure to always show error messages returned by plug-ins
gimp_plug_in_handle_proc_return(): if there is no plug-in main loop
running (the plugin was running asynchronously from a menu), show the
plug-in's error message here, because nobody else will show it
otherwise.
2010-09-07 16:21:40 +02:00
Michael Natterer 1735f86d25 Kill plug-ins that write to tiles of locked drawables or group layers
Yes this is pretty lame, but we must prevent write access to these
items under all circumstances, and we have no other way but killing
the plug-in (it should not write to the drawable directly anyway)
2009-09-02 19:48:46 +02:00
Michael Natterer a3558e3cb8 Remove GIMP_OBJECT() casts when calling gimp_object_get_name() 2009-08-31 22:47:18 +02:00
Michael Natterer d9b5207aa2 Change licence to GPLv3 (and to LGPLv3 for libgimp).
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
2009-01-17 22:28:01 +00:00
Sven Neumann 4762b73403 bumped minimum required version of GLib to 2.18.0.
2008-11-04  Sven Neumann  <sven@sven>

	* configure.in: bumped minimum required version of GLib to 
2.18.0.

	* INSTALL: document the updated dependency.

	* app/core/gimp.[ch]: introduced gimp_message_literal(), a 
variant
	of gimp_message() that takes a literal string.

	* app/errors.[ch]: removed format arguments from 
gimp_fatal_error()
	and gimp_terminate() and let them take a literal string instead.

	* app/tools/gimptool.[ch]: introduced 
gimp_tool_message_literal(),
	a variant of gimp_tool_message() that takes a literal string.

	* app/actions/documents-commands.c
	* app/actions/drawable-commands.c
	* app/actions/edit-commands.c
	* app/actions/error-console-commands.c
	* app/actions/file-commands.c
	* app/actions/gradients-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/plug-in-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/config/gimprc.c
	* app/core/gimp-modules.c
	* app/core/gimp-parasites.c
	* app/core/gimp-templates.c
	* app/core/gimp-units.c
	* app/core/gimpchannel.c
	* app/core/gimpcontainer-filter.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-convert.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage.c
	* app/core/gimpimagefile.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimplayer.c
	* app/core/gimpselection.c
	* app/dialogs/convert-dialog.c
	* app/dialogs/dialogs.c
	* app/dialogs/palette-import-dialog.c
	* app/dialogs/preferences-dialog.c
	* app/dialogs/quit-dialog.c
	* app/dialogs/stroke-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/file/file-open.c
	* app/file/file-procedure.c
	* app/file/file-save.c
	* app/file/file-utils.c
	* app/gegl/gimpcurvesconfig.c
	* app/gegl/gimplevelsconfig.c
	* app/gui/gui-message.c
	* app/gui/gui.c
	* app/gui/session.c
	* app/paint/gimpbrushcore.c
	* app/paint/gimpclone.c
	* app/paint/gimpheal.c
	* app/paint/gimpperspectiveclone.c
	* app/paint/gimpsourcecore.c
	* app/pdb/gimppdb-utils.c
	* app/pdb/gimpprocedure.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin.c
	* app/plug-in/gimppluginmanager-restore.c
	* app/plug-in/gimppluginprocedure.c
	* app/text/gimptextlayer.c
	* app/tools/gimp-tools.c
	* app/tools/gimpaligntool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdesaturatetool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpforegroundselecttool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpgegltool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpimagemaptool-settings.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimpselectiontool.c
	* app/tools/gimpsourcetool.c
	* app/tools/gimpthresholdtool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c
	* app/widgets/gimpactionview.c
	* app/widgets/gimpcontrollerlist.c
	* app/widgets/gimpcontrollers.c
	* app/widgets/gimpdataeditor.c
	* app/widgets/gimpdevices.c
	* app/widgets/gimpdnd-xds.c
	* app/widgets/gimperrordialog.c
	* app/widgets/gimphelp.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimppdbdialog.c
	* app/widgets/gimpsettingsbox.c
	* app/widgets/gimpvectorstreeview.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf-load.c
	* tools/pdbgen/pdb/convert.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/floating_sel.pdb
	* tools/pdbgen/pdb/image.pdb: use the _literal variants for
	g_set_error(), gimp_message() and gimp_tool_message().

	* app/pdb/convert-cmds.c
	* app/pdb/edit-cmds.c
	* app/pdb/floating-sel-cmds.c
	* app/pdb/image-cmds.c: regenerated.


svn path=/trunk/; revision=27548
2008-11-04 12:33:09 +00:00
Michael Natterer 5503e6a055 Add GEGL_CFLAGS and #includes as if gimpdrawable.h and gimpimage.h had a
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-10-09 20:24:04 +00:00
Sven Neumann 5e95e896b1 app/plug-in/gimppluginprocedure.c don't just free the return values when
2008-08-21  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimppluginprocedure.c
	* app/plug-in/gimptemporaryprocedure.c: don't just free the 
return
	values when running procedures asynchronously. Instead examine
	them and display the error message if there's one.

	* app/plug-in/gimppluginmanager-call.c
	(gimp_plug_in_manager_call_run_temp): return NULL if
	procedure->plug_in is not set.

	* app/plug-in/gimpplugin-message.c: comment.


svn path=/trunk/; revision=26700
2008-08-21 16:27:06 +00:00
Michael Natterer 960b30cd9e app/plug-in/gimpplugin.[ch] (struct GimpPlugIn) move the error_handler
2008-08-19  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin.[ch] (struct GimpPlugIn)
	* app/plug-in/gimppluginprocframe.[ch] (struct GimpPlugInProcFrame):
	move the error_handler from the plug-in to the proc-frame.

	* app/plug-in/gimppluginprocframe.c
	* app/plug-in/gimpplugin-message.c: changed accordingly.


svn path=/trunk/; revision=26661
2008-08-19 08:24:48 +00:00
Sven Neumann 369d991fd2 Complements the fix for bug #344818:
2008-08-19  Sven Neumann  <sven@gimp.org>

	Complements the fix for bug #344818:

	* libgimpbase/gimpbaseenums.[ch]: added new enum 
GimpPDBErrorHandler.

	* tools/pdbgen/enums.pl: regenerated.

	* app/plug-in/gimpplugin.[ch]: added error_handler to 
GimpPlugIn.

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	only display an error message for a failed procedure call if the
	plug-in's error-handler is set to 
GIMP_PDB_ERROR_HANDLER_INTERNAL.
	
	* tools/pdbgen/pdb/plug_in.pdb: added PDB getter and setter for
	the plug-in's error-handler.

	* app/pdb/plug-in-cmds.c
	* app/pdb/internal-procs.c
	* libgimp/gimpenums.c.tail
	* libgimp/gimpplugin_pdb.[ch]: regenerated.

	* plug-ins/common/file-compressor.c
	* plug-ins/file-uri/uri.c: set the error-handler to
	GIMP_PDB_ERROR_HANDLER_PLUGIN as these plug-ins are forwarding 
the
	error with their return values.


svn path=/trunk/; revision=26656
2008-08-18 22:54:26 +00:00
Sven Neumann c4f3f05df4 removed the term 'PDB' from the user-visible error messages.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	removed the term 'PDB' from the user-visible error messages.


svn path=/trunk/; revision=26601
2008-08-16 17:11:22 +00:00
Sven Neumann f84608d539 If a procedure call fails, pass a string describing the error as the
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-08-16 13:57:57 +00:00
Sven Neumann ada401fe48 use G_STRFUNC in another error message that I missed earlier.
2008-08-14  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	use G_STRFUNC in another error message that I missed earlier.


svn path=/trunk/; revision=26570
2008-08-14 21:57:39 +00:00
Sven Neumann 9884974e53 use G_STRFUNC to get the proper function name in the error message.
2008-08-14  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_tile_get):
	use G_STRFUNC to get the proper function name in the error 
message.


svn path=/trunk/; revision=26564
2008-08-14 19:59:47 +00:00
Sven Neumann 81131c0bb4 Add new PDB data type PDB_COLORARRAY for using arrays of GimpRGB colors as
2008-07-14  Sven Neumann  <sven@gimp.org>

	Add new PDB data type PDB_COLORARRAY for using arrays of GimpRGB
	colors as argument or return value.

	* libgimpbase/gimpbaseenums.[ch] (enum GimpPDBArgType): replaced
	the unused GIMP_PDB_BOUNDARY with GIMP_PDB_COLORARRAY.

	* libgimpbase/gimpprotocol.h: increased GIMP_PROTOCOL_VERSION.
	(struct _GPParam): added d_colorarray entry to the union.

	* libgimpbase/gimpprotocol.c
	* libgimp/gimp.[ch]
	* app/pdb/gimp-pdb-compat.c
	* app/plug-in/plug-in-params.c
	* app/plug-in/gimpplugin-message.c
	* tools/pdbgen/pdb.pl: deal with the new data type.

	* tools/pdbgen/enums.pl: regenerated.

	* plug-ins/pygimp/pygimp-pdb.c
	* plug-ins/script-fu/scheme-wrapper.c: handle the new data type.


svn path=/trunk/; revision=26189
2008-07-14 14:09:16 +00:00
Michael Natterer c1b372f9ca split gimp_plug_in_handle_tile_request() into two functions:
2008-05-06  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin-message.c: split
	gimp_plug_in_handle_tile_request() into two functions:
	gimp_plug_in_handle_tile_put() and gimp_plug_in_handle_tile_get().


svn path=/trunk/; revision=25578
2008-05-06 20:30:51 +00:00
Michael Natterer 7d81b3041c show an error message instead of crashing when a plug-in registers a
2008-05-06  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin-message.c
	(gimp_plug_in_handle_proc_install): show an error message instead
	of crashing when a plug-in registers a prodecure with a NULL
	argument or return value name. Also introduce two macros which
	make the utf-8 validation of all strings much more readable.


svn path=/trunk/; revision=25577
2008-05-06 20:15:12 +00:00
Michael Natterer e5be5664ed Move the shadow tiles from the image to the drawable. Fixes bug #100469.
2008-04-21  Michael Natterer  <mitch@gimp.org>

	Move the shadow tiles from the image to the drawable.
	Fixes bug #100469.

	* app/core/Makefile.am
	* app/core/gimpdrawable-shadow.[ch]: new files implementing
	the shadow tiles.

	* app/core/gimpimage.[ch]: remove the shadow tile manager from the
	GimpImage struct. Remove gimp_image_get_shadow_tiles() and
	_free_shadow_tiles().

	* app/core/gimpdrawable.[ch]: add the shadow tile manager
	here. Remove get_shadow_tiles() and merge_shadow(). Free the
	shadow tiles in finalize and when the drawable gets removed from
	the image.

	* app/core/gimpdrawable-brightness-contrast.c
	* app/core/gimpdrawable-color-balance.c
	* app/core/gimpdrawable-colorize.c
	* app/core/gimpdrawable-curves.c
	* app/core/gimpdrawable-desaturate.c
	* app/core/gimpdrawable-equalize.c
	* app/core/gimpdrawable-hue-saturation.c
	* app/core/gimpdrawable-invert.c
	* app/core/gimpdrawable-levels.c
	* app/core/gimpdrawable-operation.c
	* app/core/gimpdrawable-posterize.c
	* app/core/gimpdrawable-threshold.c
	* app/core/gimpimagemap.c: changed accordingly. Free the shadow tiles
	after using them.

	* app/plug-in/gimpplugin-cleanup.[ch]: add
	gimp_plug_in_cleanup_add_shadow() and _remove_shadow() which keep
	track of whether shadow tiles were created on behalf of a plug-in
	procedure.

	(gimp_plug_in_cleanup): free shadow tiles which were created but
	not destroyed by a plug-in procedure.

	* app/plug-in/gimpplugin-message.c (plug_in_handle_tile_request):
	call gimp_plug_in_cleanup_add_shadow() whenever a plug-in requests
	shadow tiles.

	* tools/pdbgen/pdb/drawable.pdb: use the new drawable shadow
	API. Add new procedure gimp-drawable-free-shadow. Call
	gimp_plug_in_cleaup_remove_shadow() when it gets called.

	* tools/pdbgen/pdb/image.pdb: deprecate gimp-image-free-shadow.
	Calling it has no effect any longer.

	* app/pdb/drawable-cmds.c
	* app/pdb/image-cmds.c
	* app/pdb/internal-procs.c
	* libgimp/gimpimage_pdb.[ch]
	* libgimp/gimpdrawable_pdb.[ch]: regenerated.


svn path=/trunk/; revision=25510
2008-04-21 17:20:51 +00:00
Sven Neumann 9d51e64525 renamed gimp_plug_in_handle_tile_req() to
2008-04-14  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c: renamed
	gimp_plug_in_handle_tile_req() to 
gimp_plug_in_handle_tile_request().


svn path=/trunk/; revision=25488
2008-04-14 17:50:25 +00:00
Michael Natterer 07708f74bd made messages about killed plug-ins due to invalid tile requests more
2008-04-14  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_tile_req):
	made messages about killed plug-ins due to invalid tile requests
	more verbose. They are good for debugging only and not translated,
	so more info can't hurt. Also fail (kill the plug-in) if a tile is
	requested that lives on the undo stack.


svn path=/trunk/; revision=25487
2008-04-14 15:01:23 +00:00
Sven Neumann cc44a68902 made the code more robust against errors on the wire protocol level.
2007-12-11  Sven Neumann  <sven@gimp.org>

	* libgimpbase/gimpprotocol.c: made the code more robust against
	errors on the wire protocol level.

	* app/plug-in/gimpplugin-message.c: added sanity checks to message
	handlers. This doesn't keep us from crashing on invalid input, but
	we will at least get some warnings before that happens.

svn path=/trunk/; revision=24317
2007-12-11 09:40:10 +00:00
Sven Neumann 915ac64ad5 use GError for error reporting in PDB invoker methods.
2007-12-02  Sven Neumann  <sven@gimp.org>

	* tools/pdbgen/app.pl: use GError for error reporting in PDB
	invoker methods.

	* tools/pdbgen/pdb/vectors.pdb: use the GError for the 
procedures
	introduced for bug #497159.

	* tools/pdbgen/pdb/fileops.pdb: use the GError from file-load 
and
	file-save procedures.

	* app/pdb/*_cmds.c: regenerated.

	* app/pdb/Makefile.am

	* app/pdb/gimppdberror.[ch]: new file introducing the
	GIMP_PDB_ERROR domain.

	* app/actions/plug-in-commands.c
	* app/actions/vectors-commands.c
	* app/batch.c
	* app/core/gimpimagefile.c
	* app/core/gimppdbprogress.c
	* app/file/file-open.[ch]
	* app/file/file-save.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimppluginmanager-restore.c
	* app/plug-in/gimppluginprocedure.c
	* app/plug-in/gimptemporaryprocedure.c
	* app/plug-in/plug-in-icc-profile.c
	* app/widgets/gimpbrushselect.c
	* app/widgets/gimpfontselect.c
	* app/widgets/gimpgradientselect.c
	* app/widgets/gimphelp.c
	* app/widgets/gimppaletteselect.c
	* app/widgets/gimppatternselect.c
	* app/widgets/gimppdbdialog.[ch]: changed accordingly.


svn path=/trunk/; revision=24255
2007-12-02 18:05:54 +00:00
Sven Neumann f8a56311ce set the procedure name before parsing the image types. Fixes bug #490055.
2007-10-25  Sven Neumann  <sven@gimp.org>

        * app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_proc_install):
        set the procedure name before parsing the image types.
        Fixes bug #490055.

svn path=/trunk/; revision=23943
2007-10-25 09:59:45 +00:00
Michael Natterer 4ed0eb238f app/plug-in/gimpplugin.c (gimp_plug_in_add_temp_proc) remove duplicate
2007-02-19  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin.c (gimp_plug_in_add_temp_proc)
	* app/plug-in/gimpplugindef.c (gimp_plug_in_def_add_procedure):
	remove duplicate procedures before adding the new one.
	
	* app/plug-in/gimpplugin-message.c
	(gimp_plug_in_handle_proc_install): don't remove duplicates here.


svn path=/trunk/; revision=21945
2007-02-19 09:36:19 +00:00
Michael Natterer be5fbd643e app/plug-in/Makefile.am app/plug-in/plug-in-types.h removed...
2007-02-19  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/Makefile.am
	* app/plug-in/plug-in-types.h
	* app/plug-in/plug-in-def.[ch]: removed...

	* app/plug-in/gimpplugindef.[ch]: ...and added as object. Merged
	locale and help domain setters into one function each.

	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin.[ch]
	* app/plug-in/gimppluginmanager-call.[ch]
	* app/plug-in/gimppluginmanager-file.c
	* app/plug-in/gimppluginmanager.c
	* app/plug-in/plug-in-rc.c
	* tools/pdbgen/pdb/plug_in.pdb: changed accordingly.

	* app/pdb/plug_in_cmds.c: regenerated.


svn path=/trunk/; revision=21944
2007-02-19 01:16:05 +00:00
Michael Natterer e0a86bdf05 fixed comment.
2007-01-16  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_proc_run):
	fixed comment.


svn path=/trunk/; revision=21721
2007-01-15 23:01:55 +00:00
Sven Neumann 41237259c9 In all files, changed the standard copyright notice to say "GIMP - The GNU
2006-12-09  Sven Neumann  <sven@gimp.org>

        * In all files, changed the standard copyright notice to say
        "GIMP - The GNU Image Manipulation Program".
2006-12-09 21:33:38 +00:00
Michael Natterer 2528519869 don't send a return value if executing the procedure closed the plug-in
2006-10-27  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_proc_run):
	don't send a return value if executing the procedure closed the
	plug-in (as is the case with gimp-quit). Fixes bug #332608.
2006-10-27 13:16:51 +00:00
Michael Natterer 1ed8dd4f53 app/actions/data-commands.c app/actions/documents-commands.c
2006-10-09  Michael Natterer  <mitch@gimp.org>

	* app/actions/data-commands.c
	* app/actions/documents-commands.c
	* app/actions/drawable-commands.c
	* app/actions/gradients-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/palettes-commands.c
	* app/actions/select-commands.c
	* app/actions/vectors-commands.c
	* app/core/gimp-contexts.c
	* app/core/gimp-documents.c
	* app/core/gimp-edit.c
	* app/core/gimp-modules.c
	* app/core/gimp-parasites.c
	* app/core/gimp-templates.c
	* app/core/gimp-units.c
	* app/core/gimpchannel.c
	* app/core/gimpdatafactory.[ch]
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimagefile.c
	* app/core/gimplayer-floating-sel.c
	* app/core/gimppdbprogress.c
	* app/core/gimpselection.c
	* app/dialogs/palette-import-dialog.c
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/session.c
	* app/gui/themes.c
	* app/pdb/gimpprocedure.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin.c
	* app/plug-in/gimppluginmanager-file.c
	* app/plug-in/gimppluginmanager.c
	* app/text/gimptextlayer-xcf.c
	* app/text/gimptextlayer.c
	* app/widgets/gimpcontrollers.c
	* app/widgets/gimpdataeditor.c
	* app/widgets/gimpdevices.c
	* app/widgets/gimpdnd-xds.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimpuimanager.c
	* app/widgets/gimpvectorstreeview.c
	* tools/pdbgen/pdb/brush.pdb
	* tools/pdbgen/pdb/gradient.pdb
	* tools/pdbgen/pdb/palette.pdb: convert lots of g_message() to
	gimp_message(). Make sure we never pass unknown strings (like
	error->message) to printf-like functions directly; run them
	thorugh "%s" instead. Don't translate some messages which should
	never happen.

	* app/pdb/brush_cmds.c
	* app/pdb/gradient_cmds.c
	* app/pdb/palette_cmds.c: regenerated.
2006-10-09 18:49:15 +00:00
Michael Natterer db51ce3a49 Fix disabling of deprecated procedures (bug #345733):
2006-09-19  Michael Natterer  <mitch@gimp.org>

	Fix disabling of deprecated procedures (bug #345733):

	* app/pdb/gimppdb.c (gimp_pdb_register_procedure): silently drop
	deprecated procedures if they are disabled via --pdb-compat-mode.

	* app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_proc_run):
	remove code that handles deprecated procedures even when they are
	disabled, the change above makes this impossible.
	Call plug_in_params_to_args() also if we didn't find the
	procedure, so the PDB doesn't choke on NULL args.
2006-09-19 11:58:57 +00:00
Michael Natterer 0005f0ff5d app/pdb/Makefile.am app/pdb/gimppluginprocedure.[ch] removed these
2006-08-05  Michael Natterer  <mitch@gimp.org>

	* app/pdb/Makefile.am
	* app/pdb/gimppluginprocedure.[ch]
	* app/pdb/gimptemporaryprocedure.[ch]: removed these files...

	* app/plug-in/Makefile.am
	* app/plug-in/gimppluginprocedure.[ch]
	* app/plug-in/gimptemporaryprocedure.[ch]: ...and added them here.

	* app/Makefile.am
	* app/config/Makefile.am: reordered stuff to make it link again.

	* app/pdb/gimppdb.c: removed gimp_pdb_eek() hack.

	* app/actions/plug-in-actions.c
	* app/dialogs/file-save-dialog.c
	* app/file/file-open.c
	* app/file/file-save.c
	* app/file/file-utils.c
	* app/menus/plug-in-menus.c
	* app/plug-in/gimpplugin-message.c
	* app/plug-in/gimpplugin-progress.c
	* app/plug-in/gimpplugin.c
	* app/plug-in/gimppluginmanager-call.c
	* app/plug-in/gimppluginmanager-file.c
	* app/plug-in/gimppluginmanager-query.c
	* app/plug-in/gimppluginmanager.c
	* app/plug-in/gimppluginprocframe.c
	* app/plug-in/plug-in-def.c
	* app/plug-in/plug-in-rc.c
	* app/widgets/gimpfiledialog.c
	* app/widgets/gimpfileprocview.c
	* app/widgets/gimppluginaction.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/plug_in.pdb: changed includes accordingly.

	* app/pdb/plug_in_cmds.c: regenerated.
2006-08-05 21:21:01 +00:00
Michael Natterer d033ddda1b cleaned up a bit.
2006-05-04  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimppluginshm.c: cleaned up a bit.

	(gimp_plug_in_shm_new): return NULL if anything goes wrong,
	instead of a GimpPlugInShm structure that contains no shm (we
	don't need multiple cases of "there is no shm"),

	* app/plug-in/gimppluginmanager.[ch]
	(gimp_plug_in_manager_get_shm_ID)
	(gimp_plug_in_manager_get_shm_addr): removed these functions.

	* app/plug-in/gimppluginmanager-call.c (gimp_plug_in_manager_call_run)
	* app/plug-in/gimpplugin-message.c (gimp_plug_in_handle_tile_req):
	get the shm ID and addr directly from manager->shm if it exists,
	use -1 and NULL otherwise.

	Unrelated:

	* app/plug-in/gimppluginmanager.c: move most stuff from
	gimp_plug_in_manager_exit() to gimp_plug_in_manager_finalize().
	Simplify plug-in killing in _exit().
2006-05-04 21:49:04 +00:00
Michael Natterer 2329ed9615 remove member "name" and unused cruft "ref_count". Reordered other members
2006-05-04  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/gimpplugin.[ch] (struct GimpPlugIn): remove member
	"name" and unused cruft "ref_count". Reordered other members a bit.

	(gimp_plug_in_new): set GimpObject's name to
	g_filename_display_basename(path) instead.

	Use GimpObject's name instead of plug_in->name for error messages
	and pass the full path to gimp_plug_in_debug_argv()

	* app/plug-in/gimpplugindebug.c (gimp_plug_in_debug_argv): extract
	the path's basename ourselves.

	* app/plug-in/gimpplugin-message.c: GimpObject's name for
	error messages.
2006-05-04 11:58:10 +00:00
Michael Natterer 4b917ea28b Made an object out of the plug-in struct. Also change refcounting
2006-05-03  Michael Natterer  <mitch@gimp.org>

	Made an object out of the plug-in struct. Also change refcounting
	considerably:

	- gimp_plug_in_open() adds a reference that is only dropped by
	  gimp_plug_in_close().
	- temporarily ref the plug-in while handling messages.
	- remporarily ref the plug-in while a recursive main loop is
	  running.
	- each caller of gimp_plug_in_new() also unrefs the plug-in before
	  returning, the only reference that persists across functions
	  (that keeps the plug-in alive) is the one added by open().

	* app/plug-in/plug-in.[ch]
	* app/plug-in/plug-in-context.[ch]
	* app/plug-in/plug-in-message.[ch]
	* app/plug-in/plug-in-progress.[ch]: removed these files...

	* app/plug-in/gimpplugin.[ch]
	* app/plug-in/gimpplugin-context.[ch]
	* app/plug-in/gimpplugin-message.[ch]
	* app/plug-in/gimpplugin-progress.[ch]: ...and added here as GObject.

	* app/plug-in/plug-in-proc-frame.[ch]: removed...

	* app/plug-in/gimppluginprocframe.[ch]: ...and added with a namespace.

	* app/plug-in/Makefile.am
	* app/plug-in/plug-in-types.h
	* app/plug-in/gimppluginmanager-call.c
	* app/plug-in/gimppluginmanager-file.c
	* app/plug-in/gimppluginmanager.[ch]
	* app/pdb/gimppluginprocedure.c
	* app/pdb/gimptemporaryprocedure.c
	* app/pdb/gimptemporaryprocedure.h
	* tools/pdbgen/pdb/context.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/help.pdb
	* tools/pdbgen/pdb/message.pdb
	* tools/pdbgen/pdb/plug_in.pdb
	* tools/pdbgen/pdb/progress.pdb
	* tools/pdbgen/pdb/undo.pdb: changed accordingly.

	* app/pdb/context_cmds.c
	* app/pdb/drawable_cmds.c
	* app/pdb/help_cmds.c
	* app/pdb/message_cmds.c
	* app/pdb/plug_in_cmds.c
	* app/pdb/progress_cmds.c
	* app/pdb/undo_cmds.c: regenerated.
2006-05-03 18:05:06 +00:00
Michael Natterer 927cde4121 added enum GimpPlugInCallMode which can be one of { NONE, QUERY, INIT, RUN
2006-05-02  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/plug-in-enums.[ch]: added enum GimpPlugInCallMode
	which can be one of { NONE, QUERY, INIT, RUN }.

	* app/plug-in/Makefile.am
	* app/plug-in/gimppluginmanager-run.[ch]: removed again...

	* app/plug-in/gimppluginmanager-call.[ch]: ...and added
	here. Added gimp_plug_in_manager_call_init() and
	gimp_plug_in_manager_call_query().

	* app/plug-in/plug-in.[ch]: removed plug_in_call_query() and
	plug_in_call_init().

	(struct PlugIn): removed members "init", "query" and "synchronous".

	(plug_in_open): added parameters "call_mode" and "synchronous".

	* app/plug-in/gimppluginmanager.c
	* app/plug-in/plug-in-message.c
	* app/pdb/gimppluginprocedure.c
	* app/pdb/gimptemporaryprocedure.c
	* tools/pdbgen/pdb/plug_in.pdb: changed accordingly.

	* app/pdb/plug_in_cmds.c: regenerated.
2006-05-02 18:27:31 +00:00
Michael Natterer 38406b7202 removed plug_in_push() and plug_in_pop()...
2006-04-29  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/plug-in.[ch]: removed plug_in_push() and
	plug_in_pop()...

	* app/plug-in/gimppluginmanager.[ch]: ...and added them here as
	gimp_plug_in_manager_plug_in_push() and _pop()

	* app/plug-in/plug-in-message.c (plug_in_handle_proc_run): changed
	accordingly.

	* app/plug-in/plug-in.c (plug_in_close): removed an unused
	variable, moved another one to a local scope.

	* app/plug-in/plug-in.h: indentation.
2006-04-29 19:03:44 +00:00