#[non_exhaustive]pub struct MarkdownOptions {
pub include_headers: bool,
pub include_footers: bool,
pub page_separators: PageSeparators,
pub code: bool,
pub include_figures: bool,
pub table_render_mode: TableRenderMode,
}Expand description
Which blocks reach the Markdown, and how a change of page is marked.
The switches ExtractOptions carries for
PdfDocument::extract_markdown,
as the to_markdown_with_*_options functions below take them. Default is
today’s output: no furniture, and every page change a comment.
#[non_exhaustive], so a switch added here cannot break a caller that
never named it: start from Default and assign the fields you want.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.include_headers: boolWhether BlockKind::Header blocks are written as plain paragraphs
at their reading-order position. Default false: they are left out,
exactly as without the option. Never as headings: a running head is
not a section title.
Whether BlockKind::Footer blocks are written as plain paragraphs
at their reading-order position. Default false: they are left out,
exactly as without the option. Never as headings either.
page_separators: PageSeparatorsHow a change of page is marked. Default
PageSeparators::Comment: today’s <!-- page N --> marker.
code: boolWhether monospace runs reach the Markdown as code. Default true:
`like this` in a paragraph, a fenced block for a paragraph
set wholly in one. False restores the output from before code
existed, byte for byte.
include_figures: boolWhether figures are written as image references. Default true.
False writes no reference at all, the way the furniture reads without its switches.
table_render_mode: TableRenderModeHow tables reach the Markdown. Default TableRenderMode::Auto:
pipes where Markdown holds the table’s shape, HTML elsewhere –
today’s output, byte for byte.
Trait Implementations§
Source§impl Clone for MarkdownOptions
impl Clone for MarkdownOptions
impl Copy for MarkdownOptions
Source§impl Debug for MarkdownOptions
impl Debug for MarkdownOptions
Source§impl Default for MarkdownOptions
impl Default for MarkdownOptions
impl Eq for MarkdownOptions
Source§impl From<&ExtractOptions> for MarkdownOptions
impl From<&ExtractOptions> for MarkdownOptions
Source§fn from(options: &ExtractOptions) -> Self
fn from(options: &ExtractOptions) -> Self
The markdown half of an ExtractOptions:
what extract_markdown serializes with.
Source§impl PartialEq for MarkdownOptions
impl PartialEq for MarkdownOptions
impl StructuralPartialEq for MarkdownOptions
Auto Trait Implementations§
impl Freeze for MarkdownOptions
impl RefUnwindSafe for MarkdownOptions
impl Send for MarkdownOptions
impl Sync for MarkdownOptions
impl Unpin for MarkdownOptions
impl UnsafeUnpin for MarkdownOptions
impl UnwindSafe for MarkdownOptions
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
impl<T> CloneAny for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().