pub enum ParamKind {
Colour {
default: String,
},
Number {
unit: String,
min: f64,
max: f64,
step: f64,
default: f64,
},
Choice {
values: Vec<ChoiceValue>,
default: String,
},
}Expand description
What a parameter holds. The front end renders one control per kind; a kind it does not know is shown as a plain text field of the default’s JSON, never dropped.
Variants§
Colour
A colour (#rrggbb).
Number
A number.
Fields
Choice
One of a list of words.
Fields
§
values: Vec<ChoiceValue>The values, in the order the select shows them.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ParamKind
impl<'de> Deserialize<'de> for ParamKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ParamKind
Auto Trait Implementations§
impl Freeze for ParamKind
impl RefUnwindSafe for ParamKind
impl Send for ParamKind
impl Sync for ParamKind
impl Unpin for ParamKind
impl UnsafeUnpin for ParamKind
impl UnwindSafe for ParamKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more