-
Notifications
You must be signed in to change notification settings - Fork 7
Enumeration entry
Giorgio Garofalo edited this page Oct 16, 2024
·
7 revisions
An enumeration entry is an input value that matches the name of an element from an enumeration. Enumerations cannot be created from the Quarkdown language, so by enumeration we refer to a native JVM enum
.
This value type is common among function parameters in the stdlib. From the user side, they are just strings. The main difference happens at invocation time, where an error is thrown if the value does not match any of the available entries.
Name matching follows the following rules:
-
Case-insensitive
normal
is the same asNORMAL
-
Spacing: words in native entries are separated by an
_
(underscore), which can be - and should be - omitted.spacebetween
is the same asspace_between
Examples:
.pageformat {A4} <!-- A4 is an entry of PageSizeFormat -->
.row alignment:{center} <!-- center is an entry of MainAxisAlignment --> ...
.box type:{warning} <!-- warning is an entry of Box.Type --> ...
- Syntax of a function call
- Declaring functions
- Dynamic typing
- Localization
- Including other Quarkdown files
- Importing external libraries
- Document metadata
- Theme
- Page format
- Page margin content
- Page counter
- Automatic page break
- Numbering
- Table of contents
- Stacks (row, column, grid)
- Align
- Container
- Box
- Collapsible
- Whitespace
- String
- Number
- Markdown content
- Boolean
- Enumeration entry
- Iterable
- Dictionary
- Range
- Lambda
- Size(s)
- Color
- Dynamic