Portals0.7.0 · dev (544a5c68c72e · 2026-11-28 UTC)
Loading...
Searching...
No Matches
style_source.hpp
1// Copyright (c) 2026 ttldtor.
2// SPDX-License-Identifier: BSL-1.0
3#pragma once
4
5#include <portals/detail/pss_data.hpp>
6
7namespace portals {
8namespace detail {
13std::expected<void, PssError> validateStyleDocument(const PssDocument &document);
14} // namespace detail
15
21 ~StyleLayerSource() = default;
22
25 std::string name{""};
26 std::shared_ptr<const PssDocument> document;
27};
28} // namespace portals
Weak UI-affine observer; destruction does not remove its layer.
Definition style.hpp:272
Public Portals API.
Definition action.hpp:8
StyleTier
Independent cascade priority, before selector specificity.
Definition style.hpp:251
@ DEFAULTS
Declarations above widget defaults and below all other tiers.
Definition style.hpp:252
Owning provenance snapshot for one real engine layer, including unknown typed sources....
Definition style_source.hpp:19
std::string name
Owned engine layer identity, independent of the document source label.
Definition style_source.hpp:25
StyleLayerHandle handle
UI-affine weak identity; stale after removal, whole replacement, or scene destruction.
Definition style_source.hpp:23
std::shared_ptr< const PssDocument > document
Owned immutable metadata, or null for a low-level/unknown source.
Definition style_source.hpp:26
StyleTier tier
Actual cascade priority of the observed layer.
Definition style_source.hpp:24
~StyleLayerSource()=default
Suppress implicit noexcept moves because checked MSVC string transfers can allocate.