StyleBase
The base class for StyleSheet and StyleRule.
This class is not creatable. Instances of this class cannot be created with Instance.new.
| Memory category | Gui |
|---|
Member index 4
Description
The base class for StyleSheet and StyleRule. Holds a list of child StyleRules, as well as token definitions which are stored as attributes.
History 8
- 664 Change Parameters of InsertStyleRule from (rule: StyleRule, index: int?) to (rule: StyleRule, priority: int?)
- 648 Change Parameters of SetStyleRules from (rules: Objects) to (rules: Instances)
- 648 Change ReturnType of GetStyleRules from Objects to Instances
- 580 Add StyleRulesChanged
- 578 Add SetStyleRules
- 578 Add InsertStyleRule
- 578 Add GetStyleRules
- 577 Add StyleBase
Members 4
GetStyleRules
| Parameters (0) | ||
|---|---|---|
| No parameters. | ||
| Returns (1) | ||
| Instances | ||
Returns an array of associated StyleRules.
| Thread safety | Unsafe |
|---|
History 2
- 648 Change ReturnType of GetStyleRules from Objects to Instances
- 578 Add GetStyleRules
InsertStyleRule
| Parameters (2) | ||
|---|---|---|
| rule | StyleRule | |
| priority | int? | |
| Returns (1) | ||
| null | ||
Inserts a new StyleRule into the array of rules so that its
Priority is greater than all previous
StyleRules. If priority is specified, sets the new
rule's Priority to the specified value.
| Thread safety | Unsafe |
|---|
History 2
- 664 Change Parameters of InsertStyleRule from (rule: StyleRule, index: int?) to (rule: StyleRule, priority: int?)
- 578 Add InsertStyleRule
SetStyleRules
| Parameters (1) | ||
|---|---|---|
| rules | Instances | |
| Returns (1) | ||
| null | ||
Similar to InsertStyleRule() but lets you declare and set multiple StyleRules at once.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | |
| Thread safety | Unsafe |
|---|
History 2
- 648 Change Parameters of SetStyleRules from (rules: Objects) to (rules: Instances)
- 578 Add SetStyleRules
StyleRulesChanged
| Parameters (0) | ||
|---|---|---|
| No parameters. | ||
Fires when one or more StyleRules is explicitly changed on the connected StyleSheet or StyleRule, for example when InsertStyleRule() is called.
| Thread safety | Unsafe |
|---|
History 1
- 580 Add StyleRulesChanged