diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 03:13:10 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 03:13:10 +0000 |
commit | 3c57dd931145d43f2b0aef96c4d178135956bf91 (patch) | |
tree | 3de698981e9f0cc2c4f9569b19a5f3595e741f6b /devel-docs/ui-framework.txt | |
parent | Initial commit. (diff) | |
download | gimp-3c57dd931145d43f2b0aef96c4d178135956bf91.tar.xz gimp-3c57dd931145d43f2b0aef96c4d178135956bf91.zip |
Adding upstream version 2.10.36.upstream/2.10.36
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'devel-docs/ui-framework.txt')
-rw-r--r-- | devel-docs/ui-framework.txt | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/devel-docs/ui-framework.txt b/devel-docs/ui-framework.txt new file mode 100644 index 0000000..ed97004 --- /dev/null +++ b/devel-docs/ui-framework.txt @@ -0,0 +1,57 @@ + GIMP UI Framework + ================= + +This document describes how the GIMP UI framework functions and is +implemented. Here, "UI framework" refers to the system that saves the +UI layout between GIMP sessions, i.e. how docks, dockable dialogs etc +are setup. + + + Key Classes + ----------- + +GimpDockable - Represents a dockable dialog. +GimpDockbook - A GtkNotebook of GimpDockables +GimpDock - A columns of GimpDockbooks +GimpToolbox - Subclasses GimpDock, contains the toolbox. + Dockables are added at the bottom +GimpMenuDock - Subclasses GimpDock, contains dockables, should + probably be merged with GimpDock. The name + contains "menu" from the time when it hosted the + Image Selection Menu that is now in the + GimpDockWindow +GimpDockColumns - A set of GimpDocks arranged side by side. +GimpDockWindow - A toplevel window containing a GimpDockColumns. +GimpImageWindow - A toplevel window containing images and one + GimpDockColumns to the left and to the right. +GimpDialogFactory - A factory to create and position toplevel windows +GimpSessionInfo - Contains session info for one toplevel +GimpUIConfigurer - Configures the UI when switching between + single-window and multi-window mode + + + GimpDialogFactory + ----------------- + +The GimpDialogFactory can be considered to solve two distinct +problems: + +1. Create widgets from text, in particular from text in sessionrc +2. Session manage toplevel windows so their position is remembered + across GIMP sessions + +One possible design adjustment would be to have GimpWidgetFactory that +takes care of 1), and then have GimpDialogFactory inherit from +GtkWidgetFactory and implementing 2). GimpWidgetFactory could possibly +use GtkBuilder. + + + sessionrc + --------- +When GIMP starts, the sessionrc file is parsed. This step puts +GimpSessionInfo:s into GimpDialogFactories. Later when dialogs are +created, the dialog factory looks up existing session info entries. If +one exists, it uses the session info to set e.g. the position of the +created dialog. If it doesn't exist, it creates a new session info +object for the dialog. When GIMP exists, the current session infos are +then written back to sessionrc. |