2007-05-24 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpsessioninfo.[ch]: removed more code and cleaned
up the API.
* app/widgets/Makefile.am
* app/widgets/gimpsessioninfodock.[ch]: added the removed code here.
* app/widgets/gimpdialogfactory.c: changed accordingly.
svn path=/trunk/; revision=22604
2006-04-20 Tor Lillqvist <tml@novell.com>
* app/widgets/gimpsessioninfo.c (get_appropriate_monitor): New
helper function. Same functionality as
gdk_screen_get_monitor_at_window(), except that it takes a window
geometry as parameter and not the window itself.
(gimp_session_info_set_geometry): Make sure the window is
completely inside a monitor. (#339099, #324254)
2006-01-14 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpsessioninfo.c (gimp_session_info_restore): always
set the current page of dockbooks, also if it's the first one.
2004-11-04 Sven Neumann <sven@gimp.org>
* app/widgets/gimpsessioninfo.c: be more tolerant and silently
skip entries that the dialog factory doesn't recognize.
* app/widgets/gimpdialogfactory.c: minor cleanup.
2004-09-01 Sven Neumann <sven@gimp.org>
* app/widgets/gimpdialogfactory.[ch]: added a boolean parameter to
gimp_dialog_factory_dialog_new() to let the caller decide whether
the window should be presented or not.
* app/actions/dialogs-commands.c
* app/actions/image-commands.c
* app/actions/templates-commands.c
* app/gui/gui-vtable.c
* app/gui/gui.c
* app/widgets/gimpsessioninfo.c: changed accordingly. Do not let
gimp_dialog_factory_dialog_new() present the dialog if we need to
change it after creation. This avoids annoying resizes, noticeable
especially with the error dialog.
2004-07-08 Sven Neumann <sven@gimp.org>
* app/widgets/gimpsessioninfo.c: only write aux-info for properties
that have been changed from their default values.
* app/widgets/gimphistogrameditor.c: some code cleanup.
2004-07-08 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-deserialize.c
* app/config/gimpconfig-serialize.c: removed redundant casts.
* app/widgets/gimpsessioninfo.[ch]: added convenience functions to
get and set aux-info based on object properties.
* app/widgets/gimphistogrameditor.c: use the new functions to save
a histogram's channel and scale in the sessionrc.
2004-06-01 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpsessioninfo.c (gimp_session_info_restore): added
a horrible hack that sets the paned's position after the first
"size-allocate" after "map". Makes position remembering work for
the toolbox and fixes bug #142697.
* app/widgets/gimpdockable.[ch]: added new function
gimp_dockable_set_tab_style()
* app/actions/dockable-commands.c (dockable_tab_style_cmd_callback)
* app/widgets/gimpsessioninfo.c (gimp_session_info_restore):
use gimp_dockable_set_tab_style().
2004-03-13 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpdialogfactory.[ch]: made enum
GimpDialogVisibilityState and GIMP_DIALOG_VISIBILITY_KEY public.
* app/widgets/gimpsessioninfo.c (gimp_session_info_get_geometry):
only look at GTK_WIDGET_VISIBLE(info->widget) if the dialog's
visibility state is GIMP_DIALOG_VISIBILITY_UNKNOWN and map the
visibility state to info->open otherwise.
Fixes bug #137076.
2003-12-16 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpsessioninfo.c (gimp_session_info_restore): free
GimpSessionInfoAux structs using gimp_session_info_aux_free()
instead of g_free() so we don't leak its members.
2003-11-14 Sven Neumann <sven@gimp.org>
* libgimpbase/gimputils.[ch] (gimp_memsize_to_string): take a
guint64 parameter and handle values beyond a gigabyte.
* app/core/gimptemplate.[ch]: use a guint64 for the initial memory
size and removed the gboolean that used to indicate a gulong
overflow.
* app/widgets/gimptemplateeditor.[ch]: changed accordingly.
* app/gui/file-new-dialog.c: don't set the OK button insensitive
when the initial memory size exceeds GULONG_MAX.
* app/widgets/gimpsessioninfo.c (gimp_session_info_deserialize):
replaced a misleading comment.
2003-11-13 Sven Neumann <sven@gimp.org>
* app/widgets/gimpsessioninfo.c: only save the screen number to
the sessionrc if the screen is not the default screen.
2003-11-13 Sven Neumann <sven@gimp.org>
* app/widgets/gimpsessioninfo.c (gimp_session_info_deserialize):
restore compatibility with older sessionrc format. No need to
break everyone's sessionrc again.
2003-11-13 Michael Natterer <mitch@gimp.org>
Made session management multiscreen aware:
* app/widgets/gimpsessioninfo.[ch]: added "gint screen" member
to struct GimpSessionInfo.
(gimp_session_info_get_geometry): ask the window for its screen.
(gimp_session_info_restore): place the window on the remembered
screen if the screen exists.
(gimp_session_info_save)
(gimp_session_info_deserialize): extended "open-on-exit" property
to include the screen number (e.g. "(open-on-exit 1)" for screen 1).
This change breaks everybody's sessionrc again...
2003-11-08 Michael Natterer <mitch@gimp.org>
To be multihead safe, each new window or menu needs to be
associated with a GdkScreen or it will pop up on the default
screen.
* libgimpwidgets/gimpquerybox.[ch]
* app/display/gimpdisplayshell-layer-select.[ch]
* app/widgets/widgets-types.h
* app/widgets/gimpitemfactory.[ch]
* app/widgets/gimpitemtreeview.[ch]
* app/widgets/gimptemplateview.[ch]
* app/widgets/gimptooldialog.[ch]
* app/widgets/gimpviewabledialog.[ch]
* app/gui/channels-commands.[ch]
* app/gui/color-notebook.[ch]
* app/gui/convert-dialog.[ch]
* app/gui/edit-commands.[ch]
* app/gui/grid-dialog.[ch]
* app/gui/image-commands.[ch]
* app/gui/info-dialog.[ch]
* app/gui/layers-commands.[ch]
* app/gui/offset-dialog.[ch]
* app/gui/resize-dialog.[ch]
* app/gui/stroke-dialog.[ch]
* app/gui/templates-commands.[ch]
* app/gui/vectors-commands.[ch]: added "GtkWidget *parent"
paramaters to all functions which create menus, popups or windows
and pass "parent" to gimp_dialog_new() or one of the various
wrappers around it. As a side effect, this fixes bug #61092.
* app/widgets/gimpdialogfactory.[ch]: added "GdkScreen *screen"
instead of "parent" here since there are no possible parent
windows on startup.
* app/display/gimpdisplayshell-callbacks.c
(gimp_display_shell_origin_button_press): added a quick hack to
send a display to another screen: click the origin button with the
middle mouse button.
* app/display/gimpdisplayshell.c
(gimp_display_shell_screen_changed): don't chain up
undonditionally (don't crash).
* libgimpwidgets/gimpdialog.c (gimp_dialog_new_valist): set the
dialog's screen from a non-GtkWidget parent widget. The rest of
non-window parent widget handling is still unimplemented.
* libgimpwidgets/gimpcolorbutton.c
* app/widgets/gimpcolormapeditor.c
* app/widgets/gimpcolorpanel.c
* app/widgets/gimpcomponenteditor.c
* app/widgets/gimpcontainereditor.c
* app/widgets/gimpcontainergridview.c
* app/widgets/gimpcontainerpopup.c
* app/widgets/gimpcontainertreeview.c
* app/widgets/gimpdatafactoryview.c
* app/widgets/gimpdevicestatus.c
* app/widgets/gimpdockable.c
* app/widgets/gimpdrawabletreeview.c
* app/widgets/gimperrorconsole.c
* app/widgets/gimpgradienteditor.c
* app/widgets/gimphelp.c
* app/widgets/gimppaletteeditor.c
* app/widgets/gimppreview-popup.c
* app/widgets/gimpselectioneditor.c
* app/widgets/gimpsessioninfo.c
* app/widgets/gimptoolbox-color-area.c
* app/widgets/gimptoolbox-indicator-area.c
* app/widgets/gimptoolbox.c
* app/widgets/gimptooloptionseditor.c
* app/widgets/gimpvectorstreeview.c
* app/widgets/gimpwidgets-utils.c
* app/display/gimpdisplayshell-scale.c
* app/display/gimpnavigationview.c
* app/gui/module-browser.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/drawable-commands.c
* app/gui/file-commands.c
* app/gui/file-new-dialog.c
* app/gui/file-save-dialog.c
* app/gui/gradient-editor-commands.c
* app/gui/gui-vtable.c
* app/gui/gui.c
* app/gui/info-window.c
* app/gui/palette-import-dialog.c
* app/gui/palettes-commands.c
* app/gui/qmask-commands.c
* app/gui/select-commands.c
* app/gui/tool-options-commands.c
* app/gui/view-commands.c
* app/tools/gimpcolorpickertool.c
* app/tools/gimpcroptool.c
* app/tools/gimpimagemaptool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimptransformtool.c
* plug-ins/FractalExplorer/FractalExplorer.c
* plug-ins/gfig/gfig.c
* plug-ins/gflare/gflare.c: changed accordingly. Changed all
menu_position funcs to place the menu on the right screen.
2003-10-13 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpdialogfactory.[ch]: renamed
gimp_dialog_factories_idle() and _unidle() to
gimp_dialog_factories_set_busy() and _unset_busy().
Added utility function gimp_dialog_factory_set_widget_data() and
public API gimp_dialog_factory_from_widget() so we don't need to
g_object_[set|get]_data() with magic keys all over the place.
* app/widgets/gimpsessioninfo.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-menu.c
* app/gui/gui-vtable.c: changed accordingly.
* app/widgets/gimpsessioninfo.c: remember active page of all dock
notebooks in sessionrc.
* app/widgets/gimpsessioninfo.h: cleaned up the session info structs.
2003-10-11 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpsessioninfo.[ch]: added utility function
gimp_session_info_aux_new().
* app/widgets/gimpcoloreditor.c
* app/widgets/gimpdataeditor.c
* app/widgets/gimpimagedock.c (get_aux_info): use it.
2003-10-11 Michael Natterer <mitch@gimp.org>
* app/widgets/widgets-types.h
* app/widgets/gimpsessioninfo.[ch]: added new struct
GimpSessionInfoAux which contains "gchar *name" and "gchar *value".
Changed sessionrc "aux-info" format again to be really extendable
this time. Also breaks everybody's sessionrc again.
* app/widgets/gimpimagedock.c
* etc/sessionrc: changed accordingly.
Implemented the stuff suggested in bug #122964. Fixes bug #122964
and bug #52206:
* app/widgets/gimpdataeditor.[ch]: replaced the "Gimp" member by a
"GimpDataFactory" and changed gimp_data_editor_construct()
accordingly. Implement GimpDockedInterface::set_aux_info() and
get_aux_info() and remember the currently edited data across
sessions.
* app/gui/gradient-editor-commands.c
* app/gui/gradient-editor-menu.c
* app/widgets/gimpbrusheditor.c
* app/widgets/gimpgradienteditor.c
* app/widgets/gimppaletteeditor.c: changed accordingly.
* app/widgets/gimpcoloreditor.c: remember the active color
selector across sessions.
2003-10-10 Michael Natterer <mitch@gimp.org>
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimpdocked.[ch]: new files implementing
GimpDockedInterface, a GTypeInterface which must be implemented by
all widgets which want to be packed into a GimpDockable. Has
virtual functions similar to the ones GimpDockable had.
* app/widgets/gimpdockable.[ch]: removed all virtual functions and
all function pointers from the instance struct (also the ones just
added in the commit below). Make sure only widgets implementing
the GimpDockedIface are added and simply call the child's
GimpDocked functions where we used to call our own virtual
functions and function pointers.
* app/widgets/gimpcoloreditor.c
* app/widgets/gimpcontainereditor.c
* app/widgets/gimpcontainergridview.c
* app/widgets/gimpcontainerview.c
* app/widgets/gimpeditor.c
* app/widgets/gimpimageeditor.c
* app/widgets/gimpitemtreeview.c
* app/widgets/gimpsessioninfo.c
* app/widgets/gimptooloptionseditor.c
* app/display/gimpnavigationview.c: implement GimpDockedIface.
* app/gui/dialogs-constructors.c: removed all that get_preview_func(),
set_context_func() etc. cruft since that's done by GimpDockedIface.
It's really a file of constructors now.
* app/gui/dialogs-menu.c: changed accordingly.
* app/widgets/gimpimagedock.c: forgotten in the commit below.
2003-10-10 Michael Natterer <mitch@gimp.org>
Cleaned up session management and changed the format of sessionrc
in a way that allows extensions without changing the format during
the 2.0 cycle:
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimpsessioninfo.[ch]: new files implementing the whole
GimpSessionInfo stuff (parsing, saving, restoring, utility functions).
Save / parse the position of GimpDock's panes (bug #122964).
* app/widgets/gimpdialogfactory.[ch]: removed saving, restoring
and session related utility functions and use the ones from
the new files above.
* app/gui/session.c: removed parsing and use the new stuff.
* app/widgets/gimpdock.[ch]: added new virtual functions
GimpDock::set_aux_info() and GimpDock::get_aux_info():
* app/widgets/gimpimagedock.c: implement them and handle the
"auto_follow_active" and "show_image_menu" properties.
* app/widgets/gimpdockable.[ch]: added the same virtual functions
to the GimpDockable class. Enables forward-compatible per-dockable
session management (bug #122964).
* app/gui/dialogs-commands.c
* app/gui/gui.c: changed accordingly.
* etc/sessionrc: ditto. Look at this file and update your own
sessionrc manually if you don't want to lose it.