pub struct SpanAttributes {
pub font_family: Option<String>,
pub size: Option<String>,
pub foreground: Option<String>,
pub background: Option<String>,
pub weight: Option<String>,
pub style: Option<String>,
}Expand description
Attributes for a <span> inline markup tag.
Each field corresponds to a style attribute that can be specified on the
<span> tag. All fields are optional — only attributes present in the
source markup are populated.
Fields§
§font_family: Option<String>Font family name (e.g., "Serif", "Monospace").
size: Option<String>Font size (e.g., "12", "120%").
foreground: Option<String>Foreground (text) color (e.g., "red", "#FF0000").
background: Option<String>Background color (e.g., "yellow", "#FFFF00").
weight: Option<String>Font weight (e.g., "bold", "normal").
style: Option<String>Font style (e.g., "italic", "normal").
Trait Implementations§
Source§impl Clone for SpanAttributes
impl Clone for SpanAttributes
Source§fn clone(&self) -> SpanAttributes
fn clone(&self) -> SpanAttributes
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SpanAttributes
impl Debug for SpanAttributes
Source§impl Default for SpanAttributes
impl Default for SpanAttributes
Source§fn default() -> SpanAttributes
fn default() -> SpanAttributes
Returns the “default value” for a type. Read more
Source§impl PartialEq for SpanAttributes
impl PartialEq for SpanAttributes
impl Eq for SpanAttributes
impl StructuralPartialEq for SpanAttributes
Auto Trait Implementations§
impl Freeze for SpanAttributes
impl RefUnwindSafe for SpanAttributes
impl Send for SpanAttributes
impl Sync for SpanAttributes
impl Unpin for SpanAttributes
impl UnsafeUnpin for SpanAttributes
impl UnwindSafe for SpanAttributes
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