pub struct TocHeading {
pub depth: u8,
pub title: String,
pub anchor: String,
}Expand description
One heading, discovered from the pre-layout Element tree by
[prepare_toc] — everything a TableOfContents entry needs except
the page number (added later, pass 2 only, via LayoutCtx::toc_heading_pages).
Fields§
§depth: u8§title: String§anchor: StringEither the heading’s own Text::anchor, or a synthetic one
prepare_toc assigned (NUL-prefixed — not something an author can
type via a normal string literal, so it can never collide with a
real anchor name).
Trait Implementations§
Source§impl Clone for TocHeading
impl Clone for TocHeading
Source§fn clone(&self) -> TocHeading
fn clone(&self) -> TocHeading
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 moreAuto Trait Implementations§
impl Freeze for TocHeading
impl RefUnwindSafe for TocHeading
impl Send for TocHeading
impl Sync for TocHeading
impl Unpin for TocHeading
impl UnsafeUnpin for TocHeading
impl UnwindSafe for TocHeading
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