Portals0.7.0 · dev (544a5c68c72e · 2026-11-28 UTC)
Loading...
Searching...
No Matches
pss_data.hpp
1// Copyright (c) 2026 ttldtor.
2// SPDX-License-Identifier: BSL-1.0
3#pragma once
4
5#include <portals/style.hpp>
6
7#include <algorithm>
8#include <array>
9#include <limits>
10
11namespace portals {
13enum class PssProperty {
131};
132
134inline constexpr std::size_t PSS_PROPERTY_COUNT = static_cast<std::size_t>(PssProperty::ROLE_UNDERLINE) + 1;
136inline constexpr std::size_t PSS_SCALAR_PROPERTY_COUNT = static_cast<std::size_t>(PssProperty::GLYPH_FALLBACK) + 1;
138inline constexpr std::size_t NO_PSS_DECLARATION = std::numeric_limits<std::size_t>::max();
140inline constexpr std::size_t MAX_PSS_ERROR_SUBJECT_BYTES = 64;
142inline constexpr std::size_t MAX_PSS_SOURCE_NAME_BYTES = 4096;
144inline constexpr std::size_t MAX_PSS_DOCUMENT_BYTES = 4 * MAX_PSS_BYTES;
145
151
176
179 std::size_t offset{};
180 std::size_t line{1};
181 std::size_t column{1};
182
186 constexpr bool operator==(const PssLocation &other) const = default;
187};
188
192 bool boolean{};
193 std::int32_t width{};
194 std::int32_t pattern{};
195
199 constexpr bool operator==(const PssScalarValue &other) const = default;
200};
201
203struct PssError {
207 std::array<char, MAX_PSS_ERROR_SUBJECT_BYTES> subject{};
208 std::size_t subjectSize{};
210 std::string_view message;
211
213 constexpr std::string_view subjectView() const noexcept {
214 return {subject.data(), subjectSize};
215 }
216};
217
221 std::size_t declarationBegin{};
222 std::size_t declarationCount{};
223 std::array<std::size_t, PSS_PROPERTY_COUNT> effectiveDeclaration = [] {
224 std::array<std::size_t, PSS_PROPERTY_COUNT> result{};
225 result.fill(NO_PSS_DECLARATION);
226
227 return result;
228 }();
229
233 bool operator==(const PssRuleOrigin &other) const = default;
234};
235
238 std::size_t ruleIndex{};
239 PssProperty property{};
242 std::shared_ptr<const detail::ScrollbarGlyphLiteral> glyph{};
243
244 std::shared_ptr<const std::string> roleName{};
245
249 bool operator==(const PssDeclarationOrigin &other) const {
250 return ruleIndex == other.ruleIndex && property == other.property && location == other.location &&
251 value == other.value && (glyph == other.glyph || (glyph && other.glyph && *glyph == *other.glyph)) &&
252 (roleName == other.roleName || (roleName && other.roleName && *roleName == *other.roleName));
253 }
254};
255
261 ~PssDocument() = default;
262
265 std::string sourceName{""};
266 std::vector<PssRuleOrigin> origins = std::vector<PssRuleOrigin>(0);
267 std::vector<PssDeclarationOrigin> declarations = std::vector<PssDeclarationOrigin>(0);
268
272 bool operator==(const PssDocument &other) const = default;
273};
274
282std::expected<PssDocument, PssError> parsePssDocument(std::string_view bytes, std::string_view sourceName = {});
283} // namespace portals
Public Portals API.
Definition action.hpp:8
constexpr std::size_t NO_PSS_DECLARATION
Marker for an absent effective declaration occurrence.
Definition pss_data.hpp:138
constexpr std::size_t PSS_PROPERTY_COUNT
Number of supported PSS v0 properties.
Definition pss_data.hpp:134
constexpr std::size_t MAX_PSS_DOCUMENT_BYTES
Logical runtime document payload including all metadata occurrences.
Definition pss_data.hpp:144
PssProperty
PSS v0 declaration identities in metadata and compact descriptions.
Definition pss_data.hpp:13
@ UNDERLINE
Explicit underline flag.
Definition pss_data.hpp:18
@ SCROLLBAR_ARROWS_UNDERLINE
Scrollbar arrows underline.
Definition pss_data.hpp:54
@ SCROLLBAR_TRACK_PATTERN
Independent scrollbar source.
Definition pss_data.hpp:60
@ SCROLLBAR_TRACK_BOLD
Scrollbar track bold.
Definition pss_data.hpp:37
@ FRAME_LINE_FOREGROUND
Frame part frameLine.foreground.
Definition pss_data.hpp:20
@ SCROLLBAR_ARROWS_FOREGROUND
Scrollbar arrows foreground.
Definition pss_data.hpp:50
@ SCROLLBAR_VERTICAL_END_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:113
@ SCROLLBAR_THUMB_SINGLE_UNDERLINE
Thumb single underline.
Definition pss_data.hpp:82
@ SCROLLBAR_THUMB_START_BACKGROUND
Thumb start background.
Definition pss_data.hpp:64
@ ITALIC
Explicit italic flag.
Definition pss_data.hpp:17
@ BOLD
Explicit bold flag.
Definition pss_data.hpp:16
@ FRAME_ENDS_BACKGROUND
Frame part frameEnds.background.
Definition pss_data.hpp:31
@ SCROLLBAR_VERTICAL_THUMB_START_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:116
@ SCROLLBAR_THUMB_FOREGROUND
Scrollbar thumb foreground.
Definition pss_data.hpp:40
@ SCROLLBAR_THUMB_START_UNDERLINE
Thumb start underline.
Definition pss_data.hpp:67
@ FRAME_ENDS_FOREGROUND
Frame part frameEnds.foreground.
Definition pss_data.hpp:30
@ SCROLLBAR_CORNER_FOREGROUND
Scrollbar corner foreground.
Definition pss_data.hpp:55
@ SCROLLBAR_THUMB_SINGLE_ITALIC
Thumb single italic.
Definition pss_data.hpp:81
@ SLIDER_THUMB_UNDERLINE
Slider thumb underline.
Definition pss_data.hpp:97
@ SCROLLBAR_HORIZONTAL_THUMB_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:101
@ ROLE_ITALIC
Runtime named semantic role italic.
Definition pss_data.hpp:129
@ SLIDER_TRACK_BOLD
Slider track bold.
Definition pss_data.hpp:85
@ SLIDER_TRACK_ITALIC
Slider track italic.
Definition pss_data.hpp:86
@ SCROLLBAR_VERTICAL_THUMB_BODY_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:117
@ FRAME_TITLE_BOLD
Frame part frameTitle.bold.
Definition pss_data.hpp:27
@ FRAME_LINE_BOLD
Frame part frameLine.bold.
Definition pss_data.hpp:22
@ SCROLLBAR_HORIZONTAL_TRACK_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:100
@ SLIDER_FILL_UNDERLINE
Slider fill underline.
Definition pss_data.hpp:92
@ WIDTH
Runtime state-independent horizontal mode or exact extent.
Definition pss_data.hpp:121
@ MAX_WIDTH
Runtime state-independent hard column cap.
Definition pss_data.hpp:123
@ MIN_WIDTH
State-independent cell minimum.
Definition pss_data.hpp:19
@ SLIDER_FILL_BACKGROUND
Slider fill background.
Definition pss_data.hpp:89
@ SCROLLBAR_VERTICAL_START_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:112
@ SCROLLBAR_VERTICAL_TRACK_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:110
@ SCROLLBAR_THUMB_BOLD
Scrollbar thumb bold.
Definition pss_data.hpp:42
@ SCROLLBAR_THUMB_BODY_BOLD
Thumb body bold.
Definition pss_data.hpp:70
@ SCROLLBAR_HORIZONTAL_FORWARD_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:105
@ FRAME_TITLE_UNDERLINE
Frame part frameTitle.underline.
Definition pss_data.hpp:29
@ SCROLLBAR_HORIZONTAL_THUMB_END_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:108
@ FRAME_ENDS_ITALIC
Frame part frameEnds.italic.
Definition pss_data.hpp:33
@ FRAME_TITLE_BACKGROUND
Frame part frameTitle.background.
Definition pss_data.hpp:26
@ SCROLLBAR_THUMB_PATTERN
Independent scrollbar source.
Definition pss_data.hpp:61
@ GLYPH_FALLBACK
Portable admission fallback.
Definition pss_data.hpp:99
@ SCROLLBAR_THUMB_BODY_UNDERLINE
Thumb body underline.
Definition pss_data.hpp:72
@ SLIDER_FILL_ITALIC
Slider fill italic.
Definition pss_data.hpp:91
@ SCROLLBAR_ENDS_BOLD
Scrollbar ends bold.
Definition pss_data.hpp:47
@ ROLE_BACKGROUND
Runtime named semantic role background.
Definition pss_data.hpp:127
@ SCROLLBAR_THUMB_SINGLE_FOREGROUND
Thumb single foreground.
Definition pss_data.hpp:78
@ SCROLLBAR_HORIZONTAL_THUMB_START_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:106
@ SCROLLBAR_THUMB_SINGLE_BOLD
Thumb single bold.
Definition pss_data.hpp:80
@ SCROLLBAR_THUMB_SINGLE_BACKGROUND
Thumb single background.
Definition pss_data.hpp:79
@ GLYPH_PROFILE
Named base glyph map.
Definition pss_data.hpp:98
@ SCROLLBAR_CORNER_ITALIC
Scrollbar corner italic.
Definition pss_data.hpp:58
@ FRAME_LINE_BACKGROUND
Frame part frameLine.background.
Definition pss_data.hpp:21
@ SCROLLBAR_THUMB_END_FOREGROUND
Thumb end foreground.
Definition pss_data.hpp:73
@ SLIDER_TRACK_FOREGROUND
Slider track foreground.
Definition pss_data.hpp:83
@ SCROLLBAR_THUMB_END_BOLD
Thumb end bold.
Definition pss_data.hpp:75
@ SCROLLBAR_THUMB_START_BOLD
Thumb start bold.
Definition pss_data.hpp:65
@ SCROLLBAR_ARROWS_BOLD
Scrollbar arrows bold.
Definition pss_data.hpp:52
@ SLIDER_TRACK_UNDERLINE
Slider track underline.
Definition pss_data.hpp:87
@ SCROLLBAR_TRACK_BACKGROUND
Scrollbar track background.
Definition pss_data.hpp:36
@ FRAME_LINE_ITALIC
Frame part frameLine.italic.
Definition pss_data.hpp:23
@ SCROLLBAR_CORNER_BOLD
Scrollbar corner bold.
Definition pss_data.hpp:57
@ BACKGROUND
RGB fill color.
Definition pss_data.hpp:15
@ ROLE_UNDERLINE
Runtime named semantic role underline.
Definition pss_data.hpp:130
@ SCROLLBAR_VERTICAL_THUMB_END_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:118
@ SCROLLBAR_HORIZONTAL_THUMB_BODY_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:107
@ SCROLLBAR_THUMB_UNDERLINE
Scrollbar thumb underline.
Definition pss_data.hpp:44
@ SCROLLBAR_THUMB_END_UNDERLINE
Thumb end underline.
Definition pss_data.hpp:77
@ SLIDER_FILL_BOLD
Slider fill bold.
Definition pss_data.hpp:90
@ SCROLLBAR_THUMB_ITALIC
Scrollbar thumb italic.
Definition pss_data.hpp:43
@ SCROLLBAR_THUMB_BODY_ITALIC
Thumb body italic.
Definition pss_data.hpp:71
@ SCROLLBAR_ENDS_FOREGROUND
Scrollbar ends foreground.
Definition pss_data.hpp:45
@ SCROLLBAR_THUMB_END_BACKGROUND
Thumb end background.
Definition pss_data.hpp:74
@ SCROLLBAR_THUMB_START_ITALIC
Thumb start italic.
Definition pss_data.hpp:66
@ SCROLLBAR_VERTICAL_FORWARD_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:115
@ FRAME_ENDS_UNDERLINE
Frame part frameEnds.underline.
Definition pss_data.hpp:34
@ SCROLLBAR_ARROWS_ITALIC
Scrollbar arrows italic.
Definition pss_data.hpp:53
@ SCROLLBAR_VERTICAL_THUMB_SINGLE_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:119
@ SLIDER_FILL_FOREGROUND
Slider fill foreground.
Definition pss_data.hpp:88
@ SLIDER_TRACK_BACKGROUND
Slider track background.
Definition pss_data.hpp:84
@ SCROLLBAR_VERTICAL_BACKWARD_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:114
@ SCROLLBAR_HORIZONTAL_END_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:103
@ SLIDER_THUMB_BOLD
Slider thumb bold.
Definition pss_data.hpp:95
@ ROLE_BOLD
Runtime named semantic role bold.
Definition pss_data.hpp:128
@ SCROLLBAR_ARROWS_BACKGROUND
Scrollbar arrows background.
Definition pss_data.hpp:51
@ SCROLLBAR_VERTICAL_THUMB_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:111
@ SCROLLBAR_HORIZONTAL_BACKWARD_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:104
@ SCROLLBAR_THUMB_BODY_BACKGROUND
Thumb body background.
Definition pss_data.hpp:69
@ SCROLLBAR_THUMB_START_FOREGROUND
Thumb start foreground.
Definition pss_data.hpp:63
@ SCROLLBAR_ARROW_PATTERN
Independent scrollbar source.
Definition pss_data.hpp:62
@ SCROLLBAR_HORIZONTAL_START_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:102
@ SLIDER_THUMB_FOREGROUND
Slider thumb foreground.
Definition pss_data.hpp:93
@ SCROLLBAR_TRACK_UNDERLINE
Scrollbar track underline.
Definition pss_data.hpp:39
@ SCROLLBAR_TRACK_FOREGROUND
Scrollbar track foreground.
Definition pss_data.hpp:35
@ SCROLLBAR_THUMB_BACKGROUND
Scrollbar thumb background.
Definition pss_data.hpp:41
@ SCROLLBAR_ENDS_ITALIC
Scrollbar ends italic.
Definition pss_data.hpp:48
@ SCROLLBAR_THUMB_BODY_FOREGROUND
Thumb body foreground.
Definition pss_data.hpp:68
@ SCROLLBAR_CORNER_UNDERLINE
Scrollbar corner underline.
Definition pss_data.hpp:59
@ FRAME_TITLE_FOREGROUND
Frame part frameTitle.foreground.
Definition pss_data.hpp:25
@ HEIGHT
Runtime state-independent vertical mode or exact extent.
Definition pss_data.hpp:122
@ FRAME_ENDS_BOLD
Frame part frameEnds.bold.
Definition pss_data.hpp:32
@ SCROLLBAR_CORNER_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:120
@ SCROLLBAR_THUMB_END_ITALIC
Thumb end italic.
Definition pss_data.hpp:76
@ SCROLLBAR_ENDS_UNDERLINE
Scrollbar ends underline.
Definition pss_data.hpp:49
@ FOREGROUND
RGB text color.
Definition pss_data.hpp:14
@ SLIDER_THUMB_ITALIC
Slider thumb italic.
Definition pss_data.hpp:96
@ ROLE_FOREGROUND
Runtime named semantic role foreground; name is occurrence metadata.
Definition pss_data.hpp:126
@ SLIDER_THUMB_BACKGROUND
Slider thumb background.
Definition pss_data.hpp:94
@ MAX_HEIGHT
Runtime state-independent hard row cap.
Definition pss_data.hpp:125
@ SCROLLBAR_TRACK_ITALIC
Scrollbar track italic.
Definition pss_data.hpp:38
@ SCROLLBAR_ENDS_BACKGROUND
Scrollbar ends background.
Definition pss_data.hpp:46
@ FRAME_LINE_UNDERLINE
Frame part frameLine.underline.
Definition pss_data.hpp:24
@ SCROLLBAR_CORNER_BACKGROUND
Scrollbar corner background.
Definition pss_data.hpp:56
@ FRAME_TITLE_ITALIC
Frame part frameTitle.italic.
Definition pss_data.hpp:28
@ MIN_HEIGHT
Runtime state-independent hard row minimum.
Definition pss_data.hpp:124
@ SCROLLBAR_HORIZONTAL_THUMB_SINGLE_GLYPH
Owning runtime literal glyph.
Definition pss_data.hpp:109
std::expected< PssDocument, PssError > parsePssDocument(std::string_view bytes, std::string_view sourceName={})
Parse strict UTF-8 PSS v0 into owning declarations and source metadata, without I/O.
constexpr std::size_t MAX_PSS_SOURCE_NAME_BYTES
Maximum UTF-8 source identity bytes in an owning runtime document.
Definition pss_data.hpp:142
constexpr std::size_t PSS_SCALAR_PROPERTY_COUNT
Scalar-only prefix retained by compile-time PSS descriptors.
Definition pss_data.hpp:136
PssOriginKind
Coordinates describe either original PSS bytes or explicit typed ordinals.
Definition pss_data.hpp:147
@ SYNTHETIC_TYPED
Ordinals in a typed snapshot; they are not C++ file coordinates.
Definition pss_data.hpp:149
@ PSS_BYTES
Actual offsets, LF lines, and byte columns in original PSS input.
Definition pss_data.hpp:148
constexpr std::size_t MAX_PSS_BYTES
Finite parser input byte budget.
Definition style.hpp:304
@ NONE
Caption only, including a single-glyph action button.
Definition controls.hpp:157
PssErrorCode
Structured PSS errors independent of compiler wording.
Definition pss_data.hpp:153
@ RULE_LIMIT
Source-order rule count exceeds the selected budget.
Definition pss_data.hpp:156
@ INPUT_LIMIT
Input bytes exceed the selected budget.
Definition pss_data.hpp:155
@ UNTERMINATED_COMMENT
Missing comment terminator.
Definition pss_data.hpp:167
@ INVALID_WIDTH
Negative, overflowing, or state-dependent minimum width.
Definition pss_data.hpp:173
@ DOCUMENT_LIMIT
Runtime owning payload exceeds its logical budget.
Definition pss_data.hpp:160
@ UNKNOWN_PROPERTY
Unsupported v0 declaration name.
Definition pss_data.hpp:171
@ EXPECTED_PUNCTUATION
Missing required punctuation.
Definition pss_data.hpp:166
@ EXPECTED_IDENTIFIER
Expected an ASCII name.
Definition pss_data.hpp:165
@ DUPLICATE_STATE
More than one presentation-state predicate.
Definition pss_data.hpp:169
@ DUPLICATE_ID
More than one ID predicate in a selector.
Definition pss_data.hpp:168
@ EXPECTED_SELECTOR
No v0 selector at the current position.
Definition pss_data.hpp:164
@ CLASS_LIMIT
Compact class predicates exceed their budget.
Definition pss_data.hpp:157
@ NUL_BYTE
Embedded NUL in strict input or source identity.
Definition pss_data.hpp:163
@ NONE
Successful admission.
Definition pss_data.hpp:154
@ DECLARATION_LIMIT
Compact declaration occurrences exceed their budget.
Definition pss_data.hpp:158
@ INVALID_UTF8
Invalid UTF-8 sequence anywhere in strict input.
Definition pss_data.hpp:162
@ INVALID_VALUE
Value does not have the property's exact scalar syntax.
Definition pss_data.hpp:172
@ TEXT_LIMIT
Compact owning text exceeds its shared arena.
Definition pss_data.hpp:159
@ UNKNOWN_STATE
Unsupported presentation state.
Definition pss_data.hpp:170
@ ALLOCATION
Runtime allocation or checked ownership transfer failed.
Definition pss_data.hpp:174
@ SOURCE_NAME_LIMIT
Source identity exceeds its byte budget.
Definition pss_data.hpp:161
constexpr std::size_t MAX_PSS_ERROR_SUBJECT_BYTES
Maximum owned ASCII bytes retained in an error subject.
Definition pss_data.hpp:140
TreeError
Checked tree failures; rejected operations never start the requested callback.
Definition widget_types.hpp:26
@ INVALID_ARGUMENT
An option, enum value or operation argument is invalid.
Definition widget_types.hpp:27
One declaration's source coordinates, retained even when a later duplicate wins.
Definition pss_data.hpp:237
bool operator==(const PssDeclarationOrigin &other) const
Definition pss_data.hpp:249
std::size_t ruleIndex
Source-order containing rule index.
Definition pss_data.hpp:238
PssLocation location
Start of the property name.
Definition pss_data.hpp:240
PssProperty property
Destination identity.
Definition pss_data.hpp:239
std::shared_ptr< const std::string > roleName
Optional owning runtime semantic destination.
Definition pss_data.hpp:244
std::shared_ptr< const detail::ScrollbarGlyphLiteral > glyph
Owning runtime literal occurrence.
Definition pss_data.hpp:242
PssScalarValue value
Original scalar, retained when a later duplicate overwrites it.
Definition pss_data.hpp:241
Owning parsed declarations and provenance; input bytes need not survive the call. Metadata is not aut...
Definition pss_data.hpp:259
bool operator==(const PssDocument &other) const =default
std::vector< PssRuleOrigin > origins
One origin per rule.
Definition pss_data.hpp:266
std::string sourceName
Owned caller-supplied source identity; empty means anonymous.
Definition pss_data.hpp:265
PssOriginKind originKind
Coordinate interpretation for this document.
Definition pss_data.hpp:264
std::vector< PssDeclarationOrigin > declarations
All occurrences.
Definition pss_data.hpp:267
~PssDocument()=default
Suppress implicit noexcept moves because checked MSVC container transfers can allocate.
StyleSheet sheet
Existing source-order runtime declarations, using the existing cascade.
Definition pss_data.hpp:263
Allocation-free error owning its bounded subject; message always has static lifetime.
Definition pss_data.hpp:203
constexpr std::string_view subjectView() const noexcept
Definition pss_data.hpp:213
std::size_t subjectSize
Populated subject bytes, without a terminator requirement.
Definition pss_data.hpp:208
PssErrorCode code
Specific parser/admission failure.
Definition pss_data.hpp:205
std::array< char, MAX_PSS_ERROR_SUBJECT_BYTES > subject
Owned ASCII subject; non-ASCII bytes become '?'.
Definition pss_data.hpp:207
PssLocation location
Original byte coordinates, or identity coordinates for identity validation.
Definition pss_data.hpp:206
std::string_view message
Static English explanation, never a source view.
Definition pss_data.hpp:210
TreeError cause
Validation or runtime allocation category.
Definition pss_data.hpp:204
bool subjectTruncated
Subject exceeded the fixed owning capacity.
Definition pss_data.hpp:209
Position in original PSS bytes, including an accepted leading BOM.
Definition pss_data.hpp:178
std::size_t offset
Zero-based byte offset.
Definition pss_data.hpp:179
constexpr bool operator==(const PssLocation &other) const =default
std::size_t line
One-based line, advanced only by LF.
Definition pss_data.hpp:180
std::size_t column
One-based byte column.
Definition pss_data.hpp:181
Owning coordinates and occurrence links for one source-order rule.
Definition pss_data.hpp:219
std::size_t declarationBegin
First occurrence index in PssDocument::declarations.
Definition pss_data.hpp:221
bool operator==(const PssRuleOrigin &other) const =default
PssLocation selector
Start of the complete conjunction selector.
Definition pss_data.hpp:220
std::array< std::size_t, PSS_PROPERTY_COUNT > effectiveDeclaration
Last occurrence for each property, or NO_PSS_DECLARATION.
Definition pss_data.hpp:223
std::size_t declarationCount
Number of occurrences, including overwritten duplicates.
Definition pss_data.hpp:222
Allocation-free declaration scalar; its owning occurrence property identifies the active field.
Definition pss_data.hpp:190
std::int32_t pattern
Property-tagged glyph/preset ordinal or StyleSizeMode; otherwise zero.
Definition pss_data.hpp:194
std::int32_t width
Cell bound/extent, or bit-preserved unsigned weight for a FLEX axis.
Definition pss_data.hpp:193
constexpr bool operator==(const PssScalarValue &other) const =default
RgbColor color
FOREGROUND or BACKGROUND RGB; otherwise zero.
Definition pss_data.hpp:191
Owning RGB color; terminal encoding belongs to the output adapter.
Definition cell_buffer.hpp:20
Owned immutable-at-use rules; constructing typed values may allocate and throw.
Definition style.hpp:233