pub struct ListMarkerStyle {
pub ordered_sequences: Vec<MarkerSequence>,
pub badge: bool,
pub badge_fill: ColorRgb,
pub badge_text_color: Option<ColorRgb>,
pub badge_scale: f32,
pub font_families: Vec<String>,
}Expand description
Styling for list-item markers. Bullets (unordered lists) are unaffected; these knobs shape ordered-list numbering and the optional circular badge treatment.
Fields§
§ordered_sequences: Vec<MarkerSequence>Ordered-list numbering style per nesting depth — index 0 is the
outermost list, deeper levels cycle through the list (wrapping
when the nesting runs deeper than the list). Empty means decimal
at every depth, e.g. ["decimal", "lower-alpha", "lower-roman"]
gives 1. → a. → i. as lists nest.
badge: boolDraw each ordered marker centred inside a filled circle. The
trailing . is dropped — the badge itself delimits the marker.
badge_fill: ColorRgbBadge fill colour.
badge_text_color: Option<ColorRgb>Marker text colour inside a badge. Defaults to the body text colour when unset.
badge_scale: f32Badge diameter as a multiple of the marker font size.
font_families: Vec<String>Font families for this element, in fallback order. Empty means
“inherit the document body families” (body_font_families, or
the bundled Noto defaults when that is also empty). Names must
be families the font collection knows — either system-installed
or exposed by a file listed in font_paths.
Note this REPLACES the body list rather than extending it, so a Latin-only face here will lose the multi-script fallbacks. List the scripts you need explicitly if the document is not Latin-only.
Implementations§
Source§impl ListMarkerStyle
impl ListMarkerStyle
Sourcepub fn sequence_for_depth(&self, depth: usize) -> MarkerSequence
pub fn sequence_for_depth(&self, depth: usize) -> MarkerSequence
The numbering style to use at the given nesting depth (0 = the outermost ordered list).
Trait Implementations§
Source§impl Clone for ListMarkerStyle
impl Clone for ListMarkerStyle
Source§impl Debug for ListMarkerStyle
impl Debug for ListMarkerStyle
Source§impl Default for ListMarkerStyle
impl Default for ListMarkerStyle
Source§impl<'de> Deserialize<'de> for ListMarkerStylewhere
ListMarkerStyle: Default,
impl<'de> Deserialize<'de> for ListMarkerStylewhere
ListMarkerStyle: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Forget for ListMarkerStyle
impl Freeze for ListMarkerStyle
impl Move for ListMarkerStyle
impl RefUnwindSafe for ListMarkerStyle
impl Send for ListMarkerStyle
impl Sync for ListMarkerStyle
impl Unpin for ListMarkerStyle
impl UnsafeUnpin for ListMarkerStyle
impl UnwindSafe for ListMarkerStyle
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
Source§fn to_owned_obj(&self, data: FontData<'_>) -> U
fn to_owned_obj(&self, data: FontData<'_>) -> U
T, using the provided data to resolve any offsets.