pub struct RichTextStyle {
pub family: Option<String>,
pub size: Option<f64>,
pub weight: Option<String>,
pub style: Option<String>,
pub color: Option<Color>,
pub background: Option<Color>,
pub padding: Option<(f64, f64, f64, f64)>,
pub line_height: Option<f64>,
}Expand description
The style of one run inside a rich-text label.
Fields§
§family: Option<String>The font family list, as a CSS font-family value.
size: Option<f64>The font size, in pixels.
weight: Option<String>The font weight, as a CSS font-weight value.
style: Option<String>The font style, as a CSS font-style value.
color: Option<Color>The colour of the run.
background: Option<Color>The colour painted behind the run.
padding: Option<(f64, f64, f64, f64)>The padding between the run and its background.
line_height: Option<f64>The line height of the run, as a multiple of the font size.
Implementations§
Source§impl RichTextStyle
Inherent implementation of RichTextStyle.
impl RichTextStyle
Inherent implementation of RichTextStyle.
Trait Implementations§
Source§impl Clone for RichTextStyle
impl Clone for RichTextStyle
Source§impl Debug for RichTextStyle
impl Debug for RichTextStyle
Source§impl Default for RichTextStyle
Default construction for RichTextStyle.
impl Default for RichTextStyle
Default construction for RichTextStyle.
Source§fn default() -> Self
fn default() -> Self
Constructs a default RichTextStyle value.
Source§impl PartialEq for RichTextStyle
impl PartialEq for RichTextStyle
impl StructuralPartialEq for RichTextStyle
Auto Trait Implementations§
impl Freeze for RichTextStyle
impl RefUnwindSafe for RichTextStyle
impl Send for RichTextStyle
impl Sync for RichTextStyle
impl Unpin for RichTextStyle
impl UnsafeUnpin for RichTextStyle
impl UnwindSafe for RichTextStyle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more