#include "donner/css/VariableSubstitution.h"Classes | |
| struct | donner::css::VariableDefinition |
| One winning local custom declaration. A missing value represents the initial, guaranteed-invalid value and masks an inherited value of the same name. Declarations that inherit unchanged can be omitted; the lookup supplies their already computed parent value. More... | |
| struct | donner::css::VariableOutputs |
| The caller owns the canonical computed sequences. Publishing one result before evaluating its dependents permits retained-byte admission at allocation time, without keeping a second uncharged copy of every expanded value. More... | |
Namespaces | |
| namespace | donner |
| Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css. | |
| namespace | donner::css |
| Donner CSS library, a standalone composable CSS parser. | |
Functions | |
| bool | donner::css::ResolveVariableDefinitions (std::span< const VariableDefinition > local, const VariableLookup &inherited, const VariableOutputs &outputs, VariableSubstitutionLimits limits={}, const std::function< bool(std::size_t, std::size_t)> &admit={}) |
| Compute local values in selected dependency order. Each name occurs once, and all definition spans must stay alive throughout the call. The caller keeps already published and inherited values stable while an individual value is computed. Cycles invalidate exactly their participants; unused fallbacks create no dependency, while a selected fallback can. A dependent can use a fallback after a referenced cycle becomes guaranteed-invalid. | |
| struct donner::css::VariableDefinition |
One winning local custom declaration. A missing value represents the initial, guaranteed-invalid value and masks an inherited value of the same name. Declarations that inherit unchanged can be omitted; the lookup supplies their already computed parent value.
| Class Members | ||
|---|---|---|
| string_view | name | |
| optional< span< const ComponentValue > > | value | |
| struct donner::css::VariableOutputs |
The caller owns the canonical computed sequences. Publishing one result before evaluating its dependents permits retained-byte admission at allocation time, without keeping a second uncharged copy of every expanded value.
| Class Members | ||
|---|---|---|
| function< optional< span< const ComponentValue > >(size_t)> | lookup | Read a previously published local result by its definition index. |
| function< bool(size_t, VariableSubstitutionResult)> | publish | Store one result by definition index. Return false on refusal. |