Phosphor
Qt6 / Wayland library suite for window-management tools
Loading...
Searching...
No Matches
PhosphorScrollEngine::FloatRestore Struct Reference

What a floated/minimized window's column held, so unfloat restores the slot AND the user's width/display intent (a Proportion/Preset column must not come back as the default width). More...

#include <PhosphorScrollEngine/ScrollStashTypes.h>

Public Attributes

int column = -1
ColumnWidth width
ColumnDisplay display = ColumnDisplay::Normal
bool fullscreenHold = false
 Taken by the compositor for the window's OWN fullscreen (ScrollEngine::setWindowFullscreenFloat), not by the user; only that verb may undo it, and any other unfloat consumes the slot with it.
bool ownedTabbedHeight = false
 Whether this window was the tab that decided its TABBED column's cross extent when it left.
bool maximizedToEdges = false
 The source column's maximize-to-edges state when the window left as the column's ONLY tile.
int tileIndex = -1
 The tile slot inside a SHARED column (-1 when the window had its own column).
QString stackAnchor
 A surviving SIBLING of the shared column, used to re-locate the stack at restore time — the bare column index goes stale when columns close while the window floats, and a stale index would splice the window into a stranger's stack.
quint64 leaveSequence = 0
 When the window left its shared column, from an engine-wide counter (floatWindowInternal stamps it beside tileIndex, and a drag stamps the slot it takes the window out of, which a drop that degrades to a float keeps).
int minWidth = 0
 Minimum frame size (Tile::minWidth) at float time — the tile that held it dies with takeWindow, and dropping it would strip the relayout clamps until the compositor happens to re-report.
int minHeight = 0
WindowHeight height
 The tile's height INTENT at float time.
bool windowedFullscreen = false
 Windowed fullscreen, captured by the DRAG paths only (captureDragSlot): an Escape cancel is an exact restore, and the commit re-seats the tile, so both hand the flag back.
QString tabbedHeightHeirId
 The tab that inherited the extent ownership when this window left a TABBED column it owned (ownedTabbedHeight), and that tab's height intent at the moment it inherited, captured by floatWindowInternal.
WindowHeight tabbedHeightHeirIntent

Detailed Description

What a floated/minimized window's column held, so unfloat restores the slot AND the user's width/display intent (a Proportion/Preset column must not come back as the default width).

Namespace-level like the stash types above; lifetime and ownership are documented on the engine's m_floatRestore member. It deliberately carries no committed floor, along the strip or across it: both live per window in ScrollEngine::m_committedExtents, which a float round trip leaves standing (see CommittedExtent below). A drag that drops the float back in as an arrival sized by its client is the exception, and forgets them.

Member Data Documentation

◆ column

int PhosphorScrollEngine::FloatRestore::column = -1

◆ display

ColumnDisplay PhosphorScrollEngine::FloatRestore::display = ColumnDisplay::Normal

◆ fullscreenHold

bool PhosphorScrollEngine::FloatRestore::fullscreenHold = false

Taken by the compositor for the window's OWN fullscreen (ScrollEngine::setWindowFullscreenFloat), not by the user; only that verb may undo it, and any other unfloat consumes the slot with it.

Set only on an entry floatWindowInternal captured, so it is never true beside windowedFullscreen (which the float capture leaves false). A held window is floating, so it is absent from the mode-round-trip stash and the persisted strip blob: the slot is lost across a mode round trip or a login, and the window re-enters as a fresh open.

◆ height

WindowHeight PhosphorScrollEngine::FloatRestore::height

The tile's height INTENT at float time.

Same reasoning as the width/display above: without it a float round trip (which the effect's minimize machinery also drives) silently reset a user-set window height to Auto, while a mode round trip — which stashes the intent — preserved it.

Captured in the space of the column it came from, and re-stated in the space of the column it goes back to. Those differ by the tab indicator's cross reservation: an owning tab's height sizes its TABBED column (column space, the reservation included), while a stacked tile's height is the tile's own. A height carried from a tabbed column into a Normal one, or back, is therefore off by that reservation. The restore paths put a window back where it came from, where the spaces match. The drag drop does not (it can land a tab in a stack), and keeps the intent verbatim rather than guess which space the user meant.

◆ leaveSequence

quint64 PhosphorScrollEngine::FloatRestore::leaveSequence = 0

When the window left its shared column, from an engine-wide counter (floatWindowInternal stamps it beside tileIndex, and a drag stamps the slot it takes the window out of, which a drop that degrades to a float keeps).

Each tileIndex is a slot in the column as it stood at that leave, so putting several of a column's departed tiles back at once replays the leaves newest first (see ScrollEngine::columnTilesWithHiddenMembers). 0 for an entry no leave stamped (no shared column to go back into).

◆ maximizedToEdges

bool PhosphorScrollEngine::FloatRestore::maximizedToEdges = false

The source column's maximize-to-edges state when the window left as the column's ONLY tile.

Carried for the same reason the width is: a minimize/unminimize round trip of a maximized column's lone window must rebuild a maximized column, and the flag is declared state that nothing re-derives. Left false for a tile leaving a SHARED column, where the surviving column keeps the flag itself.

◆ minHeight

int PhosphorScrollEngine::FloatRestore::minHeight = 0

◆ minWidth

int PhosphorScrollEngine::FloatRestore::minWidth = 0

Minimum frame size (Tile::minWidth) at float time — the tile that held it dies with takeWindow, and dropping it would strip the relayout clamps until the compositor happens to re-report.

Kept CURRENT while the window floats: windowMinSizeUpdated has no tile to write to then, and without the write-through the unfloat re-applies whatever the client reported at float time.

◆ ownedTabbedHeight

bool PhosphorScrollEngine::FloatRestore::ownedTabbedHeight = false

Whether this window was the tab that decided its TABBED column's cross extent when it left.

Carried because leaving hands the ownership to the tab that came on show, so coming back has to take it again or the column keeps the substitute's height — a float round trip (which the effect's minimize machinery drives) or a cancelled drag would otherwise resize the column and leave it resized.

◆ stackAnchor

QString PhosphorScrollEngine::FloatRestore::stackAnchor

A surviving SIBLING of the shared column, used to re-locate the stack at restore time — the bare column index goes stale when columns close while the window floats, and a stale index would splice the window into a stranger's stack.

◆ tabbedHeightHeirId

QString PhosphorScrollEngine::FloatRestore::tabbedHeightHeirId

The tab that inherited the extent ownership when this window left a TABBED column it owned (ownedTabbedHeight), and that tab's height intent at the moment it inherited, captured by floatWindowInternal.

Every re-entry that carries this slot (the unfloat, the drag restore, a drag joining the window back into its own column) hands the ownership back only while the column is still sized the way the leave left it: the heir still owns it with the same intent, or the heir has left the column, whose hand-off on leaving is not a resize (ScrollEngine::restoreTabbedHeightOwner). A resize of the column while this window was away (an interactive drag, a height verb, another tab claiming it) is the user's newer word on the column's extent, and reclaiming would revert it, so a resize made while the heir is still in the column blocks the reclaim. One made after the heir left does not: the test keys on the heir alone, so once the heir is gone a resize or claim by any other tab is reverted on this window's return. That is the accepted cost of not recording every ownership move made while this window was away. Empty when no tab inherited (the column closed with the window) or for an entry the drag paths captured, whose hold leaves no room for such a resize and which hand the ownership back unconditionally.

◆ tabbedHeightHeirIntent

WindowHeight PhosphorScrollEngine::FloatRestore::tabbedHeightHeirIntent

◆ tileIndex

int PhosphorScrollEngine::FloatRestore::tileIndex = -1

The tile slot inside a SHARED column (-1 when the window had its own column).

A stacked tile's float round-trip re-enters its surviving stack instead of spawning a new column at the index.

◆ width

ColumnWidth PhosphorScrollEngine::FloatRestore::width

◆ windowedFullscreen

bool PhosphorScrollEngine::FloatRestore::windowedFullscreen = false

Windowed fullscreen, captured by the DRAG paths only (captureDragSlot): an Escape cancel is an exact restore, and the commit re-seats the tile, so both hand the flag back.

The float capture (floatWindowInternal) deliberately leaves this false — float and windowed fullscreen are exclusive by design, and a float round trip is supposed to drop the flag.


The documentation for this struct was generated from the following file: