Scripting API
Scripting API
StyleSheetText
Class in Abyss.Core, from Abyss.Core.
A stylesheet's text read into its rules, and the edits the Style Sheets panel makes to it, as abyss_core::ui::sheet reads and writes them: the least text changed, what a person wrote kept as they wrote it.
public static class StyleSheetTextMethods
Outline
public static IReadOnlyList<SheetRule> Outline(string text)The rules of a sheet whose text is text, in the order they are written.
Parameters
text
SelectorProblem
public static string? SelectorProblem(string selector, bool nested = false)Why selector is no selector bevy_flair reads — at a sheet's top, or nested in a rule — or null where it is one.
Parameters
selectornested
Set
public static string Set(int rule, string css, string value)An edit setting the property css to value in the rule at rule.
Parameters
rulecssvalue
Unset
public static string Unset(int rule, string css)An edit by which the rule at rule sets css no more.
Parameters
rulecss
Add
public static string Add(string selector)An edit adding an empty rule of selector at the sheet's end.
Parameters
selector
Rename
public static string Rename(int rule, string selector)An edit writing the selector of the rule at rule as selector.
Parameters
ruleselector
Duplicate
public static string Duplicate(int rule)An edit copying the rule at rule, its comment with it, right after it.
Parameters
rule
Delete
public static string Delete(int rule)An edit taking the rule at rule, its comment with it, out.
Parameters
rule
Move
public static string Move(int rule, int? before)An edit moving the rule at rule before the one at before, or to the end.
Parameters
rulebefore
