pub struct PaintHighlightSpan {
pub start: usize,
pub length: usize,
pub foreground_color: Option<Color>,
pub background_color: Option<Color>,
pub underline_color: Option<Color>,
pub underline_style: Option<UnderlineStyle>,
pub font_underline: Option<bool>,
pub font_overline: Option<bool>,
pub font_strikeout: Option<bool>,
}Expand description
A resolved paint-only highlight span for one character range of a block.
Char offsets are block-relative, matching HighlightSpan.
Each color field is None when the highlight does not override it. This is
the post-shape overlay counterpart of the merged-into-fragments path —
it carries only attributes that do not change glyph metrics.
Fields§
§start: usize§length: usize§foreground_color: Option<Color>§background_color: Option<Color>§underline_color: Option<Color>§underline_style: Option<UnderlineStyle>§font_underline: Option<bool>§font_overline: Option<bool>§font_strikeout: Option<bool>Trait Implementations§
Source§impl Clone for PaintHighlightSpan
impl Clone for PaintHighlightSpan
Source§fn clone(&self) -> PaintHighlightSpan
fn clone(&self) -> PaintHighlightSpan
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 PaintHighlightSpan
impl Debug for PaintHighlightSpan
Source§impl PartialEq for PaintHighlightSpan
impl PartialEq for PaintHighlightSpan
Source§fn eq(&self, other: &PaintHighlightSpan) -> bool
fn eq(&self, other: &PaintHighlightSpan) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for PaintHighlightSpan
impl StructuralPartialEq for PaintHighlightSpan
Auto Trait Implementations§
impl Freeze for PaintHighlightSpan
impl RefUnwindSafe for PaintHighlightSpan
impl Send for PaintHighlightSpan
impl Sync for PaintHighlightSpan
impl Unpin for PaintHighlightSpan
impl UnsafeUnpin for PaintHighlightSpan
impl UnwindSafe for PaintHighlightSpan
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