Phosphor
Qt6 / Wayland library suite for window-management tools
Loading...
Searching...
No Matches
WindowPlacement.h File Reference
#include <PhosphorEngine/EngineTypes.h>
#include <PhosphorIdentity/VirtualScreenId.h>
#include <PhosphorIdentity/WindowId.h>
#include <QHash>
#include <QJsonArray>
#include <QJsonObject>
#include <QLatin1String>
#include <QRect>
#include <QString>
#include <QStringList>
#include <utility>

Go to the source code of this file.

Classes

struct  PhosphorEngine::EngineSlot
 One engine's view of a window: which managed slot it occupies (or that it is floating / unmanaged) in THAT engine's mode. More...
struct  PhosphorEngine::WindowPlacement
 One window's single, authoritative placement record — the unit of the unified, engine-agnostic restore model. More...

Namespaces

namespace  PhosphorEngine

Functions

bool PhosphorEngine::hasStableAppIdFor (const QString &appId, const QString &windowId)
 The REOPEN CONTRACT, which the predicates below implement: a window is restored only on the KWin output it opens on.
bool PhosphorEngine::recordContextMatchesLive (const WindowPlacement &p, int liveDesktop, const QString &liveActivity)
 Whether a record's own (desktop, activity) context is compatible with the live context an engine would INSERT it into — the guard a cross-screen claim needs because the claim VERDICT is granted on the record's context while the adoption keys the window by the home screen's CURRENT context.
template<typename IsEngineMode>
bool PhosphorEngine::pendingCrossScreenManagedRestore (const WindowPlacement &p, QLatin1String engineId, QLatin1String managedState, const QString &openingScreenId, IsEngineMode &&isEngineMode)
template<typename IsSnappingMode>
bool PhosphorEngine::pendingCrossScreenSnapRestore (const WindowPlacement &p, const QString &openingScreenId, IsSnappingMode &&isSnappingMode)
 The snap-engine specialization of the 5-argument form.
template<typename IsEngineMode>
bool PhosphorEngine::pendingCrossScreenManagedRestore (const WindowPlacement &p, QLatin1String engineId, QLatin1String managedState, const QString &openingWindowId, const QString &openingScreenId, IsEngineMode &&isEngineMode)
 The reopen contract over pendingCrossScreenManagedRestore.
template<typename IsSnappingMode>
bool PhosphorEngine::pendingCrossScreenSnapRestore (const WindowPlacement &p, const QString &openingWindowId, const QString &openingScreenId, IsSnappingMode &&isSnappingMode)
 The snap specialization of the reopen contract above.
bool PhosphorEngine::ownRecordLeftScreen (const WindowPlacement &own, const QString &openingScreenId)
 Whether a window's OWN record names a different screen than the one it is opening on while some engine still holds a live slot for it: the "left its screen" test of the reopen contract.

Variables

constexpr int PhosphorEngine::MAX_PLAUSIBLE_VIRTUAL_DESKTOP = 1024
 Upper sanity bound for a virtual desktop number read back from disk.