Struct libnotcurses_sys::widgets::NcSelectorBuilder
source · pub struct NcSelectorBuilder { /* private fields */ }Expand description
A handy builder for NcSelector.
Implementations§
source§impl NcSelectorBuilder
impl NcSelectorBuilder
sourcepub fn default_item(self, item: u32) -> Self
pub fn default_item(self, item: u32) -> Self
Selects the default item
It is selected at the start and must be between 0 and itemcount-1.
sourcepub fn max_display(self, max: u32) -> Self
pub fn max_display(self, max: u32) -> Self
Selects the maximum number of items to display at once.
0 uses all available space.
Sets the footer string.
sourcepub fn all_channels(
self,
item_opt: impl Into<NcChannels>,
item_desc: impl Into<NcChannels>,
seltitle: impl Into<NcChannels>,
selfooter: impl Into<NcChannels>,
selbox: impl Into<NcChannels>
) -> Self
pub fn all_channels( self, item_opt: impl Into<NcChannels>, item_desc: impl Into<NcChannels>, seltitle: impl Into<NcChannels>, selfooter: impl Into<NcChannels>, selbox: impl Into<NcChannels> ) -> Self
Sets all the NcChannels.
sourcepub fn item_channels(
self,
opt: impl Into<NcChannels>,
desc: impl Into<NcChannels>
) -> Self
pub fn item_channels( self, opt: impl Into<NcChannels>, desc: impl Into<NcChannels> ) -> Self
Sets the NcChannels for the item.
sourcepub fn title_channels(self, title: impl Into<NcChannels>) -> Self
pub fn title_channels(self, title: impl Into<NcChannels>) -> Self
Sets the NcChannels for the title.
sourcepub fn secondary_channels(self, secondary: impl Into<NcChannels>) -> Self
pub fn secondary_channels(self, secondary: impl Into<NcChannels>) -> Self
Sets the NcChannels for the secondary title and the footer.
sourcepub fn box_channels(self, box: impl Into<NcChannels>) -> Self
pub fn box_channels(self, box: impl Into<NcChannels>) -> Self
Sets the NcChannels for the box title.
sourcepub fn finish(self, plane: &mut NcPlane) -> NcResult<&mut NcSelector>
pub fn finish(self, plane: &mut NcPlane) -> NcResult<&mut NcSelector>
Finishes the builder and returns the NcSelector.
Trait Implementations§
source§impl Debug for NcSelectorBuilder
impl Debug for NcSelectorBuilder
source§impl Default for NcSelectorBuilder
impl Default for NcSelectorBuilder
source§fn default() -> NcSelectorBuilder
fn default() -> NcSelectorBuilder
Returns the “default value” for a type. Read more