载入中...
搜索中...
未找到
UiThemeProperty.cpp
浏览该文件的文档.
16 if (item.target != TargetId(id_) || item.type != "ui.theme" || !findTheme(ObjectId(item.item.value())))
22eve::Result<eve::Revision> UiThemeCatalogTarget::currentRevision(const SelectionSnapshot& selection) const {
29PropertySchema UiThemeCatalogTarget::schema(const SelectionSnapshot&) const { return themeTokenSchema(); }
31PropertyReadResult UiThemeCatalogTarget::read(const SelectionSnapshot& selection, const PropertyPath& path) const {
52 return eve::editing::failed<DomainOperation>(EditorStatus::Rejected, RuleId("editor.ui-theme.set"),
58 return eve::editing::failed<DomainOperation>(EditorStatus::NotFound, RuleId("editor.ui-theme.missing"),
62 return eve::editing::failed<DomainOperation>(EditorStatus::Rejected, RuleId("editor.ui-theme.token"),
A structured explanation of a failed, degraded, or noteworthy result.
Definition Diagnostic.h:94
static Diagnostic error(DiagnosticCode code, std::string message, std::string path={}, DiagnosticDetails details={}, std::string source={})
Construct an error diagnostic with the standard error severity.
Definition Diagnostic.h:125
static Result failure(Status status)
Construct a failed result from a structured status.
Definition Result.h:175
Revision revisionValue() const noexcept
Return the revision as the shared protocol revision type.
Definition EditableTarget.h:169
Dotted property path (layout.size) compared and persisted as text.
Definition EditingIds.h:78
Deterministic owning value tree shared by authoring hosts.
Definition EditingValue.h:19
eve::Result< eve::Revision > currentRevision(const SelectionSnapshot &selection) const override
Current revision.
Definition UiThemeProperty.cpp:22
PropertySchema schema(const SelectionSnapshot &selection) const override
Schema.
Definition UiThemeProperty.cpp:29
PropertyReadResult read(const SelectionSnapshot &selection, const PropertyPath &path) const override
Reads .
Definition UiThemeProperty.cpp:31
Result< DomainOperation > makeReset(const SelectionSnapshot &selection, const PropertyPath &path) const override
Make reset.
Definition UiThemeProperty.cpp:75
Result< DomainOperation > makeSet(const SelectionSnapshot &selection, const PropertyPath &path, const EditorValue &value, PropertySetMode mode) const override
Make set.
Definition UiThemeProperty.cpp:45
Result< void > validatePropertyValue(const PropertyDescriptor &descriptor, const Value &value)
Validate property value.
Definition EditingProperty.cpp:138
Definition UiDocument.cpp:9
EditorValue readThemeToken(const ui::Theme &theme, const PropertyPath &path)
Reads theme token.
Definition UiThemeTokens.cpp:299
Result< void > assignThemeToken(ui::Theme &theme, const PropertyPath &path, const EditorValue &value)
Assign theme token.
Definition UiThemeTokens.cpp:253
@ InvalidArgument
PropertyDescriptorLookup find(const PropertyPath &path) const
Finds find.
Definition EditingProperty.cpp:9
std::vector< SelectionItem > items
Definition EditingSelection.h:22