载入中...
搜索中...
未找到
UiThemeEditorScriptBindings.cpp
浏览该文件的文档.
41 return bind.checked(self, "theme editor must not be null", [&] { return self->editor().selectTheme(id); });
54 return bind.checked(self, "theme editor must not be null", [&] { return self->editor().deleteSelected(); });
57 return bind.checked(self, "theme editor must not be null", [&] { return self->editor().setActiveSelected(); });
64 "setColor", [bind](ScriptUiThemeEditor* self, const std::string& path, float r, float g, float b, float a) {
71 themeEditor.addFunc("setFloat", [bind](ScriptUiThemeEditor* self, const std::string& path, float value) {
75 themeEditor.addFunc("applyPreviewHost", [bind](ScriptUiThemeEditor* self, const std::string& hostName) {
79 editor::registerEditorHistory<ScriptUiThemeEditor>(themeEditor, bind, "theme editor must not be null");
84 themeEditor, "getSelectedId", [](ScriptUiThemeEditor& self) { return self.editor().selectedId(); },
87 themeEditor, "getActiveId", [](ScriptUiThemeEditor& self) { return self.editor().activeId(); }, std::string{});
92 themeEditor, "getThemeCount", [](ScriptUiThemeEditor& self) { return self.editor().themeCount(); }, 0);
124 vm, Status::failure(Diagnostic::error(DiagnosticCode::InvalidArgument, "theme editor must not be null",
Per-translation-unit VM + diagnostic-source helper for Squirrel bindings.
Squirrel adapter for the UI theme editor.
UI-neutral named Theme catalog editor: workspace, gallery preview, undo.
Owning, renderer-independent dynamic values.
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 Status failure(StatusCode code, Diagnostic diagnostic)
Construct a failed status with one diagnostic.
Definition Status.h:84
static Status success(StatusCode code=StatusCode::Ok)
Construct a successful status with an explicit non-error outcome.
Definition Status.h:81
Editor facade binder: common script::BindContext plus history/owned-create helpers.
Definition EditorScriptProjection.h:135
ssq::Table projectStatusResult(HSQUIRRELVM vm, const Status &status)
Project a checked native status that carries no payload.
Definition SquirrelBinding.cpp:454
Definition UiEditorModule.cpp:6
void exposeUiThemeEditorScriptBindings(ssq::Table &table, ssq::Class &moduleClass)
Expose the script-owned UiThemeEditor factory on UiEditorModule.
Definition UiThemeEditorScriptBindings.cpp:34
@ InvalidArgument
@ Applied
Definition Container.h:602