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

Per-context overlay-property overrides resolved from window-rule actions. More...

#include <PhosphorZones/AssignmentEntry.h>

Public Member Functions

bool isEmpty () const

Public Attributes

std::optional< QString > shaderId
QVariantMap shaderParams
QString shaderPresetId
 The named preset shaderParams are deltas against, resolved against shaderId.
std::optional< int > style
std::optional< QColor > highlightColor
std::optional< QColor > inactiveColor
std::optional< QColor > borderColor
std::optional< double > activeOpacity
std::optional< double > inactiveOpacity
std::optional< int > borderWidth
std::optional< int > borderRadius
std::optional< bool > showZoneNumbers

Detailed Description

Per-context overlay-property overrides resolved from window-rule actions.

Each field is set only when a matching context rule fills the corresponding overlay slot; an unset field falls through to the active layout's own value (shader / style) or the global config value (appearance). Consumed daemon-side by the overlay service — see LayoutRegistry::resolveContextOverlay.

style is the OverlayDisplayMode int (0 = ZoneRectangles, 1 = LayoutPreview); the resolver maps the wire token ("rectangles" / "preview") to the int so consumers compare against the same enum the layout exposes. shaderParams holds the overridden shader's uniform values (translated by the overlay service); it is only meaningful when shaderId is set and is empty when the rule overrides only the shader id (shader defaults apply).

The appearance fields (colours / opacities / border dimensions / zone-number visibility) layer over the global Snapping.Zones.* config: each is filled only by its SetOverlay* context action, and an unset field means "use the global config value" — config stays authoritative, the rule only overrides. Colours are concrete (no accent sentinel). Opacities are [0, 1].

Member Function Documentation

◆ isEmpty()

bool PhosphorZones::ContextOverlayOverride::isEmpty ( ) const
inline

Member Data Documentation

◆ activeOpacity

std::optional<double> PhosphorZones::ContextOverlayOverride::activeOpacity

◆ borderColor

std::optional<QColor> PhosphorZones::ContextOverlayOverride::borderColor

◆ borderRadius

std::optional<int> PhosphorZones::ContextOverlayOverride::borderRadius

◆ borderWidth

std::optional<int> PhosphorZones::ContextOverlayOverride::borderWidth

◆ highlightColor

std::optional<QColor> PhosphorZones::ContextOverlayOverride::highlightColor

◆ inactiveColor

std::optional<QColor> PhosphorZones::ContextOverlayOverride::inactiveColor

◆ inactiveOpacity

std::optional<double> PhosphorZones::ContextOverlayOverride::inactiveOpacity

◆ shaderId

std::optional<QString> PhosphorZones::ContextOverlayOverride::shaderId

◆ shaderParams

QVariantMap PhosphorZones::ContextOverlayOverride::shaderParams

◆ shaderPresetId

QString PhosphorZones::ContextOverlayOverride::shaderPresetId

The named preset shaderParams are deltas against, resolved against shaderId.

Empty means the params are the whole tuning. A preset belonging to another pack resolves to nothing, so the override falls back to its own params rather than rendering something unrelated.

◆ showZoneNumbers

std::optional<bool> PhosphorZones::ContextOverlayOverride::showZoneNumbers

◆ style

std::optional<int> PhosphorZones::ContextOverlayOverride::style

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