Struct tuirealm::props::builder::GenericPropsBuilder [−][src]
pub struct GenericPropsBuilder { /* fields omitted */ }
GenericPropsBuilder
This props builder exports methods to set values for all the possible properties.
In a normal case you shouldn’t use this builder, unless you can actually customize everything of your component.
For a Builder you should always implement only three traits: Default
, From<Props>
and PropsBuilder
, then you should implement
the setter methods for it, for the only properties you need for the associated component.
Implementations
impl GenericPropsBuilder
[src]
pub fn with_foreground(&mut self, color: Color) -> &mut Self
[src]
with_foreground
Set foreground color for component
pub fn with_background(&mut self, color: Color) -> &mut Self
[src]
with_background
Set background color for component
pub fn with_borders(
&mut self,
borders: Borders,
variant: BorderType,
color: Color
) -> &mut Self
[src]
&mut self,
borders: Borders,
variant: BorderType,
color: Color
) -> &mut Self
with_borders
Set component borders style
pub fn bold(&mut self) -> &mut Self
[src]
bold
Set bold property for component
pub fn italic(&mut self) -> &mut Self
[src]
italic
Set italic property for component
pub fn underlined(&mut self) -> &mut Self
[src]
underlined
Set underlined property for component
pub fn slow_blink(&mut self) -> &mut Self
[src]
slow_blink
Set slow_blink property for component
pub fn rapid_blink(&mut self) -> &mut Self
[src]
rapid_blink
Set rapid_blink property for component
pub fn reversed(&mut self) -> &mut Self
[src]
reversed
Set reversed property for component
pub fn strikethrough(&mut self) -> &mut Self
[src]
strikethrough
Set strikethrough property for component
pub fn with_texts(&mut self, texts: TextParts) -> &mut Self
[src]
with_texts
Set texts for component
pub fn with_input(&mut self, input_type: InputType) -> &mut Self
[src]
with_input
Set input type for component
pub fn with_input_len(&mut self, len: usize) -> &mut Self
[src]
with_input_len
Set max input len
pub fn with_custom_color(
&mut self,
name: &'static str,
color: Color
) -> &mut Self
[src]
&mut self,
name: &'static str,
color: Color
) -> &mut Self
with_custom_color
Set a custom color inside the color palette
pub fn with_value(&mut self, value: PropValue) -> &mut Self
[src]
with_value
Set initial value for component
Trait Implementations
impl Default for GenericPropsBuilder
[src]
impl From<Props> for GenericPropsBuilder
[src]
impl PropsBuilder for GenericPropsBuilder
[src]
Auto Trait Implementations
impl RefUnwindSafe for GenericPropsBuilder
impl Send for GenericPropsBuilder
impl Sync for GenericPropsBuilder
impl Unpin for GenericPropsBuilder
impl UnwindSafe for GenericPropsBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,