![]() |
Lumiera 0.pre.04
»edit your freedom«
|
A topological addressing scheme to designate structural locations within the UI. More...
Go to the source code of this file.
A topological addressing scheme to designate structural locations within the UI.
Contrary to screen pixel coordinates, we aim at a topological description of the UI structure. This foundation allows us
As starting point, we'll pick the notion of an access path within a hierarchical structure
plus a locally defined access path further down to the actual UI element
Since UI-Coordinates are conceived as immutable values, we provide a distinct Builder notation for the purpose of defining and assembling coordinate specifications. This notation also helps to keep such specifications more readable, since each component is "tagged" with its intended position within the tree, and thus the order of definition is irrelevant. Relying on that notation, it is also possible to write sparse or incomplete coordinate specifications, since each component not explicitly given is assumed to be a wildcard (*). E.g.
UICoord::currentWindow()
.path("a/b/c")
.tab(3)
.view("Timeline")
is translated into the following UI-Coordinate specification
UI::currentWindow[*]-*.Timeline.#3/a/b/c
which indicates the currently active main window, disregarding the perspective, just some panel, holding the view "Timeline", selecting the third tab/group within this view and there to descend the path of local sub-components "c" nested within "b" nested within "a"
Definition in file ui-coord.hpp.
#include "lib/error.hpp"#include "lib/symbol.hpp"#include "lib/path-array.hpp"#include "lib/nocopy.hpp"#include "lib/util.hpp"#include <cstring>#include <string>#include <vector>#include <utility>Namespaces | |
| namespace | stage |
| Lumiera GTK UI implementation root. | |
| namespace | stage::interact |
| UI interaction control. | |
Enumerations | |
| enum | { UIC_INLINE_SIZE = 8 } |
| enum | UIPathElm { UIC_WINDOW , UIC_PERSP , UIC_PANEL , UIC_VIEW , UIC_TAB , UIC_PATH } |
Classes | |
| class | UICoord |
| Describe a location within the UI through structural/topological coordinates. More... | |
| class | UICoord::Builder |
Variables | |
| const Symbol | UIC_CURRENT_WINDOW {"currentWindow"} |
| window spec to refer to the current window | |
| const Symbol | UIC_FIRST_WINDOW {"firstWindow"} |
| window spec to refer to the first window of the application | |
| const Symbol | UIC_ELIDED {"."} |
| indicate that a component is elided or irrelevant here | |