Trait reedline::MenuBuilder

source ·
pub trait MenuBuilder: Menu + Sized {
    // Required method
    fn settings_mut(&mut self) -> &mut MenuSettings;

    // Provided methods
    fn with_name(self, name: &str) -> Self { ... }
    fn with_text_style(self, color: Style) -> Self { ... }
    fn with_selected_text_style(self, color: Style) -> Self { ... }
    fn with_description_text_style(self, color: Style) -> Self { ... }
    fn with_match_text_style(self, color: Style) -> Self { ... }
    fn with_selected_match_text_style(self, color: Style) -> Self { ... }
    fn with_marker(self, marker: &str) -> Self { ... }
    fn with_only_buffer_difference(self, only_buffer_difference: bool) -> Self { ... }
}
Expand description

Common builder for all menus

Required Methods§

source

fn settings_mut(&mut self) -> &mut MenuSettings

Get mutable MenuSettings required for the builder functions

Provided Methods§

source

fn with_name(self, name: &str) -> Self

Menu builder with new name

source

fn with_text_style(self, color: Style) -> Self

Menu builder with new value for text style

source

fn with_selected_text_style(self, color: Style) -> Self

Menu builder with new value for selected text style

source

fn with_description_text_style(self, color: Style) -> Self

Menu builder with new value for description style

source

fn with_match_text_style(self, color: Style) -> Self

Menu builder with new value for match style This is the style of the part of the input text, the suggestions are based on

source

fn with_selected_match_text_style(self, color: Style) -> Self

Menu builder with new value for selected match style This is the style of the part of the input text, the suggestions are based on

source

fn with_marker(self, marker: &str) -> Self

Menu builder with new value for marker

source

fn with_only_buffer_difference(self, only_buffer_difference: bool) -> Self

Menu builder with new value for only_buffer_difference

Object Safety§

This trait is not object safe.

Implementors§