pub trait StyleString {
// Required method
fn style(&self) -> StyledString<'_>;
// Provided method
fn apply_styles<'content>(
&'content self,
styles: &'content StylesContainer,
) -> StyledString<'content> { ... }
}Expand description
A trait meaning it can be converted into a styled string instead
Required Methods§
Sourcefn style(&self) -> StyledString<'_>
fn style(&self) -> StyledString<'_>
Converts the current type into a Styled String
Provided Methods§
Sourcefn apply_styles<'content>(
&'content self,
styles: &'content StylesContainer,
) -> StyledString<'content>
fn apply_styles<'content>( &'content self, styles: &'content StylesContainer, ) -> StyledString<'content>
Creates a styled string with the applied settings