Phosphor
Qt6 / Wayland library suite for window-management tools
 
Loading...
Searching...
No Matches
Patterns.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2026 fuddlesworth
2// SPDX-License-Identifier: LGPL-2.1-or-later
3
4#pragma once
5
7#include <PhosphorShellPatterns/phosphorshellpatterns_export.h>
8
32
34enum class Edge : int {
35 Top = 0,
36 Bottom = 1,
37 Left = 2,
38 Right = 3,
39};
40
42enum class Corner : int {
43 TopLeft = 0,
44 TopRight = 1,
45 BottomLeft = 2,
46 BottomRight = 3,
47};
48
49// ── Pattern presets (single-Role recipes) ──────────────────────────────
50
53[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role& Wallpaper();
54
58[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role& Hud();
59
62[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role& Modal();
63
67[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role& Floating();
68
69// ── Pattern factories (parameterised) ──────────────────────────────────
70
74[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT PhosphorLayer::Role Panel(Edge edge);
75
80[[nodiscard]] PHOSPHORSHELLPATTERNS_EXPORT PhosphorLayer::Role Toast(Corner corner);
81
82} // namespace PhosphorShellPatterns
Shell UI patterns.
Definition Patterns.h:31
PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role & Modal()
Modal dialog.
PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role & Floating()
Free-floating overlay.
PHOSPHORSHELLPATTERNS_EXPORT PhosphorLayer::Role Panel(Edge edge)
Panel anchored to a screen edge, reserving space via exclusive zone, keyboard-on-demand (clicking giv...
Corner
Screen corner a Toast anchors to.
Definition Patterns.h:42
PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role & Hud()
Heads-up display.
PHOSPHORSHELLPATTERNS_EXPORT const PhosphorLayer::Role & Wallpaper()
Wallpaper.
PHOSPHORSHELLPATTERNS_EXPORT PhosphorLayer::Role Toast(Corner corner)
Transient corner-anchored display.
Edge
Screen edge a Panel anchors to.
Definition Patterns.h:34
Value type describing a surface's protocol-level configuration.
Definition Role.h:77