Commit Graph

122 Commits

Author SHA1 Message Date
Sven Neumann 94bef475d2 added GIMP_UNDO_FOREGROUND_SELECT.
2005-08-03  Sven Neumann  <sven@gimp.org>

	* app/core/core-enums.[ch]: added GIMP_UNDO_FOREGROUND_SELECT.

	* app/tools/Makefile.am
	* app/tools/gimpforegroundselecttool-undo.[ch]: added stubs for
	undo in the new foreground selection tool.

	* tools/pdbgen/pdb/procedural_db.pdb: include gimpbase.h for
	gimp_canonicalize_identifier().

	* app/pdb/procedural_db_cmds.c: regenerated.

	* app/file/file-utils.c: fixed signedness warning.
2005-08-03 01:54:27 +00:00
Sven Neumann 6c178549bc close the file descriptor if we fail to obtain the lock (bug #151767).
2005-04-25  Sven Neumann  <sven@gimp.org>

	* app/file/gimprecentlist.c (gimp_recent_list_add_item): close the
	file descriptor if we fail to obtain the lock (bug #151767).
2005-04-25 16:24:20 +00:00
Michael Natterer 09ef4b1d00 app/file/file-utils.c app/tools/gimpfliptool.c
2005-04-10  Michael Natterer  <mitch@gimp.org>

	* app/file/file-utils.c
	* app/tools/gimpfliptool.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimppaletteselect.c: removed unneeded base/ includes.
2005-04-09 22:47:51 +00:00
Sven Neumann c2a6b89ede open images interactively. Fixes bug #168936.
2005-03-08  Sven Neumann  <sven@gimp.org>

	* app/file/file-open.c (file_open_layer): open images interactively.
	Fixes bug #168936.
2005-03-08 16:39:20 +00:00
Sven Neumann 74002a72e1 app/dialogs/user-install-dialog.c app/file/gimprecentlist.c
2005-03-04  Sven Neumann  <sven@gimp.org>

	* app/dialogs/user-install-dialog.c
	* app/file/gimprecentlist.c
	* app/widgets/gimpwidgets-utils.c
	* modules/controller_linux_input.c
	* modules/controller_midi.c
	* plug-ins/common/compressor.c
	* plug-ins/common/mail.c
	* plug-ins/common/psp.c
	* plug-ins/common/raw.c
	* plug-ins/helpbrowser/dialog.c
	* plug-ins/imagemap/imap_cern.y
	* plug-ins/imagemap/imap_cern_parse.[ch]
	* plug-ins/imagemap/imap_csim.y
	* plug-ins/imagemap/imap_csim_parse.[ch]
	* plug-ins/imagemap/imap_main.c
	* plug-ins/imagemap/imap_ncsa.y
	* plug-ins/imagemap/imap_ncsa_parse.[ch]
	* plug-ins/uri/uri.c
	* plug-ins/xjt/xjt.c: ported the remaining functions to gstdio.
2005-03-04 19:13:21 +00:00
Daniel Egger 0add60298a app/base/Makefile.am app/composite/*akefile.am app/config/*akefile.am
2005-02-27  Daniel Egger  <de@axiros.com>

	* app/base/Makefile.am
	* app/composite/*akefile.am
	* app/config/*akefile.am
	* app/core/*akefile.am
	* app/display/*akefile.am
	* app/file/*akefile.am
	* app/paint-funcs/*akefile.am
	* app/pdb/*akefile.am
	* app/plug-in/*akefile.am
	* app/text/*akefile.am
	* app/tools/*akefile.am
	* app/vectors/*akefile.am
	* app/xcf/*akefile.am: Commonized include paths to always look
	in the builddir also to cater for srcdir != builddir builds.
2005-02-27 13:22:01 +00:00
Michael Natterer 1c7e7a165a removed file_save() and renamed file_save_as() to file_save() which always
2005-02-13  Michael Natterer  <mitch@gimp.org>

	* app/file/file-save.[ch]: removed file_save() and renamed
	file_save_as() to file_save() which always requires "uri" and
	"file_proc" to be passed. This functions does no more file_proc by
	extension finding and stuff.

	* app/actions/file-commands.c (file_save_cmd_callback): only call
	file_save() if the image has both uri and save_proc, fall back to
	file_save_as_cmd_callback() otherwise.

	* app/dialogs/file-save-dialog.c: completely chopped and
	reconstructed. Added tons of checks for extension vs. save_proc
	consistency and ask the user if she really wants to save weird
	stuff. Added masive debugging output because I'm far from certain
	that everything is correct.
2005-02-13 18:05:43 +00:00
Sven Neumann 9511753a02 check for gthread-2.0 unless the --disable-mp option is given.
2005-02-13  Sven Neumann  <sven@gimp.org>

	* configure.in: check for gthread-2.0 unless the --disable-mp
	option is given.

	* app/app_procs.c (app_libs_init): call g_thread_init().

	* app/base/pixel-processor.c: ported to GThread.

	* app/Makefile.am
	* app/*/Makefile.am: use @GTHREAD_CFLAGS@.
2005-02-13 15:08:08 +00:00
Manish Singh dd81c98a13 Make sure filename is initialized before use.
2005-02-10  Manish Singh  <yosh@gimp.org>

        * app/file/file-save.c (file_save_as): Make sure filename is
        initialized before use.
2005-02-10 23:47:30 +00:00
Sven Neumann f5e3d9b335 applied a (slightly modified) patch from Shlomi Fish that automatically
2005-02-10  Sven Neumann  <sven@gimp.org>

	* app/file/file-save.c (file_save_as): applied a (slightly
	modified) patch from Shlomi Fish that automatically adds the .xcf
	extension if none is given (bug #165684).
2005-02-10 14:32:14 +00:00
Sven Neumann 47c35a6ebf app/config/gimpconfig-file.c app/file/file-utils.c app/gui/themes.c
2005-02-07  Sven Neumann  <sven@gimp.org>

	* app/config/gimpconfig-file.c
	* app/file/file-utils.c
	* app/gui/themes.c
	* app/tools/gimpimagemaptool.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/procedural_db.pdb: use gstdio wrappers.

	* app/pdb/procedural_db_cmds.c: regenerated.
2005-02-07 01:38:18 +00:00
Sven Neumann 8b3481f3ff added new utility function file_utils_filename_from_uri().
2005-02-03  Sven Neumann  <sven@gimp.org>

	* app/file/file-utils.[ch]: added new utility function
	file_utils_filename_from_uri().

	* app/file/file-open.c (file_open_image)
	* app/file/file-save.c (file_save_as):
	* app/file/file-utils.c (file_utils_find_proc)
	(file_utils_uri_to_utf8_filename): replaced calls to
	g_filename_from_uri() with file_utils_filename_from_uri().
2005-02-03 23:14:42 +00:00
Sven Neumann 28d4a760d0 when the image filename changes, forget the filename that was last used
2004-11-29  Sven Neumann  <sven@gimp.org>

	* app/file/file-save.c (file_save_as): when the image filename
	changes, forget the filename that was last used with "save-a-copy".
2004-11-29 13:50:02 +00:00
Hans Breuer 696663a611 [new file] app/dialogs/Makefile.am : added to EXTRA_DIST
2004-09-21  Hans Breuer  <hans@breuer.org>

	* app/dialogs/makefile.msc : [new file]
	  app/dialogs/Makefile.am : added to EXTRA_DIST

	* **/makefile.msc app/gimpcore.def : updated

	* app/gimp.rc : let wilber be first

	* app/widgets/gimppropwidgets.c : msvc6 can't cast uint64 either

	* libgimpbase/gimpwin32-io.h : make up recent loss of ftruncate in GLib

	* libgimpthumbnail/gimpthumbnail.c : <process.h> for getpid() on win32

	* plug-ins/helpbrowser/dialog.c : include gimpwin32-io.h

	* plug-ins/script-fu/siodwrapper.c plug-ins/script-fu/scrip-fu.c : there
	is no script-fu-server on win32
2004-11-21 14:22:45 +00:00
Sven Neumann 5c002d9b33 fixed check for number of return values.
2004-11-18  Sven Neumann  <sven@gimp.org>

	* app/file/file-open.c (file_open_thumbnail): fixed check for
	number of return values.
2004-11-18 21:31:20 +00:00
Sven Neumann 181c089a51 check the number of return values. Only retrieve width and height if the
2004-11-18  Sven Neumann  <sven@gimp.org>

	* app/file/file-open.c (file_open_thumbnail): check the number of
	return values. Only retrieve width and height if the thumbnail
	load procedure does actually provide such this information.

	* plug-ins/common/postscript.c: added a procedure to loads
	thumbnails.  For now it only renders the first page of the
	document at low resolution. It should be extended to load an
	embedded thumbnail if available.

	* plug-ins/common/jpeg.c
	* plug-ins/common/svg.c: no need to register a menu label for the
	thumbnail loaders. Allocate the return_vals array large enough to
	hold all return values.
2004-11-18 19:00:02 +00:00
Sven Neumann d4bf381c20 app/actions/file-commands.c app/dialogs/file-save-dialog.c
2004-11-16  Sven Neumann  <sven@gimp.org>

	* app/actions/file-commands.c
	* app/dialogs/file-save-dialog.c
	* app/file/file-save.[ch]
	* app/widgets/gimpfiledialog.[ch]: combined "set_uri_and_proc" and
	"set_image_clean" parameters into a single "save_a_copy"
	parameter.  When saving a copy, attach the used URI to the image and
	let the "Save a Copy" file chooser default to the last used value.
2004-11-16 13:37:36 +00:00
Manish Singh 5d01581069 Fix a bunch of warnings from Sparse:
2004-11-13  Manish Singh  <yosh@gimp.org>

        Fix a bunch of warnings from Sparse:

        * app/actions/dockable-commands.c
        * app/actions/layers-actions.c
        * app/actions/view-commands.c
        * app/base/pixel-surround.c
        * app/config/gimpconfig-utils.c
        * app/config/gimpscanner.c
        * app/core/gimpbrushgenerated.c
        * app/core/gimpcontainer.c
        * app/core/gimpimage.c
        * app/dialogs/palette-import-dialog.c
        * app/file/gimprecentlist.c
        * app/plug-in/plug-in-params.c
        * app/text/gimptext-compat.c
        * app/text/gimptext-parasite.c
        * app/vectors/gimpbezierstroke.c
        * app/vectors/gimpstroke.c
        * app/widgets/gimpcellrendereraccel.c
        * app/widgets/gimpselectiondata.c
        * app/xcf/xcf.c
        * libgimp/gimp.c
        * libgimpthumb/gimpthumb-utils.c
        * libgimpthumb/gimpthumbnail.c
        * modules/cdisplay_proof.c
        * plug-ins/Lighting/lighting_ui.c
        * plug-ins/common/csource.c
        * plug-ins/common/glasstile.c
        * plug-ins/common/nova.c
        * plug-ins/common/pcx.c
        * plug-ins/common/pnm.c
        * plug-ins/common/randomize.c
        * plug-ins/common/screenshot.c
        * plug-ins/common/sel_gauss.c
        * plug-ins/common/spheredesigner.c
        * plug-ins/common/wind.c
        * plug-ins/gfig/gfig-dialog.c
        * plug-ins/gfig/gfig-dobject.c
        * plug-ins/gimpressionist/gimpressionist.c
        * plug-ins/ifscompose/ifscompose.c
        * plug-ins/print/gimp_main_window.c
        * plug-ins/print/print.c: Cleanup integer vs. pointer confusion.

        * app/base/temp-buf.c
        * app/dialogs/about-dialog.c
        * plug-ins/common/bumpmap.c
        * plug-ins/common/jigsaw.c
        * plug-ins/gfig/gfig-dobject.c: Cosmetic cleanups.

        * app/config/gimpconfig-deserialize.c
        * app/config/gimpconfig-path.c
        * app/config/gimpconfigwriter.c
        * app/core/gimpgradient.c
        * app/tools/gimpdrawtool.c
        * plug-ins/common/nlfilt.c
        * plug-ins/common/unsharp.c
        * plug-ins/common/zealouscrop.c: Define inline functions before they
        are used.

        * app/core/gimpdrawable-blend.c: PixelRegion definition was changed
        some time ago, but the initialization here didn't change. Fix it.

        * app/plug-in/plug-in-rc.c (plug_in_extra_deserialize): No need to
        assign token twice in a row.

        * libgimpbase/gimpdatafiles.c (gimp_datafiles_read_directories): No
        need to initialize file_data, since the code fills out all the fields.

        * plug-ins/common/CML_explorer.c
        * plug-ins/common/vpropagate.c: Declare function pointers fully.

        * plug-ins/common/grid.c (pix_composite): G_INLINE_FUNC isn't needed,
        we assume we can use the "inline" keyword always.

        * plug-ins/common/psd_save.c
        * plug-ins/common/vinvert.c
        * plug-ins/gfig/gfig-arc.c
        * plug-ins/gfig/gfig-bezier.c
        * plug-ins/gfig/gfig-circle.c
        * plug-ins/gfig/gfig-dialog.c
        * plug-ins/gfig/gfig-dobject.c
        * plug-ins/gfig/gfig-ellipse.c
        * plug-ins/gfig/gfig-line.c
        * plug-ins/gfig/gfig-poly.c
        * plug-ins/gfig/gfig-spiral.c
        * plug-ins/gfig/gfig-star.c
        * plug-ins/gfig/gfig.c
        * plug-ins/gimpressionist/orientmap.c
        * plug-ins/gimpressionist/placement.c
        * plug-ins/gimpressionist/sizemap.c
        * plug-ins/imagemap/imap_grid.c
        * plug-ins/imagemap/imap_main.c
        * plug-ins/imagemap/imap_preferences.c
        * plug-ins/imagemap/imap_settings.c
        * plug-ins/maze/maze.c
        * plug-ins/sel2path/curve.c
        * plug-ins/sel2path/fit.c
        * plug-ins/sel2path/pxl-outline.c
        * plug-ins/sel2path/spline.c
        * plug-ins/xjt/xjt.c: Functions with no args should be declared
        with (void).

        * plug-ins/common/retinex.c (MSRCR): Initialize max_preview to quiet
        the compiler.
2004-11-14 02:50:33 +00:00
Sven Neumann 5a3b3fff70 app/core/gimpimagefile.[ch] app/file/file-open.c pass the MIME type from
2004-11-13  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch]
	* app/file/file-open.c
	* app/file/file-save.c: pass the MIME type from the save procedure
	to gimp_imagefile_save_thumbnail() so that it can be stored with
	the thumbnail.

	* tools/pdbgen/pdb/fileops.pdb
	* app/pdb/fileops_cmds.c: changed accordingly.
2004-11-13 17:13:21 +00:00
Sven Neumann b62ca985aa app/plug-in/plug-in-proc-def.[ch] app/plug-in/plug-in-rc.c allow to
2004-11-13  Sven Neumann  <sven@gimp.org>

	* app/plug-in/plug-in-proc-def.[ch]
	* app/plug-in/plug-in-rc.c
	* app/plug-in/plug-ins.[ch]: allow to associate a procedure for
	thumbnail loading with any file load procedure.

	* tools/pdbgen/pdb/fileops.pdb: export this functionality to the
	PDB as gimp_register_thumbnail_loader().

	* app/pdb/fileops_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimpfileops_pdb.[ch]: regenerated.

	* app/core/gimpimagefile.c
	* app/file/file-open.[ch]: when creating a thumbnail for an image
	file, use a thumbnail load procedure if available.

	* plug-ins/common/svg.c: added "file_svg_load_thumb", a procedure
	that allows to load a small preview of the SVG image.
2004-11-13 17:06:06 +00:00
Sven Neumann 0dc715748f add the image to the list of recently used documents. Fixes bug #157879.
2004-11-10  Sven Neumann  <sven@gimp.org>

	* app/file/file-open.c (file_open_layer): add the image to the
	list of recently used documents. Fixes bug #157879.
2004-11-10 21:48:17 +00:00
Sven Neumann d001c17785 when the filename cannot be converted to UTF-8, warn and return the URI
2004-10-29  Sven Neumann  <sven@gimp.org>

	* app/file/file-utils.c (file_utils_uri_to_utf8_filename): when
	the filename cannot be converted to UTF-8, warn and return the URI
	instead. This is a workaround for the crash described in bug #153751.
2004-10-29 13:04:04 +00:00
Sven Neumann ea273aadb9 libgimpthumb/gimpthumb-utils.[ch] libgimpthumb/gimpthumbnail.[ch] added
2004-10-23  Sven Neumann  <sven@gimp.org>

	* libgimpthumb/gimpthumb-utils.[ch]
	* libgimpthumb/gimpthumbnail.[ch]
	* libgimpthumb/gimpthumb.def: added missing API, mainly for deleting
	thumbnails.

	* app/core/gimpimagefile.[ch]: when saving a thumbnail, delete a
	failure thumbnail if one exists. Unless the thumbnail was created
	explicitely, remove all other thumbnails for this image.

	* app/actions/documents-commands.c: changed accordingly.

	* app/file/file-open.c: only save a thumbnail if there isn't a
	valid thumbnail already.

	* app/widgets/gimpthumbbox.c: before attempting to create a new
	thumbnail, check if there's an uptodate failure thumbnail.
2004-10-23 15:30:39 +00:00
Sven Neumann f398bbfec6 minor cleanup.
2004-10-12  Sven Neumann  <sven@gimp.org>

	* app/file/file-open.c: minor cleanup.

	* app/file/file-save.c (file_save_as): no need to fiddle with the
	image name, the URI is taken from the imagefile anyway.
2004-10-12 19:04:03 +00:00
Sven Neumann ec693d7b09 app/config/gimpcoreconfig.[ch] added new gimprc option
2004-10-08  Sven Neumann  <sven@gimp.org>

	* app/config/gimpcoreconfig.[ch]
	* app/config/gimprc-blurbs.h: added new gimprc option
	"thumbnail-filesize-limit" that allows to control the maximum
	filesize for automatic thumbnail creation.

	* app/dialogs/preferences-dialog.c: added a GUI for it, needs
	review.

	* app/core/gimpimagefile.[ch]: minor cleanups. Moved call to
	gimp_thumbnail_peek_image() from gimp_imagefile_save_thumb() to
	 gimp_imagefile_save_thumbnail() to avoid it being called twice.

	* app/file/file-utils.[ch]: export utility function
	file_utils_find_proc_by_extension() that allows to check for a
	file plug-in by looking at the filename extension only.

	* app/widgets/gimpthumbbox.[ch]: automatically create or update
	thumbnails for image files with a known extension that are smaller
	than "thumbnail-filesize-limit".  Fixes bug #137176.
2004-10-08 19:29:33 +00:00
Sven Neumann 983e918d13 added lots of const qualifiers.
2004-10-08  Sven Neumann  <sven@gimp.org>

	* app/file/file-utils.c: added lots of const qualifiers.
2004-10-08 12:23:36 +00:00
Sven Neumann 4473915408 don't write empty groups.
2004-09-28  Sven Neumann  <sven@gimp.org>

	* app/file/gimprecentlist.c (gimp_recent_list_write): don't write
	empty groups.

	* app/file/gimprecentlist.c: disabled the code for the win32
	platform. It doesn't make much sense there anyway. If someone
	wants to contribute a win32 specific implementation, we'd welcome
	that. A Mac OS X implementation would be nice to have as well.
2004-09-28 21:17:57 +00:00
Sven Neumann 4c450f2357 seek to the start of the file before calling lockf().
2004-09-28  Sven Neumann  <sven@gimp.org>

	* app/file/gimprecentlist.c: seek to the start of the file before
	calling lockf().
2004-09-28 18:57:58 +00:00
Sven Neumann 5ad16c6fcc handle EINTR while writing.
2004-09-28  Sven Neumann  <sven@gimp.org>

	* app/file/gimprecentlist.c (gimp_recent_list_write_raw): handle
	EINTR while writing.
2004-09-28 12:50:43 +00:00
Sven Neumann 734464155f added new convenience function gimp_xml_parser_parse_fd().
2004-09-28  Sven Neumann  <sven@gimp.org>

	* app/config/gimpxmlparser.[ch]: added new convenience function
	gimp_xml_parser_parse_fd().

	* app/file/Makefile.am
	* app/file/gimprecentitem.[ch]
	* app/file/gimprecentlist.[ch]: added an implementation of the
	recent-files spec as found on freedesktop.org. This code is taken
	from libegg and has been edited to fit the GIMP needs.

	* app/file/file-open.c
	* app/file/file-save.c: update the ~/.recently-used file. Fixes
	bug #131206.
2004-09-28 12:40:34 +00:00
Michael Natterer 9ffc00be80 app/plug-in/Makefile.am removed... ...and added with a new name.
2004-09-22  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/Makefile.am
	* app/plug-in/plug-in-proc.[ch]: removed...
	* app/plug-in/plug-in-proc-def.[ch]: ...and added with a new name.

	* app/plug-in/plug-in-def.[ch]
	* app/plug-in/plug-in-message.[ch]
	* app/plug-in/plug-in-progress.[ch]
	* app/plug-in/plug-in-rc.[ch]
	* app/plug-in/plug-in-run.[ch]
	* app/plug-in/plug-in.[ch]
	* app/plug-in/plug-ins.[ch]
	* app/actions/plug-in-actions.c
	* app/actions/plug-in-commands.c
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/file/file-utils.[ch]
	* app/gui/gui-vtable.c
	* app/menus/plug-in-menus.c
	* app/widgets/gimpfiledialog.c
	* app/widgets/gimpfileprocview.c
	* app/widgets/gimppluginaction.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/fileops.pdb
	* tools/pdbgen/pdb/plug_in.pdb: changed accordingly plus some
	minor cosmetic cleanups.

	* app/pdb/fileops_cmds.c
	* app/pdb/plug_in_cmds.c: regenerated.
2004-09-22 15:12:24 +00:00
Michael Natterer 02d2b990f5 Redid the whole internal progress stuff: don't pass around
2004-08-10  Michael Natterer  <mitch@gimp.org>

	Redid the whole internal progress stuff: don't pass around
	progress_callback and progress_data; instead, provide a
	pointer to a GimpProgressInterface which can be implemented
	by a variety of backends.

	Addresses (but not yet fixes) bugs #6010, #97266 and #135185.

	* app/display/Makefile.am
	* app/display/gimpprogress.[ch]: removed the old progress hack.

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpprogress.[ch]: implement GimpProgressInterface.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpprogressdialog.[ch]: the standalone progress
	dialog as widget implementing GimpProgressInterface.

	* app/display/gimpdisplay.c
	* app/display/gimpstatusbar.[ch]
	* app/widgets/gimpfiledialog.[ch]
	* app/widgets/gimpthumbbox.[ch]: added GimpProgressInterface
	implementation to these classes.

	* app/core/gimp-gui.[ch]
	* app/gui/gui-vtable.c: replaced the old progress vtable entries
	by two new to create and destroy a GimpProgressDialog in case
	no other progress is available.

	* app/pdb/procedural_db.[ch]
	* app/plug-in/plug-in-run.[ch]
	* tools/pdbgen/app.pl: pass a GimpProgress to all PDB wrappers and
	all plug-ins.

	* app/plug-in/plug-in.[ch]
	* app/plug-in/plug-ins.c
	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-in-progress.c: handle the case there the
	plug-in was crated with a progress as well as the case where it
	wasn't.

	* app/app_procs.c
	* app/batch.c
	* app/xcf/xcf.c
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/widgets/gimphelp.c
	* app/widgets/gimpbrushselect.c
	* app/widgets/gimpfontselect.c
	* app/widgets/gimpgradientselect.c
	* app/widgets/gimppaletteselect.c
	* app/widgets/gimppatternselect.c: changed accordingly.

	* app/core/gimpimagefile.[ch]
	* app/display/gimpdisplayshell-dnd.c
	* app/gui/file-open-dialog.c
	* app/gui/file-open-location-dialog.c
	* app/gui/file-save-dialog.c
	* app/widgets/gimplayertreeview.c
	* app/widgets/gimptoolbox-dnd.c: pass a GimpProgress to all file
	related functions. Embed the progress in the file dialog where
	possible.

	* app/core/gimpdrawable-blend.[ch]
	* app/core/gimpdrawable-transform.[ch]
	* app/core/gimpimage-convert.[ch]
	* app/core/gimpimage-flip.[ch]
	* app/core/gimpimage-resize.[ch]
	* app/core/gimpimage-rotate.[ch]
	* app/core/gimpimage-scale.[ch]
	* app/core/gimpitem-linked.[ch]
	* app/core/gimpitem.[ch]
	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/core/gimplayer.c
	* app/core/gimpselection.c
	* app/vectors/gimpvectors.c: replaced callback/data by GimpProgress.

	* app/tools/gimpblendtool.c
	* app/tools/gimptransformtool.c
	* app/gui/convert-dialog.c
	* app/actions/documents-commands.c
	* app/actions/file-commands.c
	* app/actions/image-commands.c
	* app/actions/layers-commands.c
	* app/actions/plug-in-commands.c
	* app/actions/vectors-commands.c
	* tools/pdbgen/pdb/convert.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb: changed callers accordingly.

	* app/pdb/*_cmds.c: regenerated.
2004-08-10 18:47:21 +00:00
Michael Natterer 963b941d39 don't crash if no layer or only one layer is visible. Fixes bug #143804.
2004-07-15  Michael Natterer  <mitch@gimp.org>

	* app/file/file-open.c (file_open_layer): don't crash if no
	layer or only one layer is visible. Fixes bug #143804.

	* app/app_procs.c (app_run): fixed log domain registration.
2004-07-15 10:37:03 +00:00
Michael Natterer c5c63f31ee new utility function which opens an image, flattens it if needed and
2004-06-28  Michael Natterer  <mitch@gimp.org>

	* app/file/file-open.[ch] (file_open_layer): new utility function
	which opens an image, flattens it if needed and returns the only
	layer, converted for a passed destination image.

	* app/display/gimpdisplayshell-dnd.c
	(gimp_display_shell_drop_files): use the new function.
2004-06-28 21:42:19 +00:00
Sven Neumann c509204b7d tools/pdbgen/pdb/image.pdb app/pdb/image_cmds.c reverted changes I did to
2004-06-01  Sven Neumann  <sven@gimp.org>

	* tools/pdbgen/pdb/image.pdb
	* app/pdb/image_cmds.c
	* app/core/gimpimage.[ch]: reverted changes I did to the image
	unit earlier. As in 2.0, it will continue to not accept pixels.
	This makes the PDB API and the XCF format compatible again and
	fixes bug #142961 (and to some extent bug #137704).

	* app/core/Makefile.am
	* app/core/gimpimage-unit.[ch]: removed these files. The
	convenience accessors defined here aren't commonly used any
	longer.

	* app/display/gimpdisplay.[ch]
	* app/display/gimpdisplayshell.[ch]: added a unit parameter to
	gimp_display_new(). Made "unit" and "scale" properties of
	GimpDisplayShell.

	* app/actions/image-commands.c
	* app/actions/images-commands.c
	* app/actions/layers-commands.c
	* app/actions/select-commands.c
	* app/actions/view-commands.c
	* app/core/gimp-edit.c
	* app/core/gimp.[ch]
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-handlers.c
	* app/display/gimpdisplayshell-scale.c
	* app/display/gimpdisplayshell-title.c
	* app/display/gimpstatusbar.c
	* app/file/file-open.c
	* app/gui/gui-vtable.c
	* app/gui/info-window.c
	* app/gui/offset-dialog.c
	* app/gui/resize-dialog.[ch]
	* app/pdb/display_cmds.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimppainttool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/vectors/gimpvectors-export.c
	* app/widgets/gimptoolbox-dnd.c
	* tools/pdbgen/pdb/display.pdb: changed accordingly. Use the
	display unit where the image unit was used before.
2004-06-01 22:04:20 +00:00
Sven Neumann 97fe81b401 added new PDB function gimp_register_file_handler_mime() that allows to
2004-05-14  Sven Neumann  <sven@gimp.org>

	* tools/pdbgen/pdb/fileops.pdb: added new PDB function
	gimp_register_file_handler_mime() that allows to associate a MIME
	type with a file procecdurre.

	* app/pdb/fileops_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimpfileops_pdb.[ch]: regenerated.

	* app/plug-in/plug-in-proc.[ch]
	* app/plug-in/plug-in-rc.c
	* app/plug-in/plug-ins.[ch]: store a mimetype with file procedures.

	* app/actions/file-commands.c
	* app/core/gimpdocumentlist.[ch]
	* app/core/gimpimagefile.[ch]
	* app/file/file-open.[ch]
	* app/file/file-save.c: set the thumbnail's mimetype from the file
	procedure used to load/save the image.

	* app/xcf/xcf.c
	* plug-ins/bmp/bmp.c
	* plug-ins/common/csource.c
	* plug-ins/common/dicom.c
	* plug-ins/common/gif.c
	* plug-ins/common/gifload.c
	* plug-ins/common/jpeg.c
	* plug-ins/common/mng.c
	* plug-ins/common/png.c
	* plug-ins/common/postscript.c
	* plug-ins/common/psd.c
	* plug-ins/common/psd_save.c
	* plug-ins/common/sunras.c
	* plug-ins/common/svg.c
	* plug-ins/common/tga.c
	* plug-ins/common/tiff.c
	* plug-ins/common/wmf.c
	* plug-ins/common/xbm.c
	* plug-ins/common/xpm.c
	* plug-ins/common/xwd.c
	* plug-ins/faxg3/faxg3.c
	* plug-ins/winicon/main.c: register a mimetype, set a translatable
	action name (taken from shared-mime-info) and register to the <Load>
	and <Save> menus using gimp_plugin_menu_register().
2004-05-14 00:01:11 +00:00
Michael Natterer 18d9161eea Get rid of the "current_context" which was in fact just a bunch of global
2004-04-15  Michael Natterer  <mitch@gimp.org>

	Get rid of the "current_context" which was in fact just a bunch of
	global variables. Instead, pass the needed context all the way
	from the GUI and the PDB to the core. This is a prerequisite for
	macro recording and generally helps separating the various
	subsystems from each other. Work in progress...

	* app/core/gimp.[ch]: removed member "current_context" and
	gimp_[get|set]_current_context().

	* app/core/gimp-edit.[ch]
	* app/core/gimpdrawable-blend.[ch]
	* app/core/gimpdrawable-bucket-fill.[ch]
	* app/core/gimpdrawable-offset.[ch]
	* app/core/gimpdrawable-transform.[ch]
	* app/core/gimpimage-crop.[ch]
	* app/core/gimpimage-flip.[ch]
	* app/core/gimpimage-merge.[ch]
	* app/core/gimpimage-resize.[ch]
	* app/core/gimpimage-rotate.[ch]
	* app/core/gimpimage.[ch]
	* app/core/gimpimagefile.[ch]
	* app/core/gimpitem-linked.[ch]
	* app/core/gimpitem.[ch]
	* app/core/gimplayer.[ch]
	* app/core/gimpselection.[ch]
	* app/core/gimptemplate.[ch]
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/pdb/procedural_db.[ch]
	* app/text/gimptext-compat.[ch]
	* app/text/gimptextlayer-transform.[ch]
	* app/gui/brush-select.[ch]
	* app/gui/font-select.[ch]
	* app/gui/gradient-select.[ch]
	* app/gui/palette-select.[ch]
	* app/gui/pattern-select.[ch]: added tons of "GimpContext *context"
	parameters and use the passed context instead of
	gimp_get_current_context().

	* app/app_procs.c
	* app/batch.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable.c
	* app/paint/gimperaser.c
	* app/paint/gimppaintbrush.c
	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-ins.c
	* app/text/gimptextlayer.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpinktool.c
	* app/tools/gimptransformtool.c
	* app/vectors/gimpvectors.c
	* app/gui/convert-dialog.c
	* app/gui/drawable-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/file-new-dialog.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/offset-dialog.c
	* app/gui/select-commands.c
	* app/gui/vectors-commands.c
	* app/widgets/gimpdnd.c
	* app/widgets/gimpdocumentview.c
	* app/widgets/gimphelp.c
	* app/widgets/gimpthumbbox.c: pass gimp_get_user_context() or
	GIMP_CONTEXT(tool_options) or whatever is the right context
	to the changed core functions.

	* tools/pdbgen/app.pl: pass "GimpContext *context" to all
	generated PDB invokers.

	* tools/pdbgen/pdb/brush_select.pdb
	* tools/pdbgen/pdb/brushes.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/font_select.pdb
	* tools/pdbgen/pdb/gradient_select.pdb
	* tools/pdbgen/pdb/gradients.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/paint_tools.pdb
	* tools/pdbgen/pdb/palette.pdb
	* tools/pdbgen/pdb/palette_select.pdb
	* tools/pdbgen/pdb/palettes.pdb
	* tools/pdbgen/pdb/paths.pdb
	* tools/pdbgen/pdb/pattern_select.pdb
	* tools/pdbgen/pdb/patterns.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/text_tool.pdb
	* tools/pdbgen/pdb/transform_tools.pdb: pass the new context
	parameter to the changed core functions.

	* app/pdb/*_cmds.c: regenerated.
2004-04-14 23:37:34 +00:00
Michael Natterer bbc73e63bc removed the undo clearing/sanitizing code...
2004-03-22  Michael Natterer  <mitch@gimp.org>

	* app/file/file-open.c (file_open_with_proc_and_display): removed
	the undo clearing/sanitizing code...

	(file_open_image): ...and added it here so *all* newly opened
	images start with a clean and sane undo state.

	* app/gui/file-commands.c (file_revert_confirm_callback): removed
	(incomplete) undo sanitizing here too.
2004-03-22 13:46:14 +00:00
Simon Budig dfd41249fe app/core/gimpimage.[ch] renamed gimage->freeze_count to
2004-03-15  Simon Budig  <simon@gimp.org>

	* app/core/gimpimage.[ch]
	* app/core/gimpimage-undo.c: renamed gimage->freeze_count
	to gimage->undo_freeze_count (more explicit).

	* app/file/file-open.c: Ensure that the undo system is enabled
	after loading an image (to protect against broken loaders).
2004-03-14 23:19:49 +00:00
Simon Budig 657bd9fff7 app/core/gimpimage.[ch] introduced a freeze counter, so that
2004-03-14  Simon Budig  <simon@gimp.org>

	* app/core/gimpimage.[ch]
	* app/core/gimpimage-undo.c: introduced a freeze counter, so
	that undo_freeze(); undo_freeze(); undo_thaw(); no longer
	results in an thawed undo stack.

	Fixes Bug #124176.

	This might reveal other places in the code where
	gimp_image_undo_freeze/thaw or gimp_image_undo_disable/enable
	were used in an inconsistent (not-paired) manner.

	* app/file/file-open.c: e.g. here, where _enable was called on
	the new image. The intention was to free a potential undo stack,
	so now call gimp_image_undo_free() instead.
2004-03-14 19:10:55 +00:00
Michael Natterer 5568644538 added missing cast.
2004-02-26  Michael Natterer  <mitch@gimp.org>

	* app/file/file-open.c (file_open_image): added missing cast.

	* app/widgets/gimperrorconsole.[ch]
	* app/widgets/gimptexteditor.[ch]: renamed members so my file
	chooser patch becomes smaller ;)
2004-02-26 20:04:20 +00:00
Pedro Gimeno 738d31d3a4 Applied a fix by Michael Natterer addressing a problem with the preview in
2004-02-26  Pedro Gimeno  <pggimeno@wanadoo.es>

	* app/file/file-open.c (file_open_image): Applied a fix by
	Michael Natterer addressing a problem with the preview in the
	open images list when loading a file.
2004-02-26 16:59:34 +00:00
Manish Singh d14a5075ed app/file/Makefile.am app/paint/Makefile.am app/text/Makefile.am changed
2004-02-09  Manish Singh  <yosh@gimp.org>

        * app/file/Makefile.am
        * app/paint/Makefile.am
        * app/text/Makefile.am
        * app/xcf/Makefile.am: changed GTK_CFLAGS to GDK_PIXBUF_CFLAGS, since
        we don't use any gtk/gdk functions here. This especially helps in the
        text directory, since it avoids problems on broken setups with old
        fontconfig stuff in the X11 directory lying around.
2004-02-09 09:11:10 +00:00
Hans Breuer 5cbb416a91 new file to keep common definitions for the msc build use common
2004-02-07  Hans Breuer  <hans@breuer.org>

	* gimpdefs.msc : new file to keep common definitions for the msc build
	* **/makefile.msc : use common defintions, e.g. GIMP_VER
	* Makefile.am : add the former to EXTRA_DIST
2004-02-07 23:01:33 +00:00
Michael Natterer b147234460 added new function plug_in_proc_def_compare_menu_path() which is a
2004-02-03  Michael Natterer  <mitch@gimp.org>

	* app/plug-in/plug-in-proc.[ch]: added new function
	plug_in_proc_def_compare_menu_path() which is a GCompareDataFunc.
	(uses g_utf8_collate() on the translated menu paths).

	* app/plug-in/plug-ins.c (plug_ins_init): sort gimp->load_procs
	and gimp->save_procs using the new compare function above.
	Fixes bug #133180.

	(plug_ins_locale_domain)
	(plug_ins_help_domain): don't g_return_if_fail() on a NULL
	prog_name but return the default locale and help domains
	of the GIMP itself.

	(plug_ins_proc_def_insert): removed obsolete and broken (not
	locale and UTF-8 aware) code which tried to insert new plug-in
	menu entries in alphabetical order (was unused except for load
	and save procs).

	Unrelated:

	* app/plug-in/plug-in-proc.[ch]: added const qualifiers.

	* app/file/file-open.c
	* app/file/file-save.c
	* tools/pdbgen/pdb/fileops.pdb: changed accordingly (constify
	local variables).

	* app/pdb/fileops_cmds.c: regenerated.
2004-02-03 13:02:18 +00:00
Simon Budig 645a1ab652 Store the zoom factor as float, not as a ratio.
2004-01-29  Simon Budig  <simon@gimp.org>

	* app/display/gimpdisplayshell.[ch]: Store the zoom factor as
	float, not as a ratio.

	* app/display/gimpdisplayshell-scale.[ch]: change the API to
	expose the Float instead a weirdly encoded integer. Implement
	functions to get a ratio from the scale factor. Implement a set
	as presets as discussed on the mailinglist. Changed Zoom->Other
	dialog to enable entering a float.

	* app/display/gimpdisplayshell-title.c
	* app/display/gimpnavigationview.c
	* app/gui/image-menu.c
	* app/gui/info-window.c
	* app/tools/gimpmagnifytool.c: changed accordingly.

	* app/core/gimp.[ch]
	* app/display/gimpdisplay.[ch]
	* app/gui/gui-vtable.c
	* app/widgets/widgets-enums.h: Made the various display-creating
	functions accept a float for the scale. Introduce a new
	GimpZoomType: GIMP_ZOOM_TO. Generally adjust the API to use
	floats instead of weird integers.

	* app/core/gimp-edit.c
	* app/core/gimptemplate.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/file/file-open.c
	* app/gui/image-commands.c
	* app/gui/view-commands.[ch]
	* tools/pdbgen/pdb/display.pdb
	* app/widgets/gimpimageview.c
	* app/widgets/gimptoolbox-dnd.c: changed accordingly

	* app/pdb/display_cmds.c: regenerated
2004-01-29 22:22:29 +00:00
Michael Natterer 1f07af7223 removed inclusion of <stdio.h> and "plug-in/plug-in-types.h".
2004-01-19  Michael Natterer  <mitch@gimp.org>

	* app/file/file-utils.h: removed inclusion of <stdio.h> and
	"plug-in/plug-in-types.h".
2004-01-19 02:34:47 +00:00
Sven Neumann a70698c4d9 removed file_utils_filename_to_utf8() ...
2004-01-19  Sven Neumann  <sven@gimp.org>

	* app/file/file-utils.[ch]: removed file_utils_filename_to_utf8() ...

	* libgimpbase/gimputils.[ch]: ... and added it here as
	gimp_filename_to_utf8(). Added some docs that promise less than
	the current implementation holds so that we can change the
	implementation later.

	* app/*/*.c: use gimp_filename_to_utf8() where
	file_utils_filenames_to_utf8() has been used before.

	* libgimpbase/gimpbase.def: changed accordingly.

	* configure.in: reset GIMP_INTERFACE_AGE.
2004-01-19 01:08:43 +00:00
Tor Lillqvist 18485018b3 Add new function file_utils_filename_to_utf8(), which is to be used when
2004-01-14  Tor Lillqvist  <tml@iki.fi>

	* app/file/file-utils.[ch]: Add new function
	file_utils_filename_to_utf8(), which is to be used when converting
	file names (which are kept in the on-disk encoding) to UTF-8 for
	passing to GTK, or to g_print() etc.

	* app/*/*.c: Call file_utils_filename_to_utf8(). Should fix most
	of the warnings generated by non-UTF8 pathnames. See #130118.

	* libgimpbase/gimpenv.b: Document that gimp_directory() etc return
	strings in the on-disk encoding.

	* libgimpmodule/gimpmodule.c: Convert filenames to UTF-8 (using
	g_filename_to_utf8()) before passing to g_print().
2004-01-14 02:03:37 +00:00
Hans Breuer 1baa2d4581 [ I've postponed my reservations against pangoft2/fontconfig/freetype2
2003-12-12  Hans Breuer  <hans@breuer.org>

	[
	 I've postponed my reservations against pangoft2/fontconfig/freetype2
	 usage, so The Gimp should now build with msvc without patching it.
	]

	* app/makefile.msc app/text/makefile.msc : use $(PANGOFT2_CFLAGS) etc.

	* libgimpthumb/makefile.msc : (new file)
	* makefile.msc : added libgimpthumb

	* libgimpthumb/gimpthumbnail.c : include gimpwin32-io.h
	* libgimpthumb/gimpthumb-utils.c : don't compare size pointer
	with GIMP_THUMB_SIZE_FAIL but *size

	* plug-ins/makefile.msc : handle libgimpoldpreview

	* plug-ins/common/decompose.c : define cbrt() if not __GLIBC__

	* plug-ins/common/winclipboard.c : make it compile without gimpcompat.h

	* plug-ins/imagemap/imagemap_csim_lex.c : its a generated file
	but still win32/msvc has no unistd.h

	* plug-ins/pygimp/makefile.msc : (new file) to use the binary you
	need to patch glib, see bug #98737

	* plug-ins/libgimpoldpreview.c : use <libgimp/gimp.h> instead of "gimp.h"

	* **/Makefile.am : added makefile.msc to EXTRA_DIST
2003-12-13 01:35:19 +00:00