Skip to main content

PickerBuilder

Trait PickerBuilder 

Source
pub trait PickerBuilder: Sized {
    // Required methods
    fn enabled<M>(self, v: impl IntoReactive<bool, M>) -> Self;
    fn separators_before(self, indexes: impl IntoIterator<Item = usize>) -> Self;
    fn menu(self) -> Self;
    fn segmented(self) -> Self;
    fn inline(self) -> Self;
    fn style(self, style: PickerStyle) -> Self;
}
Expand description

Builder methods of Picker, reachable through a Decorated (docs/api-style.md “Typed builders and erasure”): generic modifiers and typed ones chain in any order.

Required Methods§

Source

fn enabled<M>(self, v: impl IntoReactive<bool, M>) -> Self

Whether the picker takes input (default true); a constant or a reactive bool.

Source

fn separators_before(self, indexes: impl IntoIterator<Item = usize>) -> Self

Insert native menu separators before these option indexes. Indexes still refer to options, so separators never change the selection binding. AppKit/UIKit menu style honors this; other backends and styles display the same options without grouping.

Source

fn menu(self) -> Self

Source

fn segmented(self) -> Self

Source

fn inline(self) -> Self

Source

fn style(self, style: PickerStyle) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<DecoratedInner: PickerBuilder + Piece> PickerBuilder for Decorated<DecoratedInner>

Source§

impl<T: Clone + PartialEq + 'static, S: PickerSelection<T>> PickerBuilder for Picker<T, S>

Day API ↩ Guides· daybrite.dev