Commit Graph

62 Commits

Author SHA1 Message Date
Michael Natterer af517f93aa changed GimpMenusDeleteFunc to take a PlugInProcDef* instead of a const
2004-04-25  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: changed GimpMenusDeleteFunc to take
	a PlugInProcDef* instead of a const gchar*.

	* app/plug-in/plug-ins.c
	* app/gui/gui-vtable.c
	* app/gui/plug-in-menus.[ch]: changed accordingly.
2004-04-25 08:22:22 +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
Simon Budig d85c8c19f5 removed unused member "standard_context" from the Gimp struct.
2004-02-23  Simon Budig  <simon@gimp.org>

	* app/core/gimp.[ch]: removed unused member "standard_context"
	from the Gimp struct.
2004-02-23 00:19:54 +00:00
Michael Natterer 513f5eac36 added new signal "buffer_changed" and new function
2004-02-19  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: added new signal "buffer_changed" and new
	function gimp_set_global_buffer() which emits it when the global
	buffer changes.

	* app/core/gimp-edit.c (gimp_edit_extract): use it instead
	of fiddling with gimp->global_buffer manually.

	* app/gui/image-menu.c: connect to "buffer_changed" and set the
	"Paste" menu entries sensitive. Fixes bug #134752.

	(image_menu_update): changed accordingly. Also changed a lot of
	buggy SET_SENSITIVE() lines which made menu items which work fine
	on any drawable insensitive when there were no layers (instead
	of no drawable).

	* app/gui/edit-commands.c: added new macro return_if_new_drawable()
	and use it instead of return_if_no_image() so we don't run
	into assertions if there is no active drawable.

	(cut,copy_named_buffer_callback): unfortunately had to introduce
	two new translated messages about not being able to cut/copy when
	there is no active drawable.
2004-02-19 12:49:15 +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 ca45a5c65a added enum GimpPDBCompatMode which can be one of { OFF, ON, WARN }.
2003-12-05  Michael Natterer  <mitch@gimp.org>

	* app/pdb/pdb-types.h: added enum GimpPDBCompatMode which can
	be one of { OFF, ON, WARN }.

	* app/main.c: added --pdb-compat-mode command line option. Renamed
	--enable-stack-trace to --stack-trace-mode. Made default values of
	stack_trace_mode and pdb_compat_mode depend on GIMP_MINOR_VERSION
	(default to compat ON and stack_trace NEVER).

	* app/app_procs.[ch]: pass pdb_compat_mode to gimp_new().

	* app/core/gimp.[ch]: added pdb_compat_mode to the Gimp struct
	and to gimp_new().

	* app/pdb/procedural_db.c: leave the compat table empty for
	GIMP_PDB_COMPAT_OFF.

	* app/plug-in/plug-in-message.c: warn when a deprecated procedure
	is called for GIMP_PDB_COMPAT_WARN.

	* docs/gimp-1.3.1.in: changed accordingly.
2003-12-05 17:08:35 +00:00
Michael Natterer 062c2fd4ea Made 3rd party scripts work again after all that PDB function renaming:
2003-12-05  Michael Natterer  <mitch@gimp.org>

	Made 3rd party scripts work again after all that PDB function
	renaming:

	* app/core/gimp.[ch]: added "GHashTable *procedural_compat_ht" to
	the Gimp struct which maps old procedure names to new ones.
	Call new function procedural_db_init_procs() instead of
	internal_procs_init().

	* app/pdb/procedural_db.[ch]: create and destroy the new compat
	hash table. Added new function procedural_db_init_procs() which
	registers the internal procedures and fills the compat hash table.

	(procedural_db_execute): minor fixes.

	* app/plug-in/plug-in-message.c (plug_in_handle_proc_run): if
	the requested procedure was not found, try the compat table.

	* tools/pdbgen/pdb/procedural_db.pdb: made all PDB query
	procedures compat aware. For compat procedures, return help
	strings which declare the procedure as deprecated and tell
	the new name of the procedure. Cleanup.

	* app/pdb/procedural_db_cmds.c: regenerated.
2003-12-05 13:02:18 +00:00
Sven Neumann 6bffe5ad51 removed the hack that used to call gimp_exit() when the batch command
2003-11-30  Sven Neumann  <sven@gimp.org>

	* app/batch.c: removed the hack that used to call gimp_exit() when
	the batch command matches "(gimp-quit 0)". It shouldn't be needed.

	* tools/pdbgen/pdb/misc.pdb
	* app/core/gimp.[ch]
	* app/gui/gui.c: renamed "kill_it" parameter to "force". We don't
	kill the application any longer; this option is just about whether
	to ask the user for confirmation or not.

	* app/pdb/misc_cmds.c: regenerated.

	* app/app_procs.c: cosmetics.
2003-11-30 16:05:56 +00:00
Sven Neumann 921f00c13d unref the gimp object after dumping the configuration as a test for
2003-11-17  Sven Neumann  <sven@gimp.org>

	* app/main.c: unref the gimp object after dumping the
	configuration as a test for Gimp::finalize.

	* app/base/base.[ch]: keep a reference on the config object.
	Renamed parameter "use_mmx" to "use_cpu_accel".

	* app/core/gimp.[ch]: call base_init() and base_exit() from
	app_procs.c, not from the Gimp object.

	* app/app_procs.[ch]: renamed app_init() to app_run() since here's
	where the main loop is run. Actually quit the main loop in
	app_exit_after_callback() instead of just calling exit().

	* app/errors.[ch]: declared fatal error handlers as G_GNUC_NORETURN.

	* libgimp/gimp.h: fixed usage of G_GNUC_NORETURN.
2003-11-17 00:17:01 +00:00
Sven Neumann a843b2adfd app/app_procs.[ch] app/main.c app/core/gimp.[ch] app/gui/gui.c allow to
2003-11-13  Sven Neumann  <sven@gimp.org>

	* app/app_procs.[ch]
	* app/main.c
	* app/core/gimp.[ch]
	* app/gui/gui.c
	* app/gui/session.[ch]: allow to pass a session name on the
	command-line. This causes a different sessionrc to be used. This
	is a bit hackish but our power users will probably love it.
	Also removed the useless --restore-session command-line option.

	* docs/gimp-1.3.1.in: changed accordingly.

	* app/core/gimpmarshal.list: removed obsolete marshaller.

	* app/config/gimprc.c (gimp_rc_new): improved gtk-doc comment.
2003-11-13 14:14:20 +00:00
Michael Natterer cd218fef29 Made plug-ins honor the current GIMP theme:
2003-11-10  Michael Natterer  <mitch@gimp.org>

	Made plug-ins honor the current GIMP theme:

	* app/core/gimp.[ch]: added GimpGetThemeDirFunc to the GUI vtable.

	* app/gui/gui-vtable.c: implement it here.

	* tools/pdbgen/pdb/gimprc.pdb: added new PDB function
	gimp_get_theme_dir().

	* libgimp/gimpui.c: use the new function and fall back to
	gimp_gtkrc() if it returns NULL.

	* app/pdb/gimprc_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimpgimprc_pdb.[ch]: regenerated.

	* app/gui/themes.c: unrelated cleanup.
2003-11-10 12:36:22 +00:00
Michael Natterer efd9a3e14a added "wm_name", "wm_class", "display_name" and "monitor_number" to the
2003-11-07  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/gimpprotocol.[ch]: added "wm_name", "wm_class",
	"display_name" and "monitor_number" to the GPConfig message.
	Increased protocol version number.

	* libgimp/gimp.[ch] (gimp_config): read them from the GPConfig
	message and remember them.
	Added public accessors for the new config values.

	* libgimp/gimpui.c (gimp_ui_init): pass wm_name and wm_class to
	gtk_init() and export the display/screen to use to the
	environment.

	* app/core/gimp.[ch]: added vtable entries to get the values
	from the GUI.

	* app/gui/gui-vtable.c: implement the vtable entries.

	* app/plug-in/plug-in-run.c: fill in the GPConfig values using
	the new Gimp vtable functions.

	* app/display/gimpdisplayshell-layer-select.c
	* app/display/gimpdisplayshell.c
	* app/gui/about-dialog.c
	* app/gui/channels-commands.c
	* app/gui/color-notebook.c
	* app/gui/convert-dialog.c
	* app/gui/file-dialog-utils.[ch]
	* app/gui/file-new-dialog.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/gradient-editor-commands.c
	* app/gui/gradients-commands.c
	* app/gui/grid-dialog.c
	* app/gui/image-commands.c
	* app/gui/info-dialog.[ch]
	* app/gui/info-window.c
	* app/gui/layers-commands.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/qmask-commands.c
	* app/gui/resize-dialog.c
	* app/gui/splash.c
	* app/gui/stroke-dialog.c
	* app/gui/templates-commands.c
	* app/gui/tips-dialog.c
	* app/gui/vectors-commands.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimplevelstool.c
	* app/widgets/gimpdock.c
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimptexteditor.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimpviewabledialog.[ch]
	* libgimpwidgets/gimpfileselection.c
	* libgimpwidgets/gimpquerybox.c
	* libgimpwidgets/gimpunitmenu.c
	* plug-ins/helpbrowser/dialog.c
	* plug-ins/ifscompose/ifscompose.c: replaced all calls to
	gtk_window_set_wmclass() by gtk_window_set_role() and all
	"const gchar *wmclass_name" parameters by "const gchar *role".
	Cleaned up the window role strings.
2003-11-07 17:29:02 +00:00
Sven Neumann 51113c495c added new command-line option --no-fonts. Might be useful to reduce
2003-11-05  Sven Neumann  <sven@gimp.org>

	* app/main.c: added new command-line option --no-fonts. Might be
	useful to reduce startup time or if there are problems with the
	font configuration.

	* app/app_procs.[ch]
	* app/main.c
	* app/core/gimp.[ch]
	* app/text/gimp-fonts.c: don't load any fonts when gimp is started
	with --no-fonts.

	* docs/gimp-1.3.1.in: documented the new command-line option.
	Updated some outdated information.
2003-11-05 00:33:20 +00:00
Sven Neumann a88e11afb3 app/widgets/gimpdocked.[ch] renamed GimpDockedIface to
2003-10-11  Sven Neumann  <sven@gimp.org>

	* app/widgets/gimpdocked.[ch]
	* app/widgets/widgets-types.h: renamed GimpDockedIface to
	GimpDockedInterface.

	* app/display/gimpnavigationview.c
	* app/widgets/gimpcoloreditor.c
	* app/widgets/gimpcontainereditor.c
	* app/widgets/gimpcontainerview.c
	* app/widgets/gimpeditor.c
	* app/widgets/gimpimageeditor.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimptooloptionseditor.c: changed accordingly.

	* app/config/config-types.h
	* app/config/gimpconfig.[ch]
	* app/config/gimpconfig-deserialize.[ch]
	* app/config/gimpconfig-serialize.[ch]
	* app/config/gimpconfig-utils.[ch]: added a GimpConfig typedef and
	changed the GimpConfig API to take GimpConfig instead of GObject
	pointers.

	* app/config/gimpconfig-dump.c
	* app/config/gimprc.c
	* app/config/test-config.c
	* app/core/gimp-documents.c
	* app/core/gimp-parasites.c
	* app/core/gimp-templates.c
	* app/core/gimp.[ch]
	* app/core/gimpcontainer.c
	* app/core/gimpcontext.c
	* app/core/gimpdocumentlist.c
	* app/core/gimpgrid.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-new.c
	* app/core/gimpimage.c
	* app/core/gimpparasitelist.c
	* app/core/gimptemplate.c
	* app/core/gimptooloptions.c
	* app/core/gimpviewable.c
	* app/gui/grid-dialog.c
	* app/gui/preferences-dialog.c
	* app/gui/stroke-dialog.c
	* app/gui/templates-commands.c
	* app/gui/tool-options-commands.c
	* app/paint/gimppaintcore.c
	* app/pdb/gimprc_cmds.c
	* app/text/gimptext-parasite.c
	* app/text/gimptext.c
	* app/text/gimptextlayer.c
	* app/tools/gimp-tools.c
	* app/tools/gimptexttool.c
	* app/widgets/gimpdevices.c
	* app/widgets/gimptemplateeditor.c
	* app/widgets/gimptemplateview.c
	* tools/pdbgen/pdb/gimprc.pdb: changed accordingly.
2003-10-11 14:30:18 +00:00
Michael Natterer 89d936f3aa Cleaned up the app init and exit stuff even more. Also reduces the number
2003-10-02  Michael Natterer  <mitch@gimp.org>

	Cleaned up the app init and exit stuff even more. Also reduces the
	number of missing symbols for gimp-console. Added init and exit
	debugging output (only for --verbose).

	* app/core/gimpmarshal.list
	* app/core/gimp.[ch]: added new signals "initialize" and
	"restore".  Moved plug_ins_init() to Gimp::restore()'s default
	implementation and plug_ins_exit() to Gimp::exit()'s default
	implementation. Renamed gimp_set_config() to gimp_load_config()
	and load GimpRC here. Moved base_init() and base_exit() to this
	file, too.

	* app/gui/Makefile.am
	* app/gui/gui-vtable.[ch]: new files split out of gui.c. It was
	simply too large.

	* app/gui/gui.[ch]: renamed gui_themes_init() to gui_init(),
	connect to Gimp's "initialize" and "restore" signals and create
	the GUI stuff in the callbacks. Removed most other public
	functions since they don't need to be called explicitly any more.
	Moved the whole tool initialization/shutdown code to this file.

	* app/gui/user-install-dialog.[ch]: changed
	user_install_dialog_create() to user_install_dialog_run() and
	added a gtk_main() at the end, so the install dialog's gtk_main()
	and gtk_main_quit() live in the same file.

	* app/app_procs.c: removed lots of stuff. app_init() is much
	simpler now.
2003-10-02 11:26:26 +00:00
Michael Natterer 268c4fb1ce added lots more "GimpFooFunc gui_foo_func" vtable entries to the Gimp
2003-09-10  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: added lots more "GimpFooFunc gui_foo_func"
	vtable entries to the Gimp struct and wrapper function for them.
	They cover plug-in menu creation and plug-in progress utilities.

	* app/gui/gui.c: fill in the funtion pointers and dispatch
	to the actual functions.

	* app/pdb/Makefile.am (libapppdb_a_LIBADD): removed most hacks
	since the symbols are referenced within libappgui.a now.

	Removed any GTK+ dependency from the plug-ins/ directory:

	* app/plug-in/Makefile.am (INCLUDES): replaces GTK_CFLAGS by
	GDK_PIXBUF_CFLAGS.

	* app/plug-in/plug-in-progress.c
	* app/plug-in/plug-ins.c: replaced gui function calls to create
	menus and progress bars by calls to the wrappers.

	* app/plug-in/plug-in.c (plug_in_close): check dangling PDB
	dialogs using the new wrapper.

	* app/plug-in/plug-in-def.c
	* app/plug-in/plug-in-rc.c
	* app/plug-in/plug-in-run.c: removed trailing whitespace.
2003-09-10 22:06:45 +00:00
Michael Natterer 284b8f91d7 added "gboolean console_messages" to the Gimp struct and to gimp_new()
2003-09-09  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: added "gboolean console_messages" to the
	Gimp struct and to gimp_new() since plug-in messages go directly
	through gimp_message() now and need to honor "console_messages"
	too.

	* app/app_procs.[ch]: added "gboolean console_messages" to
	app_init() and pass it to gimp_new().

	* app/appenv.h: removed global variable "console_messages".

	* app/main.c: added it to main()'s scope and pass it to app_init().

	* app/errors.c: changed accordingly.
2003-09-09 10:54:20 +00:00
Michael Natterer 1f2c75e507 Completed the new help infrastructure. Needs some polishing but basically
2003-08-28  Michael Natterer  <mitch@gimp.org>

	Completed the new help infrastructure. Needs some polishing but
	basically works as proposed:

	* tools/pdbgen/pdb/plug_in.pdb: changed gimp_plugin_help_register()
	to take a "domain_name" (which is the XML namespace) and a
	"domain_uri" (which is the root of the plug-in's help pages).

	* tools/pdbgen/pdb/help.pdb: changed gimp_help() to take help_id
	instead of a non-UTF-8 help_path.

	* app/plug-in/plug-in-def.[ch]
	* app/plug-in/plug-in-proc.[ch]
	* app/plug-in/plug-in-rc.c
	* app/plug-in/plug-ins.[ch]: remember the plug-ins' help_domain
	and help_uri instead of just help_path. Changed all plug-in APIs
	to reflect this change.

	* app/widgets/gimphelp.[ch]: on helpbrowser startup, pass it the
	whole list of help domains. The actual help request is now made
	using the browser's temporary procedure.

	* app/core/gimp.h
	* app/gui/file-open-menu.c
	* app/gui/file-save-menu.c
	* app/gui/plug-in-menus.[ch]
	* app/widgets/gimpitemfactory.c: changed accordingly.

	* app/pdb/help_cmds.c
	* app/pdb/plug_in_cmds.c
	* libgimp/gimphelp_pdb.[ch]
	* libgimp/gimpplugin_pdb.[ch]: regenerated.

	Changed the help broser to load the pages according to the
	new system:

	- moved the browser window stuff to dialog.[ch]
	- moved help domain handling to domain.[ch]
	- added gimp-help.xml parsing to domain.c
	- tons of cleanup

	* plug-ins/helpbrowser/Makefile.am
	* plug-ins/helpbrowser/dialog.[ch]
	* plug-ins/helpbrowser/domain.[ch]: new files.
	* plug-ins/helpbrowser/helpbrowser.c: chopped.
2003-08-28 18:49:11 +00:00
Michael Natterer 5e950b5501 Cleaned up and improved the message system:
2003-06-13  Michael Natterer  <mitch@gimp.org>

	Cleaned up and improved the message system:

	* app/core/gimp.[ch]: added "const gchar *domain" to
	GimpMessageFunc (a NULL domain means the message is from the GIMP
	core, everything else is a plug-in).

	* app/errors.c: pass "domain == NULL" to gimp_message().

	* tools/pdbgen/pdb/message.pdb: derive the message domain from the
	current plug-in's menu_path (evil hack but works reasonably well).

	* app/pdb/message_cmds.c: regenerated.

	* app/widgets/gimpwidgets-utils.[ch] (gimp_message_box): added a
	header showing the message domain and changed the dialog layout to
	follow the HIG more closely.

	* app/gui/error-console-dialog.[ch]: removed.

	* app/widgets/gimperrorconsole.[ch]
	* app/gui/error-console-commands.[ch]
	* app/gui/error-console-menu.[ch]: new files containing a
	re-implementation of the error console dialog.

	* app/gui/Makefile.am
	* app/gui/dialogs-constructors.c
	* app/gui/gui.c
	* app/gui/menus.c
	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h: changed accordingly.

	* app/display/gimpprogress.c: added more spacing and removed the
	separator (more HIG compliant).

	* plug-ins/[most plug-ins].c: Changed lots of messages and
	progress strings:

	- Removed plug-in names from messages since that's automatically
	  covered by "domain" now.
	- Put all filenames in ''.
	- Changed "Loading" to "Opening".
	- Added "..." to all progress messages.
	- Cleaned up all file open/save error messages to look the
	  same and include g_strerror(errno).
	- Removed special casing for progress bars and *always* show them,
	  not only if run_mode != GIMP_RUN_NONINTERACTIVE (we can't expect
	  all plug-ins to do this correctly but need to hack the core to
	  sort out unwanted progress bars).

	Unrelated:

	- Cleaned up indentation, spacing, #includes, coding style and
	  other stuff while I was at all these files.
2003-06-13 14:37:00 +00:00
Michael Natterer 650b70cf69 reduced GIMP_MAX_IMAGE_SIZE to 2^18.
2003-04-04  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/gimplimits.h: reduced GIMP_MAX_IMAGE_SIZE to 2^18.

	* libgimpbase/gimputils.[ch]: added gimp_memsize_to_string()
	utility function (which is definitely broken on 64bit systems).

	* app/core/gimpimage-new.[ch]: removed
	gimp_image_new_get_memsize_string() and gimp_image_new_create_image().
	Renamed gimp_image_new_template_new() to
	gimp_image_new_get_last_template().

	* app/core/gimpimagefile.c
	* app/display/gimpdisplayshell-title.c: changed accordingly.

	* app/core/gimp-templates.c: changed filename from "templates"
	to "templaterc".

	* app/core/gimp.[ch]
	* app/core/gimpimage-duplicate.c: don't include "gimpimage-new.h".

	* app/core/gimptemplate.[ch]: removed
	gimp_template_calc_memsize().  Instead, added the size and a
	boolean indicating that it is valid to the GimpTemplate
	struct. Added GObject::notify() implementation and update the
	values there.

	* app/widgets/gimppropwidgets.c: connect to the unit property
	correctly.

	* app/gui/file-new-dialog.c: changed accordingly. Disconnect
	from the template's "notify" signal while changing all values.
2003-04-04 15:11:30 +00:00
Michael Natterer a018b06a96 Added preliminary support for image templates. Not finished yet. Addresses
2003-04-03  Michael Natterer  <mitch@gimp.org>

	Added preliminary support for image templates. Not finished
	yet. Addresses bug #96059. Now we need a volunteer to create
	a nice collection of default templates...

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimptemplate.[ch]
	* app/core/gimp-templates.[ch]: new files implementing the new
	GimpTemplate object and the list of available image templates.

	* app/core/gimp.[ch]: keep a container of templates around.

	* app/core/gimpimage-new.[ch]: ported to use GimpTemplate. Removed
	struct GimpImageNewValues.

	* app/widgets/gimpcontainermenuimpl.c: changed to show the
	"(none)" item for a NULL selection also, not only for an empty
	container.

	* app/widgets/gimppropwidgets.[ch]: added
	gimp_prop_size_entry_connect() which connects an externally
	created GimpSizeEntry to object properties. Fixed the size entry
	code to actually work.

	* app/gui/image-menu.c
	* app/gui/file-commands.[ch]: added "Save as Template" which
	creates a new template from any image's properties.

	* app/gui/file-new-dialog.c: use prop_widgets and GimpTemplate.
	Offer the available templates in a menu at the top of the dialog.
2003-04-03 17:50:56 +00:00
Michael Natterer 47419bbcec added "gchar *default_font". and its blurb.
2003-03-25  Michael Natterer  <mitch@gimp.org>

	* app/config/gimpcoreconfig.[ch]: added "gchar *default_font".
	* app/config/gimprc-blurbs.h: and its blurb.

	* app/core/gimp.[ch]: keep a GimpFontList around.

	* app/core/gimpcontext.[ch]: added a GimpFont and all needed
	fonctions to let it work like brush, pattern etc.

	* app/core/gimpdatalist.c: cosmetic.
2003-03-25 22:06:03 +00:00
Michael Natterer af330e9659 added lots of members for the complete state of the plug-ins.
2003-02-11  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.h: added lots of members for the complete
	state of the plug-ins.

	* app/plug-in/plug-in-types.h: added PlugInShm typedef.

	* app/plug-in/plug-in-message.c
	* app/plug-in/plug-in-rc.[ch]
	* app/plug-in/plug-in-run.[ch]
	* app/plug-in/plug-in-shm.c
	* app/plug-in/plug-in.[ch]
	* app/plug-in/plug-ins.[ch]: removed all global & static variables
	and pass around more "Gimp" pointers.

	* app/plug-in/plug-in-debug.c: use G_N_ELEMENTS().

	* app/gui/image-menu.c
	* app/gui/plug-in-commands.c
	* app/gui/plug-in-menus.c
	* app/gui/toolbox-menu.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/fileops.pdb
	* tools/pdbgen/pdb/plug_in.pdb: changed accordingly.

	* app/pdb/fileops_cmds.c
	* app/pdb/plug_in_cmds.c: regenerated.
2003-02-11 12:07:31 +00:00
Manish Singh 96e7d31f58 added hooks for running plug-ins under a memory debugger. Also, removed
2003-02-10  Manish Singh  <yosh@gimp.org>

        * app/plug-in/plug-in.[ch]: added hooks for running plug-ins under
        a memory debugger. Also, removed the args array from the PlugIn
        structure, replacing with simply a variable for the path to the
        plug-in (and one for a precalculated basename).

        * app/plug-in/plug-in-debug.[ch]: helper routines for the above

        * app/plug-in/plug-in-message.c
        * app/plug-in/plug-in-proc.c
        * app/plug-in/plug-in-progress.c: reflect new and renamed args members

        * app/plug-in/Makefile.am: added plug-in-debug.[ch]

        * app/core/core-types.h: added forward declaration for GimpPlugInDebug

        * app/core/gimp.[ch]: added structure member for GimpPlugInDebug

        * devel-docs/debug-plug-ins.txt: documented new feature
2003-02-11 01:21:21 +00:00
Michael Natterer 2db2ef6185 removed gimp_main_loop() and gimp_main_loop_quit() because they were a
2003-02-03  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: removed gimp_main_loop() and
	gimp_main_loop_quit() because they were a temp_hack until plug-ins
	have their own main loops. Added gimp_threads_enter() and
	gimp_threads_leave() instead.

	* app/gui/gui.c: ditto: removed the main loop stuff and added
	functions which call GDK_THREADS_ENTER() and GDK_THREADS_LEAVE()
	instead.

	* app/app_procs.c: create the main GMainLoop here and use
	gimp_threads_enter,leave().

	* app/plug-in/plug-in.[ch]: added a ref_count per plug-in so the
	plug-in is not destroyed under our feet while running a recursive
	main loop. Added plug_in_ref(). Changed plug_in_destroy() to
	plug_in_unref(). Don't destroy the plug-in if plug_in_open()
	fails. Call gimp_threads_enter,leave() around g_main_loop_run().
	Changed the way plug_in_push,pop() are used: "current_plug_in" is
	no longer the plug-in which currently uses the wire, but the
	plug-in which currently preforms a PDB call (the former meaning
	was needed when wire callbacks had no plug-in context but needed
	to get the plug-in from the global "current_plug_in" variable).
	Removed all calls to plug_in_push,pop() from this file.

	* app/plug-in/plug-in-message.c (plug_in_handle_proc_run): added
	plug_in_push,pop() around procedural_db_execute(). No need
	to construct an error return value if the procedure was not found
	because procedural_db_execute() already does this.

	Removed all other plug_in_push,pop(). Added more checks to plug-in
	message handlers and kill the plug-in if it misbehaves. Cleanup.

	* app/plug-in/plug-in-progress.c (plug_in_progress_cancel): if the
	plug-in runs synchronously, provide a GIMP_PDB_CANCEL return value
	so we don't see error messages about the "failed" procedure.

	* app/plug-in/plug-in-run.c: removed plug_in_push,pop() stuff.
	Set the new plug_in->starting_ext boolean while starting an
	extension so the extension_ack handler knows that it wasn't called
	from a buggy plug-in. Cleanup.

	* app/plug-in/plug-ins.c: Cleanup.
2003-02-03 13:21:31 +00:00
Michael Natterer b2c3f0187d Cleaned up the exit process:
2002-12-05  Michael Natterer  <mitch@gimp.org>

	Cleaned up the exit process:

	* app/core/gimp.[ch]: added an "exit" signal which carries a
	"gboolean kill_it" parameter and has a boolean return value.
	Added gimp_boolean_handled_accumulator() so the emission of "exit"
	can be stopped by returning TRUE from a callback.  Removed
	gimp_shutdown() from the public API and made it "exit"'s default
	implementation. Addec gimp_exit() to emit the signal.

	* app/core/gimpmarshal.list: added BOOLEAN__BOOLEAN marshaller.

	* app/gui/gui.[ch]: Replaced public functions gui_shutdown() and
	gui_exit() by "exit" callbacks. g_signal_connect_after() the
	latter so the shutdown order is correct.

	* app/app_procs.[ch]: removed app_exit() and connect to "exit".
	Split the exit stuff into normal and connect_after callbacks as
	above.

	* app/batch.c
	* app/gui/file-commands.c
	* tools/pdbgen/pdb/misc.pdb
	* app/widgets/gimptoolbox.c: call gimp_exit() instead of
	app_exit(). Don't #include "app_procs.h".

	* app/pdb/misc_cmds.c: regenerated.
2002-12-05 15:49:59 +00:00
Michael Natterer 319173b14c added "gboolean use_shm" to the Gimp struct and to gimp_new().
2002-12-01  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: added "gboolean use_shm" to the Gimp struct
	and to gimp_new().

	* app/app_procs.c: pass "use_shm" to gimp_new().

	* app/plug-in/plug-in.c (plug_in_init): get "use_shm" from the
	passed "gimp".  Don't include "appenv.h" and "app_procs.h".
2002-12-01 12:16:03 +00:00
Michael Natterer 64eb7d748a added gimp->edit_config which is a copy of gimp->config except for
2002-11-30  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: added gimp->edit_config which is a copy of
	gimp->config except for GIMP_PARAM_RESTRT options. Create it in
	gimp_set_config() which must be called before anything else after
	gimp_new(). Install "notify" handlers between the both to keep
	them up-to-date. Enable auto saving for the edit_config.

	* app/app_procs.c: call gimp_set_config().

	* tools/pdbgen/pdb/gimprc.pdb: use gimp->edit_config here so we
	don't accidentially change GIMP_PARAM_RESTART values from the PDB.

	* app/pdb/gimprc_cmds.c: regenerated.

	* app/gui/preferences-dialog.c: use gimp->edit_config as the base
	for all prefs operations. Disable auto saving while the prefs
	dialog is open. No need any more to parse the saved gimprc to get
	GIMP_PARAM_RESTART values. Removed GIMP_PARAM_RESTART special
	hacks because edit_config handles them transparently for us.

	Unrelated:

	* app/core/gimpimage.c (gimp_image_init): initialize active_vectors.

	* app/gui/gui.c (gui_image_disconect): when the last image
	disappears, show the toolbox only if the image had a display.
2002-11-30 13:08:44 +00:00
Manish Singh 2eef2afbc1 don't say "Now type 'make'" if configure failed.
2002-11-11  Manish Singh  <yosh@gimp.org>

        * autogen.sh: don't say "Now type 'make'" if configure failed.

        * app/core/Makefile.am
        * app/core/core-types.h
        * app/core/gimpenvirontable.[ch]: Implemented GimpEnvironTable,
        keeps an envp array built from system environment and *.env files.

        * app/core/gimp.[ch]: keep a GimpEnvironTable around.

        * app/gimprc.c
        * app/config/gimpcoreconfig.[ch]
        * app/core/gimpcoreconfig.h
        * app/gui/preferences-dialog.c
        * app/gui/user-install-dialog.c: environ-path config stuff

        * themes/Default/images/preferences/Makefile.am
        * themes/Default/images/preferences/folder-environ.png: just copied
        folder.png here, need a better one.

        * app/plug-in/plug-in.c: quick hack to use the envp in the
        GimpEnvironTable. Only on unix now, should really port the
        code to use g_spawn_*.

        * data/misc/user_install
        * etc/gimprc.in: add environ-path stuff

        * data/environ/Makefile: creates system environ directory.

        * data/environ/default.env: sample env file info.

        * data/Makefile.am
        * configure.in: added data/environ dir

        * plug-ins/pygimp/Makefile.am: python module files get put in
        $(gimpplugindir)/python now, install pygimp.env to point to it.

        * plug-ins/pygimp/doc/Makefile.am: minor clean up.
2002-11-12 03:34:11 +00:00
Michael Natterer c7ac6aff52 Moved generic datafile loading to LibGimpBase:
2002-10-23  Michael Natterer  <mitch@gimp.org>

	Moved generic datafile loading to LibGimpBase:

	* app/core/gimpdatafiles.[ch]: removed...

	* libgimpbase/gimpdatafiles.[ch]: ...and add here with a changed
	API which requires no more global variables.

	* libgimpbase/Makefile.am
	* libgimpbase/gimpbase.h
	* libgimpbase/gimpbasetypes.h
	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpdatafactory.c
	* app/gui/gui.c
	* app/plug-in/plug-in.c
	* app/plug-in/plug-ins.c
	* app/tools/tools.c: changed accordingly.

	Moved module loading to LibGimpModule:

	* app/core/gimpmodules.c: removed lots of code...

	* libgimpmodule/gimpmoduledb.[ch]: ...and added it here as
	GimpModuleDB object.

	* libgimpmodule/Makefile.am
	* libgimpmodule/gimpmoduletypes.h: changed accordingly.

	* app/core/gimp.[ch]: replaced gimp->modules by gimp->module_db.

	* libgimpmodule/gimpmodule.[ch]: added
	gimp_module_query(). Internal cleanup. Stuff...

	* app/gui/module-browser.c: changed accordingly. Unfinished...

	* app/core/gimpcontainer.c
	* app/core/gimplist.c: reverted the HACKS introduced recently.

	* app/core/gimpobject.[ch]: added gimp_g_object_get_memsize()
	utility function.

	* libgimpproxy/gimpobject.[ch]: regenerated.

	Changed display filter configuration stuff:

	* libgimpwidgets/gimpcolordisplay.[ch]: made the virtual
	configure() function return a GtkWidget instead of opening a
	dialog. Changed configure_cancel() to configure_reset(). Added
	"changed" signal.

	* app/display/gimpdisplayshell-filter-dialog.c: embed the filters'
	config GUI in the dialog. Connect to "changed" and added a "Reset"
	button which resets the filter.

	* modules/cdisplay_gamma.c
	* modules/cdisplay_highcontrast.c: changed accordingly.

	* modules/colorsel_triangle.c
	* modules/colorsel_water.c: minor fixes.

2002-10-23  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/libgimpbase-docs.sgml
	* libgimpbase/libgimpbase-sections.txt
	* libgimpbase/tmpl/gimpbasetypes.sgml
	* libgimpbase/tmpl/gimpdatafiles.sgml: added GimpDatafiles

	* libgimpmodule/libgimpmodule-docs.sgml
	* libgimpmodule/libgimpmodule-sections.txt
	* libgimpmodule/tmpl/gimpmoduledb.sgml: added GimpModuleDB.

	* libgimpwidgets/libgimpwidgets.types: added gimp_dialog_get_type

	* libgimpmodule/tmpl/gimpmodule.sgml
	* libgimpwidgets/tmpl/gimpcolordisplay.sgml
	* libgimpwidgets/tmpl/gimpdialog.sgml: updated.
2002-10-23 14:55:07 +00:00
Michael Natterer 451d392aac Some PDB cleanup:
2002-09-10  Michael Natterer  <mitch@gimp.org>

	Some PDB cleanup:

	* tools/pdbgen/pdb/procedural_db.pdb: removed the get_data() and
	set_data() implementations and the global "data_list" variable.
	Cleaned up the dump() stuff (pass the FILE pointer around instead
	of having a global variable for it). Fixed output_string() so it
	does not crash on NULL strings.

	* app/core/gimp.[ch]: added gimp->procedural_db_data_list.

	* app/pdb/procedural_db.[ch]: added procedural_db_[set|get]_data().
	Don't leak data identifiers when overwriting an already existing
	entry. Added g_return_if_fail() stuff to all public functions.

	* tools/pdbgen/pdb/channel.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/parasite.pdb: tweaked some helper functions to
	take parameters which make them aware of the real type of the
	objects they handle (e.g. the PDB function gimp_layer_set_name()
	matches the core function gimp_object_get_name()).

	* app/pdb/pdb_glue.h: removed ugly CPP-level workarounds for the
	issue mentioned above.

	* app/pdb/channel_cmds.c
	* app/pdb/drawable_cmds.c
	* app/pdb/layer_cmds.c
	* app/pdb/parasite_cmds.c
	* app/pdb/procedural_db_cmds.c: regenerated.
2002-09-10 20:23:00 +00:00
Sven Neumann 16e8b1bec8 registered GimpFillType enum and added translatable names to
2002-05-13  Sven Neumann  <sven@gimp.org>

	* app/core/core-enums.[ch]: registered GimpFillType enum and added
	translatable names to GimpImageBaseType.

	* app/core/gimp.[ch]
	* app/core/gimpedit.c
	* app/core/gimpimage-new.[ch]: removed gimp_image_new_[init|exit]()
	where we used to create names for the enums mentioned above. Dropped
	gimp_image_new_set_have_current_cut_buffer() in favor of accessing
	the value directly.

	* app/gui/file-new-dialog.c (file_new_dialog_create)
	* app/gui/layers-commands.c (layers_new_layer_query): use
	GimpEnumMenus to choose the base_type and fill_type.
2002-05-13 15:35:27 +00:00
Michael Natterer a3bb0b0dad Started to get rid of the gdisplays_foo() functions in
2002-05-08  Michael Natterer  <mitch@gimp.org>

	Started to get rid of the gdisplays_foo() functions in
	app/display/gimpdisplay-foreach.[ch]. Work in progress...

	* app/core/gimp.[ch]: added the display list to the Gimp object
	(as a GimpList of GimpObjects). This way we get more independent
	from whether there is GUI or not, as gimp->displays will simply
	be an empty list for the --no-interface case.

	* app/display/gimpdisplay.[ch]: Removed the global "display_list"
	and "display_num" variables. Use gimp->displays instead.

	* app/display/gimpdisplay-foreach.[ch]: renamed most functions
	from gdisplays_foo() to gimp_displays_foo() and pass them a Gimp
	pointer.

	* app/core/gimpimage.[ch]: added a "flush" signal.

	* app/display/gimpdisplay-handlers.c: connect to "flush" and call
	gimp_display_flush() in the callback.

	* tools/pdbgen/pdb/display.pdb: use gimp_displays_flush(gimp)
	here and only here.

	* app/pdb/display_cmds.c: regenerated.

	* app/app_procs.c
	* app/gui/gui.c
	* app/gui/preferences-dialog.c:
	s/gdislays_foo()/gimp_displays_foo(gimp)/

	* app/image_map.c
	* app/undo_history.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-dnd.c
	* app/display/gimpdisplayshell-layer-select.c
	* app/display/gimpdisplayshell-scale.c
	* app/gui/channels-commands.c
	* app/gui/colormap-editor-commands.c
	* app/gui/convert-dialog.c
	* app/gui/drawable-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/offset-dialog.c
	* app/gui/qmask-commands.c
	* app/gui/select-commands.c
	* app/gui/vectors-commands.c
	* app/paint/gimpairbrush.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpinktool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimptexttool.c
	* app/tools/gimpthresholdtool.c
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c
	* app/widgets/gimpbufferview.c
	* app/widgets/gimpchannellistview.c
	* app/widgets/gimpcomponentlistitem.c
	* app/widgets/gimpdocumentview.c
	* app/widgets/gimpdrawablelistitem.c
	* app/widgets/gimpdrawablelistview.c
	* app/widgets/gimpimageview.c
	* app/widgets/gimpitemlistitem.c
	* app/widgets/gimpitemlistview.c
	* app/widgets/gimplayerlistitem.c
	* app/widgets/gimplayerlistview.c
	* app/widgets/gimpvectorslistview.c: replaced gdisplays_flush()
	with calls to gimp_image_flush(gimage). Removed inclusion of
	"display/gimpdisplay-foreach.h" from most files.
2002-05-08 17:48:24 +00:00
Michael Natterer ff722d0cff removed unused commented out prototype.
2002-05-08  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.h: removed unused commented out prototype.

	* app/core/gimpimage.c (gimp_image_set_tattoo_state): fixed it
	again after I have b0rked it when using vectors instead of paths.

	* app/display/gimpdisplay.c: some comments and one more
	g_return_val_if_fail().

	* app/widgets/gimpimagedock.c: more fixes for the subtle
	active_image <-> active_display difference.

	* tools/pdbgen/pdb/display.pdb (gimp_display_delete): call
	gimp_display_delete() instead of just destroying it's shell (eek).

	* app/pdb/display_cmds.c: regenerated.

	Added a special view type for the image list so we can implement
	stuff like deleting images which are left over from crashed
	plug-ins:

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpimageview.[ch]: new widget: a view on the image
	container.

	* app/gui/Makefile.am
	* app/gui/images-commands.[ch]: new callbacks for it's context menu.

	* app/gui/dialogs-constructors.c: use the new widget instead of
	plain GimpContainerViews.

	* app/gui/menus.c: added an item_factory for it.
2002-05-08 12:39:01 +00:00
Michael Natterer 6086f832c9 app/core/Makefile.am new object for registering GimpPaintCore subclasses,
2002-02-27  Michael Natterer  <mitch@gimp.org>

	* app/core/Makefile.am
	* app/core/gimppaintinfo.[ch]: new object for registering
	GimpPaintCore subclasses, just like GimpToolInfo for tools.

	* app/core/gimp.h: added gimp->paint_info_list to hold them.

	* app/core/gimptoolinfo.[ch]: removed the "pdb_string" and
	"paint_core_name" pointers and added a GimpPaintInfo pointer
	instead.

	* app/core/gimpimage-mask.c
	* app/gui/vectors-commands.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/tool_manager.c: changed accordingly.

	* app/paint/paint-types.h
	* app/paint/paint.c: added paint class registration stuff like
	the tool_manager does.

	* app/paint/gimpairbrush.[ch]
	* app/paint/gimpclone.[ch]
	* app/paint/gimpconvolve.[ch]
	* app/paint/gimpdodgeburn.[ch]
	* app/paint/gimperaser.[ch]
	* app/paint/gimppaintbrush.[ch]
	* app/paint/gimppencil.[ch]
	* app/paint/gimpsmudge.[ch]: added register functions which are
	called from paint_init().

	The core object system lives not only in "core/", but in
	core, paint, vectors, file, plug-in and xcf, so I had to hack
	a bit to keep the deps working:

	* app/pdb/pdb-types.h: don't include "paint/paint-types.h"...

	* app/core/core-types.h: ...because it's included here. Moved
	the inclusions of the core's subsystems' "foo/foo-types.h"
	files to the end of the file.

	* app/paint/Makefile.am: Some slimy radioactive uglyness.

	* app/gui/drawable-commands.c
	* app/tools/gimpblendtool.c: removed calling core functions via
	the PDB because it makes no sense to do it manually in only a few
	places.  This needs to be done generically using generated
	wrappers living in "app/commands/" or something...
2002-02-27 13:57:49 +00:00
Michael Natterer cdf2a90b03 app/core/Makefile.am app/core/core-types.h new base class for something
2002-02-25  Michael Natterer  <mitch@gimp.org>

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpitem.[ch]: new base class for something which is a
	child of an image, has a PDB ID, a tattoo, parasites and emits
	a "removed" signal.

	* app/core/gimpdrawable.[ch]
	* app/vectors/gimpvectors.[ch]: derive from GimpItem. Removed
	lots of stuff from GimpDrawable.

	* app/core/gimp.[ch]: changed gimp->drawable_table and
	gimp->next_drawable_ID to gimp->item_table and gimp->next_item_id.

	* app/undo.[ch]: s/undo_push_drawable_parasite/undo_push_item_parasite/,
	minor cleanups.

	* app/core/gimplayer.[ch]: changed gimp_layer_new_from_tiles() and
	gimp_layer_new_from_drawable() to take the "dest_gimage" as
	second, not first parameter.

	* app/image_map.c
	* app/core/gimpchannel.c
	* app/core/gimpdrawable-blend.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-histogram.c
	* app/core/gimpdrawable-offset.c
	* app/core/gimpdrawable-preview.c
	* app/core/gimpdrawable-transform.c
	* app/core/gimpedit.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-mask.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-pick-color.c
	* app/core/gimpimage.c
	* app/core/gimplayer-floating-sel.c
	* app/display/gimpdisplayshell-dnd.c
	* app/file/file-save.c
	* app/gui/channels-commands.c
	* app/gui/file-save-dialog.c
	* app/gui/layers-commands.c
	* app/gui/offset-dialog.c
	* app/gui/paths-dialog.c
	* app/gui/toolbox.c
	* app/paint/gimpairbrush.c
	* app/paint/gimpclone.c
	* app/paint/gimpconvolve.c
	* app/paint/gimpdodgeburn.c
	* app/paint/gimperaser.c
	* app/paint/gimppaintbrush.c
	* app/paint/gimppaintcore.c
	* app/paint/gimppencil.c
	* app/paint/gimpsmudge.c
	* app/plug-in/plug-in.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpinktool.c
	* app/tools/gimppainttool.c
	* app/xcf/xcf-load.c
	* app/xcf/xcf-save.c
	* app/widgets/gimpdrawablepreview.c: changed accordingly.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpitemlistview.[ch]: new widget implementing most
	of the stuff formerly done by GimpDrawableListView.

	* app/widgets/gimpchannellistview.c
	* app/widgets/gimpdrawablelistitem.c
	* app/widgets/gimpdrawablelistview.[ch]
	* app/widgets/gimplayerlistview.c: changed accordingly.

	* app/widgets/gimpdnd.[ch]: added a vectors DND type.

	* app/gui/menus.c
	* app/gui/dialogs.c
	* app/gui/dialogs-constructors.[ch]: added a vectors dialog and
	a vectors item_factory.

	* app/gui/Makefile.am
	* app/gui/vectors-commands.[ch]: new files implementing the
	callbacks for the new vectors dialog and item_factory.

	* app/pdb/pdb_glue.h: some more ugly hacks to keep intermediate
	perl code working...

	* tools/pdbgen/pdb.pl: added a vectors type, use GimpItem for all
	ID lookups.

	* tools/pdbgen/pdb/channel.pdb
	* tools/pdbgen/pdb/color.pdb
	* tools/pdbgen/pdb/drawable.pdb
	* tools/pdbgen/pdb/edit.pdb
	* tools/pdbgen/pdb/image.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/misc_tools.pdb
	* tools/pdbgen/pdb/parasite.pdb
	* tools/pdbgen/pdb/selection.pdb
	* tools/pdbgen/pdb/selection_tools.pdb: misc changes according to
	stuff above.

	* app/pdb/channel_cmds.c
	* app/pdb/color_cmds.c
	* app/pdb/drawable_cmds.c
	* app/pdb/edit_cmds.c
	* app/pdb/floating_sel_cmds.c
	* app/pdb/image_cmds.c
	* app/pdb/layer_cmds.c
	* app/pdb/misc_tools_cmds.c
	* app/pdb/paint_tools_cmds.c
	* app/pdb/parasite_cmds.c
	* app/pdb/selection_cmds.c
	* app/pdb/selection_tools_cmds.c
	* app/pdb/text_tool_cmds.c
	* app/pdb/transform_tools_cmds.c: regenerated.
2002-02-25 17:58:50 +00:00
Michael Natterer 9b8bf8de5c made gimp->global_buffer a GimpBuffer, not TileManager.
2001-12-13  Michael Natterer  <mitch@gimp.org>

	* app/core/gimp.[ch]: made gimp->global_buffer a GimpBuffer,
	not TileManager.

	* app/core/gimpbuffer.[ch]: added a "gboolean copy_pixels" to
	gimp_buffer_new().

	* app/core/gimpimage-new.c
	* app/core/gimpedit.[ch]
	* app/core/gimpimage-qmask.c
	* app/widgets/gimpbufferpreview.c
	* app/widgets/gimpbufferview.c
	* app/widgets/gimpcontainerview-utils.c: chaned accordingly, don't
	include "base/tile-manager.h".

	* app/core/gimpdrawable.[ch]: added gimp_drawable_copy().

	* app/core/gimpchannel.[ch]
	* app/core/gimplayer.[ch]
	* app/core/gimplayermask.[ch]: use it in
	gimp_[channel|layer|layer_mask]_copy(), added "GType new_type" as
	paramater to all of them.

	* app/core/gimpimage-duplicate.c
	* app/gui/channels-commands.c
	* app/gui/edit-commands.c
	* app/gui/layers-commands.c
	* app/widgets/gimpchannellistview.c
	* tools/pdbgen/pdb/channel.pdb
	* tools/pdbgen/pdb/layer.pdb
	* tools/pdbgen/pdb/selection.pdb: changed accordingly.

	* app/pdb/channel_cmds.c
	* app/pdb/layer_cmds.c
	* app/pdb/selection_cmds.c: regenerated.

	* app/core/gimplayer.[ch]: removed the "layer_type" parameter from
	gimp_layer_new_from_tiles() because it always needed to be equal
	to gimp_image_base_type_with_alpha() of the passed image.

	* app/core/gimpdrawable-transform.c
	* app/core/gimpedit.c
	* app/core/gimpimage-mask.c: cahanged accordingly.

	* app/core/gimpimage.[ch]: added some new GIMP_IMAGE_TYPE_FOO()
	marcos to get rid of magic values like "pixels = 3" all over the
	place.

	* app/core/gimplayer.[ch]: added gimp_layer_new_from_drawable()
	which creates a layer from an other image's drawable.

	* app/core/gimpimage-convert.[ch]: made the RGB and GRAY converters
	public to use them above, use the new GIMP_IMAGE_TYPE() macros.

	* app/display/gimpdisplayshell-dnd.c
	* app/gui/toolbox.c: removed tile manager stuff and use the new
	functions.

	* app/widgets/gimpdrawablelistview.[ch]: added a
	"convert_drawable_func" which is used to handle drops from other
	images.

	* app/widgets/gimpdrawablelistitem.c
	* app/widgets/gimplayerlistitem.c
	* app/widgets/gimplistitem.[ch]: implemented DND of layers between
	images using gimp_layer_new_from_drawable().

	* app/gui/dialogs-constructors.c: changed accordingly.
2001-12-12 23:48:18 +00:00
Michael Natterer bcd208d9f4 app/Makefile.am removed, chopped...
2001-12-07  Michael Natterer  <mitch@gimp.org>

	* app/Makefile.am
	* app/devices.[ch]: removed, chopped...

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/gui/Makefile.am

	* app/widgets/gimpdeviceinfo.[ch]
	* app/widgets/gimpdevices.[ch]
	* app/gui/device-status-dialog.[ch]
	* app/gui/input-dialog.[ch]: ...and added here.

	Made GimpToolInfo a GimpContext subclass. Create a GimpDeviceManager
	struct in gimpdevices.c and attach it to the Gimp instance.

	* app/core/gimp.[ch]: removed gimp_create_context(). It was a bad
	idea in the first place beause it prevented GimpContext subclasses
	from being be properly registered with their Gimp instance.

	* app/core/gimpcontext.c: moved the stuff which used to be in
	gimp_create_context() back here. Added a "gimp" property which
	must be set on construction. Added a "dispose" implementation
	which removes the context from it's Gimp's context_list.

	* app/gimprc.c
	* app/core/gimptoolinfo.[ch]
	* app/display/gimpdisplayshell-callbacks.c
	* app/gui/brush-select.c
	* app/gui/dialogs-constructors.c
	* app/gui/gradient-editor.c
	* app/gui/gradient-select.c
	* app/gui/gui.c
	* app/gui/menus.c
	* app/gui/palette-editor.c
	* app/gui/palette-select.c
	* app/gui/pattern-select.c
	* app/gui/toolbox.c
	* app/tools/gimppainttool.c
	* app/tools/tool_manager.c
	* app/widgets/gimpimagedock.c: changed accordingly.

	* app/gui/tools-commands.[ch]: made all callback signatures
	the same.

	* app/gui/preferences-dialog.c: cleaned up the
	display_format_string GtkCombo code.
2001-12-07 17:39:51 +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
Michael Natterer f77c7ade89 app/main.c moved "message_handler" from here...
2001-12-01  Michael Natterer  <mitch@gimp.org>

	* app/main.c
	* app/appenv.h: moved "message_handler" from here...

	* app/core/gimp.[ch]: ...to here. Added gimp_message() and a
	"gui_message_func" pointer...

	* app/gui/gui.c: ...which gets set here to gui_message().

	* app/errors.c: don't include any gui stuff but simply call
	gimp_message().

	* app/app_procs.c: don't set "message_handler" here, it's done in
	gui.c now.

	* app/gui/error-console-dialog.[ch]: use gimp->message_handler.

	* app/gui/dialogs-constructors.c: pass a Gimp pointer to
	error_console_create().

	* app/widgets/gimpwidgets-utils.[ch]: made the "message" parameter
	of gimp_message_box() a const gchar*, not just gchar*.

	* tools/pdbgen/pdb/message.pdb: use gimp->message_handler, don't
	include "appenv.h".

	* app/pdb/message_cmds.c: regenerated.

	* app/devices.[ch]: cleanup before chopping: removed global
	variable "current_device", added devices_get_current(), pass lots
	of Gimp pointers around.

	* app/gimprc.c: pass a Gimp pointer to devices_rc_update().

	* app/display/gimpdisplayshell-callbacks.c
	* app/gui/toolbox.c
	* app/tools/gimppainttool.c: use devices_get_current(), pass Gimp
	pointers to all devices_foo() functions.

	* app/core/gimpimage-mask.c: no need to include "pdb/pdb-types.h".
2001-12-01 21:02:34 +00:00
Michael Natterer 77863d8868 app/Makefile.am removed...
2001-11-30  Michael Natterer  <mitch@gimp.org>

	* app/Makefile.am
	* app/plug_in.[ch]: removed...

	* app/plug-in/Makefile.am
	* app/plug-in/plug-in-types.h
	* app/plug-in/plug-in.[ch]: ...and added here.

	* app/appenv.h: removed StackTraceMode and MessageHandlerType...

	* libgimpbase/gimpbasetypes.h: ...and added them here.

	* tools/pdbgen/Makefile.am: don't scan "app/apptypes.h" for enums.

	* tools/pdbgen/enumcode.pl: added a general check to prevent
	enums which are defined in libgimp* from being written to
	"libgimp/gimpenums.c".

	* libgimp/gimpenums.h
	* plug-ins/script-fu/script-fu-constants.c
	* tools/pdbgen/enums.pl: regenerated.

	* app/core/core-types.h: include "pdb/pdb-types.h" so including
	"core/core-types.h" gets the whole core type space.

	* app/core/gimp.[ch]: added a "stack_trace_mode" parameter to the
	constructor and store it in the Gimp struct because the value is
	also passed to plug-ins and nobody should include "appenv.h".

	* app/gimprc.[ch]: pass the alternate_system_gimprc and
	alternate_gimprc filenames from the command line to gimprc_prase()
	so we don't need to include "appenv.h".

	* app/batch.[ch]: pass the "batch_cmds" as parameter, don't
	include "append.h".

	* app/app_procs.c: pass more parameters around.

	* app/devices.c
	* app/errors.c
	* app/gimphelp.c
	* app/main.c
	* app/core/gimpgradient.c
	* app/display/gimpdisplay.c
	* app/display/gimpdisplayshell.c
	* app/file/file-open.c
	* app/file/file-save.c
	* app/file/file-utils.c
	* app/gui/commands.c
	* app/gui/error-console-dialog.c
	* app/gui/file-dialog-utils.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* app/gui/paths-dialog.c
	* app/gui/user-install-dialog.c
	* app/tools/gimpbezierselecttool.c
	* app/tools/xinput_airbrush.c
	* app/xcf/xcf.c
	* tools/pdbgen/pdb/fileops.pdb
	* tools/pdbgen/pdb/help.pdb
	* tools/pdbgen/pdb/message.pdb
	* tools/pdbgen/pdb/plug_in.pdb: changed accordingly:

	- changed "plug-in.h" include where needed.
	- don't call gimp_fatal_error() directly, it's called via the log
	  handler when calling g_error().
	- don't incude "errors.h" except from main.c.
	- changed stack_trace and message_handler enum names.
	- get "stack_trace_mode" from Gimp.
	- removed many inclusions of "appenv.h".

	* app/pdb/fileops_cmds.c
	* app/pdb/help_cmds.c
	* app/pdb/message_cmds.c
	* app/pdb/plug_in_cmds.c
	* app/pdb/procedural_db.c: regenerated.
2001-12-01 00:14:14 +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 14098dc0eb Made --no-interface not calling gtk_init() (and thus not contacting the X
2001-11-17  Michael Natterer  <mitch@gimp.org>

	Made --no-interface not calling gtk_init() (and thus not
	contacting the X server) any more. (Fixes #58961).

	* app/core/gimp.[ch]: added two new function pointers
	"gui_main_loop_func" and "gui_main_loop_quit_func" and an own
	stack of GMainLoops which is used if they are not set.

	* app/gui/gui.[ch]: added main loop functions here and set them as
	pointers in the Gimp instance. Separated gui_libs_init() from
	gui_themes_init() so it can be used as replacement for gtk_init()
	and be called before command line parsing.

	* app/main.c: check for "--no-interface" before initializing
	anything. Added a "--g-fatal-warnings" option (cut'n'paste from
	gtkmain.c). Added a check for "--" (end of options).

	* app/app_procs.c: call the new gimp_main_loop() functions,
	call gui_themes_init().

	* app/devices.[ch]: reduce usage of "the_gimp" by passing "Gimp"
	pointers to some functions.

	* app/plug_in.c: some ugly checks for the_gimp->no_interface which
	will go away once this file is core/ui chopped. Call
	gimp_main_loop() stuff instead of gtk_main().

	* app/core/gimptoolinfo.c: allow passing a NUL GdkPixbuf pointer.
2001-11-17 16:32:34 +00:00
Michael Natterer 51687bba7d Wishlist item #57812:
2001-11-16  Michael Natterer  <mitch@gimp.org>

	Wishlist item #57812:

	* app/core/gimpimage.[ch]: added a progress_callback to
	gimp_image_scale().

	* app/gui/gui.c
	* app/gui/image-commands.c
	* app/gui/resize-dialog.h
	* tools/pdbgen/pdb/image.pdb: changed accordingly.

	* app/core/gimp.[ch]: found that gimp->busy needs to be a counter,
	not a boolean, so nested calls work.

	* app/pdb/image_cmds.c: regenerated.
2001-11-16 17:08:41 +00:00
Michael Natterer 5f63e079b8 Chopped up the display stuff (beware: unfinished)...
2001-10-31  Michael Natterer  <mitch@gimp.org>

	Chopped up the display stuff (beware: unfinished)...

	The plan is that GimpDisplay is the object which collects
	updates from the image, compresses them and waits for the GIMP
	to be idle to actually paint them. It should be a non-GUI object
	which is the model for the actual widget to connect to.

	GimpDisplayShell has all the widgets and handles painting and
	exposing of the result. Nobody should actually be required to
	update ot look at it as it should be a view on the GimpDisplay
	object.

	Much stuff is still in the wrong place and the functions don't
	follow their files' filename namespace any more. More to come...

	* app/display/Makefile.am
	* app/display/gimpdisplay-ops.[ch]: removed. It's functions didn't
	belong together anyway.

	* app/display/gimpdisplay-area.[ch]: new files: the GimpArea
	functions.

	* app/display/gimpdisplay-handlers.[ch]: new files: signal
	handlers for GimpImage signals. Mostly from app/gui.c.

	* app/display/gimpdisplay.[ch]: removed all widgets and other
	GUI stuff. There is still much undecided here...

	* app/display/gimpdisplayshell.[ch]: actually use the object and
	filled it with all the stuff from GimpDisplay.

	* app/display/gimpdisplay-callbacks.[ch]
	* app/display/gimpdisplay-foreach.[ch]
	* app/display/gimpdisplay-render.c
	* app/display/gimpdisplay-scale.[ch]
	* app/display/gimpdisplay-scroll.[ch]
	* app/display/gimpdisplay-selection.c: changed accordingly.

	* app/core/gimp.[ch]: return a GimpObject from
	gimp_create_display() so it can be used as single GUI independent
	point to create displays, require the initial scale as parameter.

	* app/core/gimpcontext.c: changed the ugly EEKWrapper according to
	the GimpDisplay structure changes. Bugfix: set the image to NULL
	in gimp_context_display_destroyed().

	* app/core/gimpedit.c
	* app/core/gimpimage-new.c: changed gimp_create_display() calls
	accordingly.

	* app/core/gimpimage-convert.c: invalidate the layer & image
	previews here, not in the caller.

	* app/core/gimpimage-crop.c: update the whole image after cropping.

	* app/core/gimpimage.[ch]: added gimp_image_find_guide(),
	gimp_image_snap_point() and gimp_image_snap_rectangle(). Added
	"resolution_changed" and "unit_changed" signals and corresp.
	public convenience functions to emit them.

	* app/core/gimplayer.c: emit the image's "alpha_changed" signal
	when adding alpha to the bottom (and only) layer of the image.

	* app/gimpprogress.c
	* app/image_map.c
	* app/nav_window.c
	* app/qmask.c
	* app/undo.c
	* app/user_install.c: changed accordingly.

	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/file-open-dialog.c
	* app/gui/image-commands.c
	* app/gui/info-window.c
	* app/gui/preferences-dialog.c
	* app/gui/toolbox.c
	* app/gui/view-commands.c: ditto.

	* app/gui/gui.[ch]: removed most gimp->images handlers as the
	displays connect to them themselves now. chaged gui_display_new()
	according to the gimp_create_display() changes.
	Added gui_get_screen_resolution().

	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbucketfilltool.c
	* app/tools/gimpbycolorselecttool.c
	* app/tools/gimpclonetool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpdrawtool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimpfreeselecttool.c
	* app/tools/gimpfuzzyselecttool.c
	* app/tools/gimpinktool.c
	* app/tools/gimpiscissorstool.c
	* app/tools/gimpmagnifytool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimppathtool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimpselectiontool.c
	* app/tools/gimptexttool.c
	* app/tools/gimptool.c
	* app/tools/gimptransformtool.c
	* app/tools/xinput_airbrush.c: lots of changes because GimpDisplay
	has become two objects. Lots of gdisp->shell casting uglyness
	added. This is fine because exactly these parts will have to go
	away.

	(GimpDisplay will provide methods for XOR drawing upon the display
	in image coordinates without the need to transform coordinates all
	the time. Also the tools shouldn't see GdkEvents but get more
	useful virtual functions which speak in image coordinates too).

	* app/widgets/gimpcomponentlistitem.c: removed a now useless image
	update.

	* tools/pdbgen/pdb/display.pdb: use gimp_create_display().

	* app/pdb/display_cmds.c: regenerated.
2001-10-31 21:18:57 +00:00
Michael Natterer 05e15eb1cc Cleanup weekend...
2001-10-29  Michael Natterer  <mitch@gimp.org>

	Cleanup weekend...

	* app/app_procs.c: pass "no_interface" to gimp_new().

	* app/core/gimp.[ch]: added "gboolean no_interface" and the
	load_procs and save_procs GSLists.

	* app/core/gimptoolinfo.[ch]: added a "Gimp" pointer to the
	GimpToolInfo object so more functions find their context without
	accessing the global "the_gimp" variable.

	* app/display/display-types.h: removed the GDisplay -> GimpDisplay
	typedef.

	* app/display/gimpdisplay.c: look at gimp->no_interface, don't
	include "appenv.h".

	* app/file/file-open.[ch]
	* app/file/file-save.[ch]: don't use "the_gimp" any more. Instead,
	pass around lots of "Gimp" pointers. Removed the global load_procs
	and save_procs variables here. Use access() to find out whether a
	file is readable/writable, removed the manual voodoo and it's
	Win32 wrappers. Added an optional (can be NULL) "PlunInProcDef"
	parameter to file_save(), removed file_save_with_proc().

	* app/gui/menus.c: Use the unused "gpointer data" parameter of the
	GtkItemFactory callbacks to pass a "Gimp" pointer to all of them.
	This reduces the usage of the global "the_gimp" hack to zero
	in app/gui/... yeah.

	* app/gui/channels-commands.c
	* app/gui/edit-commands.c
	* app/gui/file-commands.c
	* app/gui/image-commands.c
	* app/gui/layers-commands.c
	* app/gui/palettes-commands.c
	* app/gui/select-commands.c
	* app/gui/test-commands.c
	* app/gui/tools-commands.c
	* app/gui/view-commands.c: use the passed "Gimp" pointer.

	* app/gui/color-area.[ch]
	* app/gui/convert-dialog.c
	* app/gui/dialogs-constructors.c
	* app/gui/file-new-dialog.[ch]
	* app/gui/file-open-dialog.[ch]
	* app/gui/file-save-dialog.[ch]
	* app/gui/gui.c
	* app/gui/info-window.[ch]
	* app/gui/module-browser.[ch]
	* app/gui/palette-editor.c
	* app/gui/palette-import-dialog.[ch]
	* app/gui/paths-dialog.c
	* app/gui/preferences-dialog.[ch]
	* app/gui/resize-dialog.[ch]
	* app/gui/tool-options-dialog.[ch]
	* app/gui/toolbox.c: pass around lots more "Gimp" and
	"GimpContext" pointers and don't use "the_gimp" any more.

	* app/tools/gimptool.h: added a pointer to the corresponding
	GimpToolInfo object (which in turn has a pointer to a Gimp).

	* app/tools/tool_manager.[ch]: set the pointer after creating the
	tool object. Removed tool_manager_get_info_by_tool() as there is a
	tool->tool_info pointer now.

	* app/tools/gimpbezierselecttool.c
	* app/tools/gimpblendtool.c
	* app/tools/gimpbrightnesscontrasttool.c
	* app/tools/gimpclonetool.c
	* app/tools/gimpcolorbalancetool.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpconvolvetool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpcurvestool.c
	* app/tools/gimpdodgeburntool.c
	* app/tools/gimpdrawtool.c
	* app/tools/gimpeditselectiontool.c
	* app/tools/gimpellipseselecttool.c
	* app/tools/gimperasertool.c
	* app/tools/gimpfliptool.c
	* app/tools/gimphistogramtool.c
	* app/tools/gimphuesaturationtool.c
	* app/tools/gimpinktool.c
	* app/tools/gimplevelstool.c
	* app/tools/gimpmagnifytool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimpmovetool.c
	* app/tools/gimppainttool.c
	* app/tools/gimppathtool.c
	* app/tools/gimpperspectivetool.c
	* app/tools/gimpposterizetool.c
	* app/tools/gimprectselecttool.c
	* app/tools/gimprotatetool.c
	* app/tools/gimpscaletool.c
	* app/tools/gimpsheartool.c
	* app/tools/gimptexttool.c
	* app/tools/gimpthresholdtool.c
	* app/tools/path_tool.c
	* app/tools/xinput_airbrush.c: s/GDisplay/GimpDisplay/g.
	Use tool->tool_info and tool_info->gimp in some places to get
	rid of using "the_gimp".

	Removing the remaining ones involves changing the tool options
	system and is scheduled next...

	* app/widgets/gimpdnd.c
	* app/widgets/gimpdocumentview.c: pass a "Gimp" pointer to all
	file_open_*() functions.

	* app/gdisplay_color.[ch]
	* app/gdisplay_color_ui.[ch]
	* app/image_map.[ch]
	* app/nav_window.[ch]
	* app/path.c
	* app/path_bezier.c
	* app/path_transform.h
	* app/qmask.[ch]: s/GDisplay/GimpDisplay/g

	* tools/pdbgen/pdb/fileops.pdb: load_procs and save_procs are
	members of the "Gimp" object now.

	* tools/pdbgen/pdb/plug_in.pdb: use gimp->no_interface, don't
	include "appenv.h".

	* app/pdb/fileops_cmds.c
	* app/pdb/plug_in_cmds.c: regenerated.
2001-10-29 11:47:11 +00:00
Michael Natterer 8b5b8df82d generate app/file/Makefile
2001-10-25  Michael Natterer  <mitch@gimp.org>

	* configure.in: generate app/file/Makefile

	* app/Makefile.am
	* app/file-open.[ch]
	* app/file-save.[ch]
	* app/file-utils.[ch]: removed...

	* app/file/Makefile.am
	* app/file/file-open.[ch]
	* app/file/file-save.[ch]
	* app/file/file-utils.[ch]: ...and added here.

	* app/gui/file-commands.c
	* app/gui/file-open-dialog.c
	* app/gui/file-save-dialog.c
	* tools/pdbgen/pdb/fileops.pdb: changed includes accordingly.

	* app/app_procs.[ch]: removed app_exit_finish() and
	app_exit_finish_done() from the public API, call gtk_main() here,
	pass "no_data" to gimp_new() and "restore_session" to
	gui_restore().

	* app/main.c: removed global variable "double_speed", don't
	call gtk_main() in main.c. Added some missing log domains.

	* app/appenv.h: removed "double_speed".

	* app/core/gimp.[ch]: added "gboolean no_data" property which
	must be passed to gimp_new().

	* app/display/gimpdisplay-foreach.[ch]: added gdisplays_set_busy()
	and gdisplays_unset_busy().

	* app/gui/about-dialog.c: don't include "appenv.h", declare
	"double_speed" extern.

	* app/gui/brush-select.[ch]
	* app/gui/gradient-select.[ch]
	* app/gui/palette-select.[ch]
	* app/gui/pattern-select.[ch]: made the list of dialogs and the
	global selection dialogs private. Added functions which get a
	dialog by PDB callback_name. Pass a "Gimp" and the callback_name
	to the constructors. Don't include "app_procs.h" for "the_gimp"
	and "appenv.h" for "no_data" any more. Use the passed "Gimp"
	instead and look at gimp->no_data.

	* app/gui/toolbox.[ch]: pass a "Gimp" to the constructor.

	* app/gui/gui.[ch]: use the new gdisplays_[un]set_busy() functions,
	use the passed "Gimp" all over the place, don't include
	"appenv.h" and "app_procs.h". gui_really_quit_dialog() takes
	a "quit_func" callback now and calls it instead of calling
	app_exit_finish() (which is now private) directly.

	* app/gui/convert-dialog.c
	* app/gui/dialogs-constructors.c
	* app/gui/palette-import-dialog.c
	* tools/pdbgen/pdb/brush_select.pdb
	* tools/pdbgen/pdb/gradient_select.pdb
	* tools/pdbgen/pdb/pattern_select.pdb: changed accordingly.

	* app/pdb/brush_select_cmds.c
	* app/pdb/fileops_cmds.c
	* app/pdb/gradient_select_cmds.c
	* app/pdb/pattern_select_cmds.c: regenerated.

2001-10-25  Michael Natterer  <mitch@gimp.org>

	* POTFILES.in: app/file-*.c -> app/file/file-*.c
2001-10-25 13:30:01 +00:00
Michael Natterer cc83594bf2 link the app in a different order as some init functions are called from
2001-10-19  Michael Natterer  <mitch@gimp.org>

	* app/Makefile.am: link the app in a different order as some init
	functions are called from core/gimp.c instead of app_procs.c now.

	* app/app_procs.[ch]: made app_init_update_status() private and
	pass it as callback to various init functions.

	* app/plug_in.[ch]: plug_in_init() take "gimp" and "status_callback"
	parameters.

	* app/undo.c: use "gimage->gimp" instead of "the_gimp", don't
	include "app_procs.h".

	* app/core/core-types.h: added "GimpInitStatusFunc" typedef.

	* app/core/gimp.[ch]: gimp_initialize() and gimp_restore() now
	take a "status_callback" as parameter. Don't include "app_procs.h".

	* app/core/gimpmodules.c: putting the modules in a strong
	container was a bad idea because it may be impossible to finalize
	a GimpModuleInfo object belonging to a stalled module.

	* app/gui/color-area.c: use G_N_ELEMENTS().

	* app/gui/session.c: don't call app_init_update_status() and don't
	include "app_procs.h" because this happens after the splash is
	hidden.

	* tools/pdbgen/app.pl
	* app/pdb/internal_procs.[ch]: pass a "status_callback" to
	internal_procs_init(), don't include "app_procs.h".

	* plug-ins/Makefile.am: build gfig, gimpressionist and imagemap
	again.

	* plug-ins/MapObject/mapobject_preview.c
	* plug-ins/MapObject/mapobject_ui.c: s/gdk_image_unref/g_object_unref/

	* plug-ins/gfig/gfig.c
	* plug-ins/gimpressionist/brush.c
	* plug-ins/gimpressionist/gimpressionist.c
	* plug-ins/gimpressionist/ppmtool.[ch]
	* plug-ins/gimpressionist/presets.c
	* plug-ins/imagemap/imap_browse.[ch]
	* plug-ins/imagemap/imap_csim.y
	* plug-ins/imagemap/imap_edit_area_info.c
	* plug-ins/imagemap/imap_file.c
	* plug-ins/imagemap/imap_main.c
	* plug-ins/imagemap/imap_menu.c
	* plug-ins/imagemap/imap_polygon.c
	* plug-ins/imagemap/imap_popup.c
	* plug-ins/imagemap/imap_preferences.c
	* plug-ins/imagemap/imap_taglist.c
	* plug-ins/imagemap/imap_tools.c: ported to current GLib/Gtk+.

	* plug-ins/gap/gap_arr_dialog.c
	* plug-ins/gap/gap_decode_xanim.c
	* plug-ins/gap/gap_filter_foreach.c
	* plug-ins/gap/gap_filter_main.c
	* plug-ins/gap/gap_frontends_main.c
	* plug-ins/gap/gap_lib.c
	* plug-ins/gap/gap_main.c
	* plug-ins/gap/gap_mod_layer.c
	* plug-ins/gap/gap_mov_dialog.c
	* plug-ins/gap/gap_navigator_dialog.c
	* plug-ins/gap/resize.c: half-way fixed this one too but I'm not
	willing to fix tons of duplicated and deprecated app/ code...
2001-10-19 16:41:09 +00:00
Michael Natterer be86df2a69 app/Makefile.am removed.
2001-10-18  Michael Natterer  <mitch@gimp.org>

	* app/Makefile.am
	* app/module_db.[ch]: removed.

	* app/core/Makefile.am
	* app/core/core-types.h
	* app/core/gimpmoduleinfo.[ch]
	* app/core/gimpmodules.[ch]: new files containing the module info
	object and the module list handling code.

	* app/gui/Makefile.am
	* app/gui/module-browser.[ch]: new files containing the GUI.

	* app/xcf/xcf.[ch]: pass a "Gimp" pointer to xcf_exit().

	* app/core/gimp.[ch]: handle modules and xcf init/exit here too.

	* app/app_procs.c: don't touch the modules and xcf stuff any more.

	* app/gui/dialogs-constructors.c: changed accordingly.

2001-10-18  Michael Natterer  <mitch@gimp.org>

	* POTFILES.in: module_db.c has moved.
2001-10-18 17:27:36 +00:00