Commit Graph

34 Commits

Author SHA1 Message Date
Michael Natterer ab607a0adc app: add gimp_imagegile_get_gicon() which uses async API and can't block
and use it in gimp_view_renderer_imagefile_get_icon().
2011-06-19 23:06:33 +02:00
Michael Natterer c550eae5e1 app: move all GimpImagefile members to private 2011-03-02 12:26:04 +01: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 3344c1b3bc Do not any longer keep the document history in two places. We only use
2008-03-24  Sven Neumann  <sven@gimp.org>

	Do not any longer keep the document history in two places. We 
only
	use GtkRecentManager now:

	* app/core/Makefile.am
	* app/core/gimp-documents.[ch]: removed these files.

	* app/core/gimpdocumentlist.c: removed code to load and save the
	"documents" file.
	(gimp_document_list_add_uri): call gimp_recent_list_add_uri() 
here.

	* app/core/gimpimagefile.[ch]: added function to set the 
mime-type.

	* app/core/gimp.c (gimp_restore): removed code to load the
	document history.
	(gimp_real_exit): removed code to save it.
	
	* app/core/gimp-gui.[ch]: extended the vtable with a method to
	populate the document list.

	* app/gui/gui-vtable.c: added code to populate the document 
history
	from the list of recently used files kept by GtkRecentManager.

	* app/gui/gui.c (gui_restore_callback): load the recent files 
here.

	* app/file/file-open.c
	* app/file/file-save.c: no need to call 
gimp_recent_list_add_uri()
	any longer as gimp_document_list_add_uri() does that for us now.

	* app/actions/documents-commands.c 
(documents_clear_cmd_callback):
	purge the items from GtkRecentManager. Also changed the dialog 
to
	emphasize that this operation now affects the document history 
in
	all applications.

	* docs/gimp.1.in: removed reference to "documents" file.


svn path=/trunk/; revision=25190
2008-03-24 11:11:15 +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
Sven Neumann 905fdfcbed did a global gimage -> image substitution.
2006-03-28  Sven Neumann  <sven@gimp.org>

	* app/*: did a global gimage -> image substitution.
2006-03-28 17:08:36 +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 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 280a497f48 ref the imagefile while creating the thumbnail.
2004-10-13  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.c (gimp_imagefile_create_thumbnail): ref
	the imagefile while creating the thumbnail.

	* app/core/gimpimagefile.[ch]
	* app/widgets/gimpthumbbox.c (gimp_thumb_box_auto_thumbnail): moved
	the tricky part about thumbnail creation into the new function
	gimp_imagefile_create_thumbnail_weak().
2004-10-12 23:25:19 +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
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
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
Sven Neumann 8c32fa9b6d removed the size parameter and do nothing but invalidating the preview.
2004-01-10  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch] (gimp_imagefile_update): removed the
	size parameter and do nothing but invalidating the preview.

	* app/gui/file-open-dialog.c
	* app/widgets/gimpdocumentview.c: changed accordingly.

	* app/core/gimpdocumentlist.c (gimp_document_list_deserialize):
	no need for calling gimp_imagefile_update() from here.

	* tools/pdbgen/pdb/fileops.pdb
	* app/pdb/fileops_cmds.c (file_load_thumbnail): rewritten using the
	GimpThumbnail API.

	* app/core/gimp.c: cosmetics.
2004-01-10 23:55:28 +00:00
Sven Neumann d8903a2477 added libgimpthumb.
2003-12-08  Sven Neumann  <sven@gimp.org>

	* Makefile.am (SUBDIRS): added libgimpthumb.

	* libgimpthumb/gimpthumb-utils.c
	* libgimpthumb/gimpthumbnail.c: basic functionality is implemented
	and seems to be working.

	* app/Makefile.am: link the application against libgimpthumb.

	* app/core/core-types.h: include libgimpthumb/gimpthumb-types.h.

	* app/core/gimpimagefile.[ch]: removed thumbnail handling routines
	and use libgimpthumb instead. Fixes bug #127914.

	* app/gui/file-open-dialog.c
	* app/widgets/gimpdocumentview.c: changed accordingly.
2003-12-08 09:12:25 +00:00
Michael Natterer 99d93b9255 added vitrual function GimpViewable::get_description() which returns the
2003-04-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpviewable.[ch]: added vitrual function
	GimpViewable::get_description() which returns the string that
	should be presented to the user plus an optional tooltip with more
	information. The default implementation just returns the object's
	name and no tooltip.

	* app/core/gimpbrush.c
	* app/core/gimpbuffer.c
	* app/core/gimpimage.c
	* app/core/gimppalette.c
	* app/core/gimppattern.c
	* app/core/gimptoolinfo.c: implement get_description().

	* app/core/gimpimagefile.[ch]: ditto. Renamed
	gimp_imagefile_get_description() to
	gimp_imagefile_get_desc_string(). Well, um, gimme a better name...

	* app/gui/file-open-dialog.c: changed accordingly.

	* app/file/file-utils.[ch]: renamed readXVThumb() to
	file_utils_readXVThumb().

	* tools/pdbgen/pdb/fileops.pdb: changed accordingly.

	* app/widgets/widgets-types.h: removed GimpItemGetNameFunc typedef.

	* app/widgets/gimpcontainerview-utils.[ch]: removed the the actual
	get_name_funcs. They now live in the core as
	GimpViewable::get_description() implementations.

	* app/widgets/gimpcontainermenu.[ch]
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpcontainermenuimpl.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimpcontainerview.[ch]
	* app/widgets/gimpmenuitem.[ch]
	* app/widgets/gimpviewabledialog.c: removed get_name_func stuff
	and use gimp_viewable_get_description().

	* app/widgets/gimpcontainermenu.[ch]: added "preview_border_width"
	to gimp_container_menu_set_preview_size().

	* app/widgets/gimpimagedock.c: changed accordingly.

	* app/pdb/fileops_cmds.c: regenerated.
2003-04-08 16:01:01 +00:00
Michael Natterer 51785c1d5b app/core/gimpdocumentlist.[ch] added "Gimp" pointers so we don't need to
2003-01-24  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpdocumentlist.[ch]
	* app/core/gimpimagefile.[ch]: added "Gimp" pointers so we don't
	need to use "the_gimp" from "app_procs.h".

	* app/core/core-types.h
	* app/core/gimp.c
	* app/gui/file-open-dialog.c
	* tools/pdbgen/pdb/fileops.pdb: changed accordingly.

	* app/pdb/fileops_cmds.c: regenerated.
2003-01-24 17:38:24 +00:00
Sven Neumann d7e5b9d8d3 added some assertions, cleaned up internals.
2002-04-29  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch]: added some assertions, cleaned up
	internals.

	* app/widgets/gimpdocumentview.c: use the preview size instead of a
	hardcoded thumbnail size. Should we use the prefs value instead?
2002-04-30 01:40:44 +00:00
Sven Neumann 84e768d0a2 accept any size so we don't depend on the values of GimpThumbnailSize. We
2002-04-29  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch]: accept any size so we don't depend on
	the values of GimpThumbnailSize. We might want to allow other thumbnail
	sizes than only 0, 128 or 256.
2002-04-29 19:59:02 +00:00
Sven Neumann 9b6cde9da0 added new enum GimpThumbnailSize.
2002-04-29  Sven Neumann  <sven@gimp.org>

	* app/core/core-enums.[ch]: added new enum GimpThumbnailSize.

	* app/gimprc.c
	* app/config/gimpcoreconfig.[ch]
	* app/core/gimpcoreconfig.[ch]: replaced old gimprc value
	write_thumbnails with thumbnail_size.

	* app/core/gimpimagefile.[ch]: allow to specify a thumbnail size.

	* app/core/gimpdocuments.c
	* app/file/file-open.c
	* app/file/file-save.c
	* app/gui/preferences-dialog.c
	* app/widgets/gimpdocumentview.c: changed accordingly.

	* app/gui/file-open-dialog.c: create the preview according to the
	users choice of thumbnail size. Doesn't update on changes yet.
2002-04-29 19:41:45 +00:00
Sven Neumann 927a100584 save empty thumbnails to ~/.thumbnails/fail/gimp-1.3 if we cannot create a
2002-04-29  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch]: save empty thumbnails to
	~/.thumbnails/fail/gimp-1.3 if we cannot create a thumbnail. Added
	new state GIMP_IMAGEFILE_STATE_THUMBNAIL_EXISTS to indicate that a
	thumbnail was found but is not yet loaded. Removed unused thumb_mtime
	from GimpImagefile struct and simplified some parts of the code.

	* app/gui/file-open-dialog.c: cosmetic changes.
2002-04-29 17:20:26 +00:00
Michael Natterer 63ca433dce added "gchar *name_changed_signal" to GimpViewableClass which defaults to
2002-04-29  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpviewable.[ch]: added "gchar *name_changed_signal"
	to GimpViewableClass which defaults to "name_changed".

	* app/widgets/gimplistitem.c
	* app/widgets/gimpmenuitem.c: connect to
	viewable_class->name_changed_signal instead of just
	"name_changed". Fixed possible UI inconsistency where the previous
	viewable's tooltip would have been displayed.

	* app/core/gimpimagefile.[ch]: set name_changed_signal to
	"info_changed" so views can update their tooltips correctly.
	Merged the separate image_state and thumb_state states into one
	state variable and extended the state enum. Added description
	strings for all states. Show the file size for all files, not only
	for those with a thumbnail. Enabled display of outdated
	thumbnails.

	* app/gui/file-open-dialog.c: some changes because
	gimp_imagefile_get_description() returns 3 instead of 2 lines of
	text now.

	* app/widgets/gimpcontainerview-utils.c: show the imagefile's
	description in the tooltip.

	* app/gui/menus.c
	* app/gui/documents-commands.[ch]
	* app/widgets/gimpdocumentview.c: added functions to remove
	"dangling" document history entries. Updated the context menu so
	all functions can be accessed through it.
2002-04-28 23:10:42 +00:00
Michael Natterer 095314f01d made gimp_imagefile_save_thumbnail() return a gboolean indicating success.
2002-04-19  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimagefile.[ch]: made gimp_imagefile_save_thumbnail()
	return a gboolean indicating success.

	* app/file/file-save.c
	* tools/pdbgen/pdb/fileops.pdb: use gimp_imagefile_save_thumbnail()
	to save thumbnails.

	* app/file/file-utils.[ch]: removed the .xvpics thumbnail saving code.

	* app/pdb/fileops_cmds.c: regenerated.
2002-04-19 17:15:39 +00:00
Michael Natterer b96f184b0b speak in terms of "uri", not "filename". Return the created imagefile.
2002-04-19  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpdocuments.[ch] (gimp_documents_add): speak in terms
	of "uri", not "filename". Return the created imagefile.

	* app/core/gimpimagefile.[ch]: factored out private function
	gimp_imagefile_save_png_thumb() and call it from
	gimp_imagefile_create_thumbnail().
	Added public function gimp_imagefile_save_thumbnail() which takes
	an imagefile and an image.

	* app/file/file-open.c: create thumbnails for all images opened
	interactively using gimp_imagefile_save_thumbnail().

	* app/xcf/xcf-load.c (xcf_load_image): set the filename with
	gimp_image_set_filename() so it gets converted to an URI as for
	external plug-ins.
2002-04-19 12:05:47 +00:00
Michael Natterer 9c400c406e create the thumbnail subdir strings only once in class_init, minor stuff.
2002-04-18  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimagefile.[ch]: create the thumbnail subdir strings
	only once in class_init, minor stuff.

	* app/widgets/gimppreview.c: set widget_class->activate_signal to
	the preview's "clicked" id so we can create mnemonics for it.

	* app/gui/file-open-dialog.c: make the whole preview area clickable,
	block some signals of the "Preview" button so it behaves like
	the tree view headers.
2002-04-18 14:14:50 +00:00
Michael Natterer 31c19e8d1f save the number of layers in the thumbnail and show it in the description.
2002-04-18  Michael Natterer  <mitch@gimp.org>

	* app/core/gimpimagefile.[ch]: save the number of layers in the
	thumbnail and show it in the description.

	* app/gui/file-dialog-utils.[ch]: added file_dialog_new() which
	contains a lot of factored out code from file-open and file-save.

	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c: use file_dialog_new(), reduce use of
	global variables, added utility functions to reduce code
	duplication, cleanup.

	* app/gui/file-open-dialog.c: use a temporary imagefile to create
	previews so the dialog's preview can show the progress when
	creating many thumbnails.

2002-04-18  Michael Natterer  <mitch@gimp.org>

	* POTFILES.in: added app/gui/file-dialog-utils.c
2002-04-18 01:18:24 +00:00
Sven Neumann 48fb6b37ed app/core/gimpimagefile.[ch] moved code to generate a literate description
2002-04-17  Sven Neumann  <sven@gimp.org>

	* app/core/gimpimagefile.[ch]
	* app/gui/file-open-dialog.c: moved code to generate a literate
	description of the image to the GimpImagefile object.
2002-04-16 23:59:53 +00:00
Michael Natterer 4aa4803dd0 register GimpImageType.
2002-04-17  Michael Natterer  <mitch@gimp.org>

	* app/core/core-enums.[ch]: register GimpImageType.

	* app/core/gimpimagefile.[ch]: read and write more image properties
	in thumbnails.

	* app/gui/file-open-dialog.c: changed accordingly.

	* app/widgets/gimpdialogfactory.c: disabled debugging output.

	* app/widgets/gimpdocumentview.c: changed the "Refresh" button to
	regenerate the preview on click and reload all previews on
	shift+click.

	* tools/pdbgen/enums.pl: regenerated.
2002-04-16 23:03:23 +00:00
Michael Natterer 99e575d17d fixed temp_buf_copy() and temp_buf_to_[color|gray]() to (1) not crash and
2002-04-16  Michael Natterer  <mitch@gimp.org>

	* app/base/temp-buf.c: fixed temp_buf_copy() and
	temp_buf_to_[color|gray]() to (1) not crash and (2) to assume the
	correct pixelformat. Bugs were never noticed because the code was
	never used until today...

	* app/core/gimpviewable.c (gimp_viewable_get_new_preview_pixbuf):
	use temp_buf_copy() to convert GRAY* TempBufs to RGB* before
	creating the pixbuf.

	* app/app_procs.c: don't try to open command line images if the
	filename could not be converted to an URI.

	* app/file/file-open.c
	* app/file/file-save.c: use g_file_test() instead of stat().

	* app/file/file-utils.[ch]: cleanup, changed
	file_utils_filename_to_uri() to take a list of procs, not a Gimp
	pointer.

	* app/core/gimpimage.c: changed accordingly.

	* app/core/gimpimagefile.[ch]: implemented thumbnail saving
	following the thumbnail standard v0.5 (the implementation is not
	yet fully standard compliant).

	* app/gui/file-open-dialog.c: use the new thubmnail functions and
	removed all .xvpics code. Not finished yet...

	* app/core/gimpdocuments.c
	* app/widgets/gimpdocumentview.c: changed accordingly.

	* tools/pdbgen/pdb/fileops.pdb (file_save_thumbnail): set "success"
	correctly.

	* app/pdb/fileops_cmds.c: regenerated.
2002-04-16 20:25:27 +00:00
Sven Neumann 4ba6db4e94 Michael Natterer <mitch@gimp.org>
2001-12-03  Sven Neumann  <sven@gimp.org>
	    Michael Natterer <mitch@gimp.org>

	* app/paint-funcs/paint-funcs-mmx.h: removed redefiniton of HAS_ALPHA
	macro.

	* app/core/gimp.c: reverted Daniel's change; it doesn't make the code
	simpler, only more error-prone.

	* app/gui/info-dialog.h
	* app/gui/resize-dialog.h
	* app/core/gimp.h
	* app/core/gimpbrushgenerated.h
	* app/core/gimpbrushpipe.h
	* app/core/gimpchannel.[ch]
	* app/core/gimpcontainer.h
	* app/core/gimpcoreconfig.h
	* app/core/gimpdata.h
	* app/core/gimpdatafactory.[ch]
	* app/core/gimpdrawable-blend.c
	* app/core/gimpdrawable.[ch]
	* app/core/gimpimage.h
	* app/core/gimpimagefile.h
	* app/core/gimplayer.h
	* app/core/gimplayermask.h
	* app/core/gimpmoduleinfo.h
	* app/core/gimppalette.h
	* app/core/gimpundo.h
	* app/widgets/gimpbrushfactoryview.h
	* app/widgets/gimpconstrainedhwrapbox.h
	* app/widgets/gimpcontainermenu.h
	* app/widgets/gimpcontainerview.h
	* app/widgets/gimpdialogfactory.h
	* app/widgets/gimpimagedock.h
	* app/widgets/gimplistitem.h
	* app/widgets/gimpmenuitem.h
	* app/widgets/gimpnavigationpreview.h
	* app/widgets/gimppreview.h
	* app/gimprc.h
	* app/pathP.h
	* app/tools/gimpbezierselecttool.h
	* app/tools/gimpcolorbalancetool.h
	* app/tools/gimpcurvestool.h
	* app/tools/gimpdodgeburntool.c
	* app/tools/gimpfreeselecttool.h
	* app/tools/gimphuesaturationtool.h
	* app/tools/gimpinktool-blob.h
	* app/tools/gimpinktool.h
	* app/tools/gimpiscissorstool.h
	* app/tools/gimpmagnifytool.h
	* app/tools/gimpmeasuretool.h
	* app/tools/gimppainttool.h
	* app/tools/gimppathtool.h
	* app/tools/gimprectselecttool.h
	* app/tools/gimpthresholdtool.h
	* app/tools/gimptool.h
	* app/tools/gimptransformtool.h
	* app/base/base-config.h
	* app/base/gimplut.[ch]
	* app/base/pixel-region.h
	* app/base/pixel-surround.[ch]
	* app/base/temp-buf.[ch]
	* app/base/tile-manager-private.h
	* app/base/tile-manager.[ch]
	* app/base/tile-private.h
	* app/base/tile.[ch]
	* app/display/gimpdisplay.h
	* app/display/gimpdisplayshell-selection.h
	* app/display/gimpdisplayshell.h
	* app/gui/brush-select.h
	* app/gui/gradient-editor.h
	* app/gui/gradient-select.h: reverted most of Daniel's changes.

	There's no reason to use unsigned integers here and in lots of places
	it is even wrong.

	Then it's way too early to convert gbooleans into bitfields. This
	change may make sense in a few places but can happen later when the
	API has settled and the code is more stable.

	* app/gimprc.c: reverted Daniel's change. This is a GCC-ism and this
	code is about to die soon anyway.
2001-12-03 13:44:59 +00:00
Daniel Egger 1ed9180112 Convert ugly comments into named structure fields. Much cleaner and less
2001-12-02  Daniel Egger  <degger@fhm.edu>

	* app/gimprc.c: Convert ugly comments into named structure fields.
	Much cleaner and less errorprone though may cause troubles on
	older compilers and then needs to be reverted. Please report!

	* app/base/base-types.h: Add FIXME reminder.

	* app/base/gimplut.c: Use CLAMP macro instead of if-cascade.

	* app/base/temp-buf.c: Remove duplicated calculations and simplify
	checks.

	* app/base/tile-manager.c:
	- (tile_manager_get_tile_num): Return success and take an additional
	  pointer for the tilenumber.
	- Simplify logic in the rest of the file as a result.
	- Remove rotten debugging cruft.

	* app/core/gimpbrushgenerated.c: Fix two stylistic nits.

	* app/app_procs.c: Include <stdlib.h> for exit () prototype.

	* app/core/gimpdrawable-blend.c: Include <stdlib.h> for abs ()
	prototype.

	* app/display/gimpdisplay.c: Include <string.h> for memcpy ()
	prototype.

	* app/core/gimpimage-convert.c: (HIST_RGB): First parameter is
	not const. Fixes a gcc warning for a wrong return value.

	* libgimpwidgets/gimpunitmenu.c
	* app/core/gimpunit.c: Add suggested (by gcc 3.1 cvs) parentheses
	to group correct logic tests together.

	* app/paint-funcs/paint-funcs-generic.h: Fix my HAS_ALPHA macro
	to avoid gcc 3.1 cvs warning.

	* app/gimprc.h
	* pathP.h
	* base-config.h
	* app/base/boundary.h
	* app/base/gimplut.[ch]
	* app/base/pixel-region.h
	* app/base/pixel-surround.[ch]
	* app/base/temp-buf.[ch]
	* app/base/tile-manager-private.h
	* app/base/tile-manager.c
	* app/base/tile-private.h
	* app/base/tile.[ch]
	* app/core/gimp.h
	* app/core/gimpbrushgenerated.h
	* app/core/gimpbrushpipe.h
	* app/core/gimpchannel.[ch]
	* app/core/gimpcontainer.h
	* app/core/gimpcoreconfig.h
	* app/core/gimpdata.h
	* app/core/gimpdatafactory.[ch]
	* app/core/gimpdrawable-blend.c
	* app/core/gimpdrawable.[ch]
	* app/core/gimpimage.h
	* app/core/gimpimagefile.h
	* app/core/gimplayer.h
	* app/core/gimplayermask.h
	* app/core/gimpmoduleinfo.h
	* app/core/gimppalette.h
	* app/core/gimpundo.h
	* app/display/gimpdisplay.h
	* app/display/gimpdisplayshell-selection.h
	* app/display/gimpdisplayshell.h
	* app/gui/brush-select.h
	* app/gui/gradient-editor.h
	* app/gui/gradient-select.h
	* app/gui/info-dialog.h
	* app/gui/resize-dialog.h
	* app/tools/gimpbezierselecttool.h
	* app/tools/gimpcolorbalancetool.h
	* app/tools/gimpcolorpickertool.h
	* app/tools/gimpcurvestool.h
	* app/tools/gimpdodgeburntool.c
	* app/tools/gimpfreeselecttool.h
	* app/tools/gimpfuzzyselecttool.h
	* app/tools/gimphuesaturationtool.h
	* app/tools/gimpinktool-blob.h
	* app/tools/gimpinktool.h
	* app/tools/gimpiscissorstool.h
	* app/tools/gimpmagnifytool.h
	* app/tools/gimpmeasuretool.h
	* app/tools/gimppainttool.h
	* app/tools/gimppathtool.h
	* app/tools/gimprectselecttool.h
	* app/tools/gimpthresholdtool.h
	* app/tools/gimptool.h
	* app/tools/gimptransformtool.h
	* app/tools/path_toolP.h
	* app/widgets/gimpbrushfactoryview.h
	* app/widgets/gimpconstrainedhwrapbox.h
	* app/widgets/gimpcontainermenu.h
	* app/widgets/gimpcontainerview.h
	* app/widgets/gimpdialogfactory.h
	* app/widgets/gimpimagedock.h
	* app/widgets/gimplistitem.h
	* app/widgets/gimpmenuitem.h
	* app/widgets/gimpnavigationpreview.h
	* app/widgets/gimppreview.h: Unsignify lots of variables and
	parameters and use bitfields in structs where possible. First
	part of a huge cleanup all over the code...
2001-12-02 14:59:30 +00:00
Sven Neumann 757017a8e2 bumped version number to 1.3.1. Require Glib/GTK+-1.3.11 and Pango-0.22.
2001-11-23  Sven Neumann  <sven@gimp.org>

	* configure.in: bumped version number to 1.3.1.
	Require Glib/GTK+-1.3.11 and Pango-0.22. Removed GDK_DISABLE_COMPAT_H
	and GTK_DISABLE_COMPAT_H from our default CFLAGS since they don't
	exist any longer.

	* RELEASE-TO-CVS.patch: removed since the glib/gtk+ API is supposed to
	be frozen now.

	* HACKING: removed reference to RELEASE-TO-CVS.patch

	* app/gui/menus.c
	* app/tools/gimptexttool.c: applied RELEASE-TO-CVS.patch to conform
	to the new GTK+/Pango API.

	* app/core/Makefile.am: generate marshallers with gimp_marshal prefix.

	* app/core/gimpmarshal.list: added all marshallers we use.

	* app/core/gimpmarshal.[ch]: regenerated.

	* app/[lots of .c files]: use gimp_marshal_* for all marshallers.

	* data/images/
	* app/app_procs.c
	* app/gui/splash.c:

	* libgimpbase/Makefile.am
	* libgimpbase/gimpbase.h
	* libgimpbase/gimputils.[ch]: removed since they are no longer needed.

	* app/gimprc.c
	* plug-ins/common/ps.c
	* plug-ins/gdyntext/gdyntext.c
	* plug-ins/gdyntext/gdyntextcompat.c
	* plug-ins/gfig/gfig.c
	* plug-ins/gflare/gflare.c
	* plug-ins/script-fu/script-fu-scripts.c: use glib functions instead
	of gimp_strescape() and gimpstrcompress().

	* cleaned up all header files: use G_BEGIN_DECLS/G_END_DECLS, declared
	all _get_type function as G_GNUC_CONST.

	* tools/pdbgen/enumcode.pl
	* tools/pdbgen/lib.pl: make them generate header files using
	G_BEGIN_DECLS/G_END_DECLS.

	* pixmaps/Makefile.am
	* pixmaps/wilber3.xpm: removed ...
	* data/images/tips_wilber.png: ... and added here as PNG

	* app/gui/tips-dialog.c: load the Wilber on demand using GdkPixbuf.

	* data/images/gimp_splash.ppm: removed ...
	* data/images/gimp_splash.png: ... and added as PNG

	* app/app_procs.c
	* app/gui/splash.[ch]: load the splash image using GdkPixbuf.

	* app/gui/about-dialog.c: sink the GtkPreview.
2001-11-22 23:46:13 +00:00
Michael Natterer 4305c39cf0 app/core/Makefile.am new file implementing the docindex.* replacement.
2001-08-11  Michael Natterer  <mitch@gimp.org>

	* app/core/Makefile.am
	* app/core/gimpdocuments.[ch]: new file implementing the
	docindex.* replacement.

	* app/gimprc.c: added TT_XDOCUMENT to parse the new document
	history.

	* app/file-save.c
	* app/gui/file-open-dialog.c: add opened & saved images to the
	document history.

	* app/core/gimp.c: call gimp_documents_init/exit() instead of
	doing it here.

	* app/core/gimpimagefile.[ch]: removed the "filename" attribute
	and use GimpObject's "name" instead.

	* app/gui/dialogs-constructors.[ch]
	* app/gui/dialogs.c
	* app/gui/menus.c: added a menu entry/dockable for the document
	history.

	* app/widgets/gimpdnd.[ch]: make it DND-able.

	* app/widgets/gimppreview.c: fix  preview rendering correctly this
	itme.
2001-08-11 07:47:35 +00:00
Sven Neumann 52b3387214 app/core/Makefile.am app/core/core-types.h added first draft of a
2001-08-09  Sven Neumann  <sven@gimp.org>

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpimagefile.[ch]: added first draft of a GimpImagefile
	object that will handle image files on disk, in particular their
	thumbnails.
2001-08-09 09:07:17 +00:00