ThemeDSL
class ThemeDSL
DSL (Domain Specific Language) helper functions for building Themes.
Adds syntax to define top-level rules in the form :
SELECTOR { ... }
Content copied to clipboard
Where SELECTOR
is either a String
, a WithPseudoStyle or a Selector.
...
is a block of code with a RuleDSL as the receiver.
Properties
Functions
Link copied to clipboard
Allows a string to be used as a selector for a rule. The type of selector depends on the string's contents. If it begins with a colon, then it uses PseudoStyleSelector, otherwise it uses StyleSelector. e.g.
Allows us to use enums (which implement WithPseudoStyle) as selectors. e.g.
For example :