Commit Graph

70 Commits

Author SHA1 Message Date
Michael Natterer b505f3a5c0 libgimp: make sure plug-ins follow the core's theme
Add a GFileMonitor on "theme.css" and reload the theme when it
changes, also update "gtk-application-prefer-dark-theme" in the same
callback.
2019-01-04 16:39:39 +01:00
Oleksii Samorukov ac26671eb6 Fix plugin focus issues on osx
GTK/OSX does not automatically assign focus to the new windows (upstream
issue), so activateIgnoringOtherApps is called. However, if it is called
before gtk initialized it may cause number of focus issues.

(cherry picked from commit 3adf4a4861)
2018-10-18 14:07:03 +02:00
Michael Natterer 5f700549e7 Change the license URL from http://www.gnu.org/licenses/ to https:// 2018-07-11 23:29:46 +02:00
Michael Natterer b36205176e app, libgimp*: remove the config option to disable tooltips
Also remove all traces of it from the plug-in protocol and raise the
protocol version to 0x0100 (we now allow features and therefore
version bumps in stable, and the master protocol version should always
be higher). Fix the code that aborts plug-in startup on protocol
version mismatch, we can't use gimp_message() because we have no
protocol.
2018-06-06 19:23:30 +02:00
Ell 97925de8eb libgimpbase, libgimp, app: pass icon theme dir to plug-ins through config
Pass the current icon theme directory to plug-ins through the
config message, and add a gimp_icon_theme_dir() libgimp function
for retrieving it.  Note that we already have a similar
gimp_icon_get_theme_dir() PDB function, which we keep around, since
it can be used to dynamically query for the current icon dir,
unlike the former, and since it returns a dynamically-allocated
string, while the rest of the config-related functions return
statically allocated strings.

Use the new function, instead of gimp_get_icon_theme_dir(), in
gimp_ui_init().  This allows gimp_ui_init() to run without making
any PDB calls.  Consequently, this allows us to start plug-ins that
call gimp_ui_init() without entering the main loop in the main app.
We're going to add a plug-in that displays an interactive dialog
while the main app is blocking waiting for an operation to
complete, and we need to be able to start the plug-in without
entering the main loop, to avoid the possibility of arbitrary code
being executed during the wait.

Bump the protocol version.
2018-05-29 16:04:28 -04:00
Michael Natterer 0dd8459a1f libgimp: deprecate more cruft, everything not needed by cruft plug-ins 2018-05-20 21:06:29 +02:00
Michael Natterer af1bb43f37 Port theme and gtkrc file loading to CSS files using GtkCssProvider 2018-05-20 21:06:28 +02:00
Michael Natterer 21e51d2c0f port gtkrc files to CSS (incompletely and stuff commented out) 2018-05-20 21:06:28 +02:00
Michael Natterer e6c055a131 libgimp: remove GdkRGB and GdkColorMap calls, these APIs are gone 2018-05-20 21:06:26 +02:00
Jehan c0eb7858a5 Bug 795057 - Insensitive text in plug-ins is unreadable with dark themes
Don't fix too early! In some cases, PixbufStyle class is not found and
the fix failed.
2018-04-21 12:10:49 +02:00
Michael Natterer 53fae39aee Bug 795057 - Insensitive text in plug-ins is unreadable with dark themes
Copy the fix from app/gui/themes.c to libgimp/gimpui.c so insensitive
labels look right in plug-ins too.
2018-04-08 22:55:19 +02:00
Michael Natterer 2334cb41a7 Bug 760579 - Plug-in dialogs fail to use UI themes
Something must have changed in GTK+, probably a long time ago, because
this code definitely used to work in the past.

Anyway, change gimp_ui_init() in libgimpui to use gtk_rc_parse()
instead of gtk_rc_add_default_file() which fixes the plug-in's initial
theme, and install a GFileMonitor on themerc which calls
gtk_rc_reparse_all() when themerc changes.
2016-01-16 19:36:13 +01:00
Michael Natterer 71894bd787 libgimpwidgets: rename gimpstock.[ch] to gimpicons.[ch]
because stock is on its way out, so we better start renaming and
deprecating stuff sooner than later.
2015-12-12 20:44:46 +01:00
Michael Natterer 69f87bcc84 libgimpwidgets: be smarter when changing icon themes, and have fallbacks
Add gimp_stock_set_icon_theme() which can be called at any time, also
before gimp_stock_init(), in which case we avoid setting the configured
icon theme twice on startup. Call it from libgimp/gimpui.c and
from app/gui/icon-themes.c so the app and plug-ins use the same
icon theme.
2015-12-12 19:32:11 +01:00
Michael Natterer 8005eea835 Remove the "GIMP" from all "Since: GIMP 2.x" API doc comments
because it confuses gtk-doc and breaks some links. Also change the
"Index of new symbols in GIMP 2.x" sections to be what seems to be the
modern standard (looked at the GLib and GTK+ docs), and update some
other stuff.
2015-05-31 21:18:09 +02:00
Michael Natterer ab801970ca Bug 677776 - filter popup windows get hidden behind main image window
Simone found a better way than setting plug-in windows to UTILITY: simply
call the proper API, [NSApp arrangeInFront: nil].
2012-11-12 23:42:15 +01:00
Michael Natterer 018fc32727 Bug 677776 - filter popup windows get hidden behind main image window
On OSX, set all transient plug-in windows to UTILITY, so they appear
on top of the image window, which is a bad hack. See the comment in
gimp_window_set_transient_for_display().
2012-11-11 21:19:17 +01:00
Michael Natterer 9e5ed1e70a Bug 684003 - When using the main window in secondary monitor...
If gimp_window_set_transient_for() fails (due to platform
restrictions), at least set GTK_WIN_POS_CENTER on the window, so it
gets centered on the monitor where the mouse is. This also removes the
need for OSX specific centering code in GimpDialog (bug 677776).
2012-11-11 21:09:46 +01:00
Michael Natterer 0b56aa0d13 Bug 677776 - filter popup windows get hidden behind main image window
On OSX, call [NSApp activateIgnoringOtherApps] when a plug-in dialog
is shown, so the plug-in process becomes the active app, and the
dialog gets focussed.

In order to avoid doing this in GimpDialog (which is also used in
the core), do it in gimp_ui_init() which all interactive plug-ins
call, and when gimp_temp_proc_run() is called interactively, to
catch repeated activation of an already running plug-in.

Also, set GimpDialog's initial position to GTK_WIN_POS_CENTER,
or they will pop up in the top left corner.

Inspired by patches from Simone Karin Lehmann and Daniel Sabo.
2012-11-07 23:44:35 +01:00
Michael Natterer 0d481702c7 libgimp*: add GIMP_DEPRECATED macros using G_DEPRECATED
and start using them instead of GIMP_DISABLE_DEPRECATED where possible.
2012-05-03 00:54:21 +02:00
Michael Natterer 24ee3370b8 Depend on GTK+ >= 2.24.3, cairo >= 1.20.1, gdk-pixbuf >= 2.22.1
and completely separate configure and sanity checks for gdk-pixbuf
from GTK+, because it's now distributed as a separate package. Remove
all sorts of conditional compiling based on GDK_CHECK_VERSION() and
CAIRO_VERSION.
2011-04-06 19:58:24 +02:00
Michael Natterer 8333dfde7b Add some #if GTK_CHECK_VERSION (2, 24, 0) for creating foreign window
so we don't use deprecated API and make the gtk3 port simpler.
2011-02-16 22:51:02 +01:00
Sven Neumann 71ead96472 libgimp: deprecate gimp_min_colors() and gimp_install_cmap()
Also remove calls to gdk_rgb_set_min_colors() and gdk_rgb_set_install()
from gimp_ui_init(). These are considered obsolete nowadays.
2010-10-19 09:59:59 +02:00
Michael Natterer c78e4c8d63 libgimp: move docs from template files to inline comments
Also split up the "tools" docs into separate files so it matches
the new autogenerated PDB section headers.
2010-07-07 11:48:10 +02:00
Michael Natterer a2c70822d4 Use accessors from GTK+ 2.20 instead of using sealed members directly 2010-04-19 19:21:07 +02:00
Michael Natterer 1aeb315ecf undef GTK_DISABLE_DEPRECATED in many places which undef GSEAL_ENABLE
because the widget flag access macros (e.g. GTK_WIDGET_REALIZED) are
now deprecated in GTK+ master.
2010-03-06 23:14:29 +01:00
Michael Natterer 8cee9c66a7 Build with GSEAL_ENABLE and #undef it where accessors are missing 2009-10-17 18:55:14 +02:00
Michael Natterer 8becbc6568 libgimp/gimpbrushselectbutton.c libgimp/gimpexport.c
2009-03-22  Michael Natterer  <mitch@gimp.org>

	* libgimp/gimpbrushselectbutton.c
	* libgimp/gimpexport.c
	* libgimp/gimpfontselectbutton.c
	* libgimp/gimpgradientselectbutton.c
	* libgimp/gimpimagecombobox.c
	* libgimp/gimpitemcombobox.c
	* libgimp/gimppaletteselectbutton.c
	* libgimp/gimppatternselectbutton.c
	* libgimp/gimpprogressbar.c
	* libgimp/gimpui.c
	* libgimp/gimpzoompreview.c
	* tools/test-clipboard.c: use accessors for various members of
	GTK+ structures that don't exist any longer when GSEAL_ENABLE is
	defined.


svn path=/trunk/; revision=28191
2009-03-22 15:49:13 +00: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 efc8351987 improved the documentation of gimpui_init().
2008-07-17  Sven Neumann  <sven@gimp.org>

	* libgimp/gimpui.c: improved the documentation of gimpui_init().


svn path=/trunk/; revision=26211
2008-07-17 08:58:56 +00:00
Sven Neumann 26d1021e77 Properly pass the focus from the core to plug-in dialogs:
2008-03-27  Sven Neumann  <sven@gimp.org>

	Properly pass the focus from the core to plug-in dialogs:

	* libgimpbase/gimpprotocol.[ch]: added a user_time member to the
	GimpConfig struct. Bumped the protocol version to 0x0012.

	* app/core/gimp-gui.[ch]
	* app/gui/gui-vtable.c: added gimp_get_user_time() to get the
	timestamp of the last user interaction.

	* app/plug-in/gimppluginmanager-call.c
	(gimp_plug_in_manager_call_run): pass the timestamp to in the
	GimpConfig message.

	* libgimp/gimp.[ch]:
	* libgimp/gimp.def: added method to access the timestamp as set
	in the config message.

	* libgimp/gimpui.c (gimp_ui_init): construct a fake startup ID and
	set the DESKTOP_STARTUP_ID environment variable.

svn path=/trunk/; revision=25263
2008-03-27 16:30:29 +00:00
Michael Natterer fb1ec39812 remove check for putenv().
2007-11-06  Michael Natterer  <mitch@gimp.org>

	* configure.in: remove check for putenv().

	* app/composite/gimp-composite-3dnow-test.c
	* app/composite/gimp-composite-altivec-test.c
	* app/composite/gimp-composite-mmx-test.c
	* app/composite/gimp-composite-sse-test.c
	* app/composite/gimp-composite-sse2-test.c
	* app/composite/gimp-composite-vis-test.c
	* libgimp/gimpui.c
	* plug-ins/uri/uri-backend-wget.c
	* tools/gimp-remote-x11.c: use g_setenv() instead of putenv().


svn path=/trunk/; revision=24076
2007-11-06 13:28:19 +00:00
Michael Natterer ec11dbc1a1 remove FOO_DISABLE_DEPRECATED for only glib >= 2.15 and gtk+ >= 2.13, GIMP
2007-09-13  Michael Natterer  <mitch@gimp.org>

	* configure.in: remove FOO_DISABLE_DEPRECATED for only glib >= 2.15
	and gtk+ >= 2.13, GIMP builds fine against the 2.14 and 2.12 APIs
	apart from:

	* app/tools/gimpselectionoptions.c
	* libgimpwidgets/gimphelpui.c: undef GTK_DISABLE_DEPRECATED because
	GtkTooltips is deprecated in gtk+ 2.12.

	* libgimp/gimpui.c
	* plug-ins/common/pat.c: the address of an array is always
	non-NULL, no need to check for that. Fixes new gcc warnings.


svn path=/trunk/; revision=23522
2007-09-13 10:44:07 +00:00
Mukund Sivaraman c2d1214551 Changed "The GIMP" to "GIMP" everywhere, where it's used as a name.
2007-06-06  Mukund Sivaraman  <muks@mukund.org>

        Changed "The GIMP" to "GIMP" everywhere, where it's used as a name.


svn path=/trunk/; revision=22715
2007-06-06 08:44:52 +00:00
Sven Neumann 19f836a49b no need to construct (and leak) command-line arguments when initializing
2007-01-22  Sven Neumann  <sven@gimp.org>

	* libgimp/gimpui.c (gimp_ui_init): no need to construct (and 
leak)
	command-line arguments when initializing GTK+.


svn path=/trunk/; revision=21757
2007-01-22 20:56:13 +00:00
Tor Lillqvist eac61e1e12 libgimp/gimpui.c (gimp_window_set_transient_for) These functions are used
2006-10-16  Tor Lillqvist  <tml@novell.com>

	* libgimp/gimpui.c (gimp_window_set_transient_for)
	* app/widgets/gimpwidgets-utils.c (gimp_window_set_transient_for):
	These functions are used for cross-process transient-for, which
	causes hangs on Win32. Bypass on Win32 for now. (#359538)
2006-10-16 11:55:50 +00:00
Sven Neumann f2df31a50e converted tabs to spaces.
2006-04-12  Sven Neumann  <sven@gimp.org>

	* libgimp*/gimp*.[ch]: converted tabs to spaces.
2006-04-12 10:53:28 +00:00
Michael Natterer b10adabb5e Added parent window API to the GimpProgress interface and to the libgimp
2005-09-09  Michael Natterer  <mitch@gimp.org>

	Added parent window API to the GimpProgress interface and to
	the libgimp progress stuff. Might look strange, but does
	the right thing in almost all cases (image window, file dialog,
	script-fu dialog etc). Fixes bug #62988.

	* app/core/gimpprogress.[ch]: added GimpProgress::get_window()
	which should return a toplevel window ID if the progress is in a
	window that wants to be the transient parent of plug-in dialogs.

	* app/widgets/gimpwidgets-utils.[ch] (gimp_window_get_native): new
	function which returns the window handle of a GtkWindow's GdkWindow.

	* app/widgets/gimpfiledialog.c: implement ::get_window().

	* app/display/gimpdisplay.[ch]: ditto. Removed window handle API.

	* app/gui/gui-vtable.c: changed accordingly.

	* libgimpbase/gimpbaseenums.[ch] (enum GimpProgressCommand):
	added GIMP_PROGRESS_COMMAND_GET_WINDOW.

	* app/plug-in/plug-in-progress.[ch] (plug_in_progress_get_window):
	new function. Also renamed some functions to match the
	GimpProgress interface, and not the legacy PDB procedure names.

	* tools/pdbgen/pdb/progress.pdb
	* app/core/gimppdbprogress.c: implement get_window() on both
	sides of the wire, keeping backward compatibility (hopefully).

	* libgimp/gimpprogress.[ch]: deprecated gimp_progress_install()
	and added gimp_progress_install_vtable() which takes a vtable with
	padding to be extensible. Added get_window() vtable entry and
	dispatch it accordingly. Also added pulse() which was implemented
	in a hackish way before. Everything is of course backward
	compatible.

	* libgimp/gimpprogressbar.c: inmplement the get_window() stuff
	so a plug-in dialog containing a progress can be the transient
	parent of another dialog in another plug-in.

	* libgimp/gimpui.[ch] (gimp_ui_get_progress_window): new function
	which returns a foreign GdkWindow of this plug-ins progress
	window.

	Renamed gimp_window_set_transient_for_default_display() to
	gimp_window_set_transient() and make it use the progress' window
	handle instead of the display's (which is the right thing to do in
	almost all cases).

	* libgimp/gimp.def
	* libgimp/gimpui.def: add the new functions.

	* tools/pdbgen/enums.pl
	* app/pdb/internal_procs.c
	* app/pdb/progress_cmds.c
	* libgimp/gimpprogress_pdb.[ch]: regenerated.

	* libgimp/gimpexport.c
	* plug-ins/*/*.c: follow API change.
2005-09-09 18:07:31 +00:00
Sven Neumann ec56ef9d01 Address bug #307971:
2005-09-05  Sven Neumann  <sven@gimp.org>

	Address bug #307971:

	* app/core/gimp-gui.[ch]
	* app/display/gimpdisplay.[ch]
	* app/gui/gui-vtable.c
	* tools/pdbgen/pdb/display.pdb: added PDB function to obtain a
	window handle on an image display.

	* app/pdb/display_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimpdisplay_pdb.[ch]: regenerated.

	* libgimp/gimpui.[ch]: added functions to set a GtkWindow transient
	to an image display.

	* plug-ins/common/gauss.c: use the new function exemplarily.

	* libgimp/gimp.def
	* libgimp/gimpui.def: updated.
2005-09-05 20:47:12 +00:00
Sven Neumann 9c376b389f cosmetics.
2005-04-20  Sven Neumann  <sven@gimp.org>

	* libgimp/gimpui.c (gimp_ensure_modules): cosmetics.
2005-04-20 09:33:16 +00:00
Sven Neumann 62b5c77c76 app/config/gimpguiconfig.[ch] added gimprc option "show-help-button".
2004-10-04  Sven Neumann  <sven@gimp.org>

        * app/config/gimpguiconfig.[ch]
        * app/config/gimprc-blurbs.h: added gimprc option "show-help-button".

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

        * app/dialogs/file-save-dialog.c
        * app/dialogs/image-new-dialog.c
        * app/dialogs/quit-dialog.c
        * app/display/gimpdisplayshell-close.c
        * app/widgets/gimphelp-ids.h: don't set help-ids on confirmation
        dialogs.

        * libgimpbase/gimpprotocol.[ch]
        * libgimp/gimp.[ch]: added boolean "show_help_button" to the
        config message.

        * app/plug-in/plug-in-run.c: pass the new preference to the plug-in.

        * libgimpwidgets/gimpdialog.[ch]: added new function that allows to
        set whether new dialogs should get a help button added.

        * app/gui/gui.c
        * libgimp/gimpui.c: call gimp_dialogs_show_help_button() according
        to the gimprc settings.
2004-10-04 16:21:52 +00:00
Michael Natterer 35b372ea08 tools/pdbgen/Makefile.am tools/pdbgen/groups.pl removed the "Palette" pdb
2004-09-22  Michael Natterer  <mitch@gimp.org>

	* tools/pdbgen/Makefile.am
	* tools/pdbgen/groups.pl
	* tools/pdbgen/pdb/palette.pdb: removed the "Palette" pdb group...

	* tools/pdbgen/pdb/context.pdb: and added its functions to the
	"Context" namespace instead.

	* app/pdb/Makefile.am
	* app/pdb/palette_cmds.c: removed.

	* app/pdb/procedural_db.c: added them to the pdb_compat hash table.

	* libgimp/Makefile.am
	* libgimp/gimppalette_pdb.[ch]: removed.

	* libgimp/gimppalette.[ch]: new files holding compat functions
	which call gimp_context_*() functions.

	* libgimp/gimp.h
	* libgimp/gimpui.c: changed accordingly.

	* app/pdb/context_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimp_pdb.h
	* libgimp/gimpcontext_pdb.[ch]: regenerated.

	* plug-ins/MapObject/mapobject_image.c
	* plug-ins/MapObject/mapobject_preview.c
	* plug-ins/common/apply_lens.c
	* plug-ins/common/blinds.c
	* plug-ins/common/borderaverage.c
	* plug-ins/common/checkerboard.c
	* plug-ins/common/colortoalpha.c
	* plug-ins/common/cubism.c
	* plug-ins/common/exchange.c
	* plug-ins/common/film.c
	* plug-ins/common/gif.c
	* plug-ins/common/grid.c
	* plug-ins/common/mapcolor.c
	* plug-ins/common/mblur.c
	* plug-ins/common/mng.c
	* plug-ins/common/mosaic.c
	* plug-ins/common/papertile.c
	* plug-ins/common/png.c
	* plug-ins/common/polar.c
	* plug-ins/common/semiflatten.c
	* plug-ins/common/sinus.c
	* plug-ins/common/sparkle.c
	* plug-ins/common/vpropagate.c
	* plug-ins/common/warp.c
	* plug-ins/common/whirlpinch.c
	* plug-ins/gfig/gfig-style.c
	* plug-ins/gfli/gfli.c
	* plug-ins/ifscompose/ifscompose.c
	* plug-ins/maze/handy.c
	* plug-ins/pagecurl/pagecurl.c
	* plug-ins/pygimp/gimpmodule.c
	* plug-ins/script-fu/scripts/*.scm: changed accordingly.
2004-09-22 18:43:09 +00:00
Sven Neumann 3fb6adbcfb changed wm_name to app_name in the GimpConfig struct; increased
2004-02-17  Sven Neumann  <sven@gimp.org>

	* libgimpbase/gimpprotocol.[ch]: changed wm_name to app_name in
	the GimpConfig struct; increased GIMP_PROTOCOL_VERSION.

	* app/plug-in/plug-in-run.c (plug_in_run): pass the return value
	of g_get_application_name() to the plug-ins.

	* libgimp/gimp.[ch]: removed function gimp_wm_name(). Set the
	plug-in's application name if an app_name is passed in the config
	message.

	* libgimp/gimpui.c: removed usage of gimp_wm_name(); it was wrong
	to do it this way and caused all plug-ins claim to be the gimp-1.3
	executable in their error messages.

	* libgimp/gimp.def: removed symbol gimp_wm_name.

	* configure.in: reset gimp_binary_age and gimp_interface_age.

	* app/core/gimpimage.c (gimp_image_name_changed): removed unused
	variable.
2004-02-17 14:03:07 +00:00
Michael Natterer ebcb621c51 changed "prog_name" parameter of gimp_help() to "help_domain". It's
2004-01-20  Michael Natterer  <mitch@gimp.org>

	* tools/pdbgen/pdb/help.pdb: changed "prog_name" parameter of
	gimp_help() to "help_domain". It's useless to pass the plug-in's
	executable name to the core because the core already knows it.
	Instead, enabled accessing arbitrary help domains via the
	PDB. Passing NULL as help_domain will use the domain the plug-in
	registered, or the GIMP main help domain if it didn't register a
	domain.

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

	* libgimp/gimpui.c (gimp_ui_help_func): pass NULL as help_domain.
2004-01-20 12:38:31 +00:00
Michael Natterer 5221d4daa6 libgimpbase/Makefile.am libgimpbase/gimpbase-private.[ch] new files
2003-11-15  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/Makefile.am
	* libgimpbase/gimpbase-private.[ch]
	* libgimpbase/gimpunit.c: new files implementing GimpUnitVTable
	(formerly known as GimpWidgetsVTable). Now the unit functions
	finally live in the same library as their header declarations.

	* libgimpbase/gimpunit.h: removed comment about being a header for
	two different files.

	* libgimpwidgets/gimpwidgets-private.[ch]: removed
	GimpWidgetsVTable.

	* libgimpwidgets/gimpsizeentry.c
	* libgimpwidgets/gimpunitmenu.c
	* libgimpwidgets/gimpwidgets.c: use normal gimp_unit functions
	again.

	* libgimp/gimpui.c
	* app/gui/gui.c: removed GimpWidgetVTable stuff.

	* libgimp/Makefile.am
	* libgimp/gimpunitcache.[ch]: new files.

	* libgimp/gimpunit.c: removed (moved to gimpunitcache.c).

	* libgimp/gimp.c (gimp_main): initialize GimpUnitVTable using the
	gimp_unit_cache functions.

	* app/Makefile.am
	* app/units.[ch]: new files implementing GimpUnitVTable.

	* app/libgimp_glue.[ch]: removed.

	* app/app_procs.[ch]: made "the_gimp" a static variable. Call
	units_init().

	* app/main.c: changed accordingly.
2003-11-15 22:53:28 +00:00
Sven Neumann 50e8667b63 reverted Yosh's change and removed the call to gtk_preview_set_gamma()
2003-11-15  Sven Neumann  <sven@gimp.org>

	* libgimp/gimpui.c (gimp_ui_init): reverted Yosh's change and
	removed the call to gtk_preview_set_gamma() instead. The gamma
	value isn't used anywhere else so it would only be confusing to
	use it on plug-in previews.
2003-11-15 20:37:08 +00:00
Manish Singh 2f9e4c17ce and #undef GTK_DISABLE_DEPRECATED, for gtk_preview_set_gamma declaration.
2003-11-15  Manish Singh  <yosh@gimp.org>

        * libgimp/gimpui.c: and #undef GTK_DISABLE_DEPRECATED, for
        gtk_preview_set_gamma declaration.
2003-11-15 20:10:15 +00:00
Michael Natterer 8706affa1d Use the correct GTK+ APIs for setting and changing the theme:
2003-11-12  Michael Natterer  <mitch@gimp.org>

	Use the correct GTK+ APIs for setting and changing the theme:

	* app/gui/themes.c (themes_apply_theme): don't call gtk_rc_parse()
	but write a new config file "~/.gimp-1.3/themerc" which includes
	both the theme's and the user's gtkrc files.

	(themes_init): use gtk_rc_add_default_file() to make themerc known
	to GTK+.

	(themes_theme_change_notify): don't fiddle with toplevel windows
	manually but simply call gtk_rc_reparse_all() after writing the
	new themerc.

	* libgimp/gimpui.c (gimp_ui_init): use gtk_rc_add_default_file()
	instead of gtk_rc_parse().

	* app/gui/preferences-dialog.c: cleaned up / beautified the theme
	selector. Added a "Reload Current Theme" button. Simplified
	GtkTreeView column inserting all over the place.

	(prefs_response): destroy the preferences dialog later so we don't
	crash when cancelling a theme change on "Cancel" (workaround for
	bug #126808).

	* app/gui/module-browser.c (module_browser_new): column inserting
	simplification.
2003-11-12 12:56:31 +00:00
Michael Natterer e34358d8c3 added new API gimp_color_button_[get|set]_update() which configures the
2003-11-11  Michael Natterer  <mitch@gimp.org>

	* libgimpwidgets/gimpcolorbutton.[ch]: added new API
	gimp_color_button_[get|set]_update() which configures the button
	to emit "color_changed" continuously while the color in the color
	selection dialog is being changed. Fixes bug #90091.

	Renamed GimpColorButton struct member
	"GtkItemFactory *item_factory" to a /*< private >*/ member named
	"gpointer popup_menu". This is ugly but fixes bug #125115,

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.c
	* app/widgets/gimpcolorpanel.c: changed accordingly.

	* libgimpwidgets/gimpcolorbutton.c: use a GimpColorSelection
	with a handmade GimpDialog instead of GtkColorSelectionDialog.

	Enabled module loading for plug-ins so the color selection
	can show the color selectors which are implemented in modules:

	* libgimpwidgets/gimpwidgets-private.[ch]: added
	GimpEnsureModlesFunc which can be called by modules users.

	* app/gui/gui.c (gui_libs_init): pass NULL as
	GimpEnsureModulesFunc since the core loads the modules itself.

	* libgimp/gimpui.c (gimp_ui_init): pass new private function
	gimp_ensure_modules() which will load the modules upon first
	invocation.

	* libgimp/Makefile.am: link libgimpui against libgimpmodule.

	* libgimpwidgets/gimpcolorselection.c: call
	_gimp_ensure_modules_func() if it is non-NULL so color selector
	modules are available for plug-ins.

	* tools/pdbgen/pdb/gimprc.pdb: added new PDB wrapper
	gimp_get_module_load_inhibit().

	* app/pdb/gimprc_cmds.c
	* app/pdb/internal_procs.c
	* libgimp/gimpgimprc_pdb.[ch]: regenerated.
2003-11-11 17:55:45 +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