RGBMatrix.Animation.Config.FieldType.Option (rgb_matrix v0.1.0) View Source
An option field type for use in animation configuration.
Supports defining a list of pre-defined options as atoms.
To define an option field in an animation, specify :option
as the field
type.
Example:
field :direction, :option,
default: :right,
options: ~w(right left up down)a, # This must be a list of atoms
doc: [
name: "Direction",
description: """
Controls the direction of the wave
"""
]
# This options list produces the same result as above:
options: [
:right,
:left,
:up,
:down
]
Link to this section Summary
Link to this section Types
Specs
Specs
value() :: atom()