Module window_frame
Expand description
A window standing on a desktop, as a described component: what a shell draws for a place on a
floating desk (shell.md §4, frame_classic) and for a strip of places (strips_view),
which is the same thing.
Its ground is the window level of the design language (SurfaceLevel::Window): the app’s
content colour, the window edge and its soft shadow at the theme’s window radius, with what it
holds clipped to that shape; the window in front stands higher than those behind it, as a
desktop shows which window has the keyboard.
A window has one bar, never two stacked, and the bar says what state the window is in:
- several places: the bar is their tabs, the window’s content the place in front;
- one place whose view has a header row: the frame offers its window bar to that row
(
WindowHeader::set_window_bar), so the app’s title and actions and the frame’s controls read as one bar; - one place with no header row of its own, in front: the frame’s own bar names it;
- one such place behind: the bar is the decorations alone, as a desktop draws a window nobody is typing into.
The window’s own controls stand in a pill of the floating material at the trailing end of the bar in every state, and the app’s own slots stay the app’s. A view says which window is in front and what its controls are; the theme decides everything the frame is made of.
Structs§
- Window
Frame WindowFramePropsbuilt: layers on the window surface, the content (under the frame’s own bar while it needs one) and the controls over its bar’s trailing end.- Window
Frame Props - A window standing on a desktop: the window surface with its edge and shadow, holding the window’s content and its controls, clipped to its radius.