Enum pandoc::PandocOption [−][src]
#[non_exhaustive]
pub enum PandocOption {
Show 83 variants
DataDir(PathBuf),
Defaults(PathBuf),
Strict,
ParseRaw,
Smart,
OldDashes,
BaseHeaderLevel(u32),
ShiftHeadingLevelBy(i32),
IndentedCodeClasses(String),
Filter(PathBuf),
LuaFilter(PathBuf),
Normalize,
PreserveTabs,
TabStop(u32),
TrackChanges(TrackChanges),
ExtractMedia(PathBuf),
Standalone,
Template(PathBuf),
Meta(String, Option<String>),
Var(String, Option<String>),
PrintDefaultTemplate(String),
PrintDefaultDataFile(PathBuf),
NoWrap,
Columns(u32),
TableOfContents,
TableOfContentsDepth(u32),
NoHighlight,
HighlightStyle(String),
IncludeInHeader(PathBuf),
IncludeBeforeBody(PathBuf),
IncludeAfterBody(PathBuf),
SelfContained,
Offline,
Html5,
HtmlQTags,
Ascii,
ReferenceLinks,
AtxHeaders,
TopLevelDivision(Tld),
NumberSections,
NumberOffset(Vec<u32>),
NoTexLigatures,
Listings,
Incremental,
SlideLevel(u32),
SectionDivs,
DefaultImageExtension(String),
EmailObfuscation(EmailObfuscation),
IdPrefix(String),
TitlePrefix(String),
Css(URL),
ReferenceOdt(PathBuf),
ReferenceDocx(PathBuf),
ReferenceDoc(PathBuf),
EpubStylesheet(PathBuf),
EpubCoverImage(PathBuf),
EpubMetadata(PathBuf),
EpubEmbedFont(PathBuf),
EpubChapterLevel(u32),
PdfEngine(PathBuf),
PdfEngineOpt(String),
Citeproc,
Bibliography(PathBuf),
Csl(PathBuf),
CitationAbbreviations(PathBuf),
Natbib,
Biblatex,
LatexMathML(Option<URL>),
AsciiMathML(Option<URL>),
MathML(Option<URL>),
MimeTex(Option<URL>),
WebTex(Option<URL>),
JsMath(Option<URL>),
MathJax(Option<URL>),
Katex(Option<URL>),
KatexStylesheet(URL),
GladTex,
Trace,
DumpArgs,
IgnoreArgs,
Verbose,
ResourcePath(Vec<PathBuf>),
RuntimeSystem(Vec<PandocRuntimeSystemOption>),
}
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
DataDir(PathBuf)
–data-dir=DIRECTORY
Tuple Fields of DataDir
0: PathBuf
Defaults(PathBuf)
–defaults=FILE
Tuple Fields of Defaults
0: PathBuf
–strict
-R –parse-raw
-S –smart
–old-dashes
BaseHeaderLevel(u32)
replaced by ShiftHeadingLevelBy
–base-header-level=NUMBER
Tuple Fields of BaseHeaderLevel
0: u32
replaced by ShiftHeadingLevelBy
ShiftHeadingLevelBy(i32)
–shift-heading-level-by=NUMBER,
Tuple Fields of ShiftHeadingLevelBy
0: i32
IndentedCodeClasses(String)
–indented-code-classes=STRING
Tuple Fields of IndentedCodeClasses
0: String
Filter(PathBuf)
-F PROGRAM –filter=PROGRAM
Tuple Fields of Filter
0: PathBuf
LuaFilter(PathBuf)
-L SCRIPT –lua-filter=SCRIPT
Tuple Fields of LuaFilter
0: PathBuf
–normalize
-p –preserve-tabs
TabStop(u32)
–tab-stop=NUMBER
Tuple Fields of TabStop
0: u32
TrackChanges(TrackChanges)
–track-changes=accept|reject|all
Tuple Fields of TrackChanges
0: TrackChanges
ExtractMedia(PathBuf)
–extract-media=PATH
Tuple Fields of ExtractMedia
0: PathBuf
-s –standalone
Template(PathBuf)
–template=FILENAME
Tuple Fields of Template
0: PathBuf
-M KEY[:VALUE] –metadata=KEY[:VALUE]
-V KEY[:VALUE] –variable=KEY[:VALUE]
PrintDefaultTemplate(String)
-D FORMAT –print-default-template=FORMAT
Tuple Fields of PrintDefaultTemplate
0: String
PrintDefaultDataFile(PathBuf)
–print-default-data-file=FILE
Tuple Fields of PrintDefaultDataFile
0: PathBuf
–no-wrap
Columns(u32)
–columns=NUMBER
Tuple Fields of Columns
0: u32
–toc, –table-of-contents
TableOfContentsDepth(u32)
–toc-depth=NUMBER
Tuple Fields of TableOfContentsDepth
0: u32
–no-highlight
HighlightStyle(String)
–highlight-style=STYLE
Tuple Fields of HighlightStyle
0: String
IncludeInHeader(PathBuf)
-H FILENAME –include-in-header=FILENAME
Tuple Fields of IncludeInHeader
0: PathBuf
IncludeBeforeBody(PathBuf)
-B FILENAME –include-before-body=FILENAME
Tuple Fields of IncludeBeforeBody
0: PathBuf
IncludeAfterBody(PathBuf)
-A FILENAME –include-after-body=FILENAME
Tuple Fields of IncludeAfterBody
0: PathBuf
–self-contained
–offline
-5 –html5
–html-q-tags
–ascii
–reference-links
–atx-headers
TopLevelDivision(Tld)
–top-level-division=
Tuple Fields of TopLevelDivision
0: Tld
-N –number-sections
–number-offset=NUMBERS
–no-tex-ligatures
–listings
-i –incremental
SlideLevel(u32)
–slide-level=NUMBER
Tuple Fields of SlideLevel
0: u32
–section-divs
DefaultImageExtension(String)
–default-image-extension=extension
Tuple Fields of DefaultImageExtension
0: String
EmailObfuscation(EmailObfuscation)
–email-obfuscation=none|javascript|references
Tuple Fields of EmailObfuscation
IdPrefix(String)
–id-prefix=STRING
Tuple Fields of IdPrefix
0: String
TitlePrefix(String)
-T STRING –title-prefix=STRING
Tuple Fields of TitlePrefix
0: String
Css(URL)
-c URL –css=URL
Tuple Fields of Css
0: URL
ReferenceOdt(PathBuf)
–reference-odt=FILENAME
Tuple Fields of ReferenceOdt
0: PathBuf
ReferenceDocx(PathBuf)
replaced by ReferenceDoc
–reference-docx=FILENAME
Tuple Fields of ReferenceDocx
0: PathBuf
replaced by ReferenceDoc
ReferenceDoc(PathBuf)
–reference-doc=FILENAME
Tuple Fields of ReferenceDoc
0: PathBuf
EpubStylesheet(PathBuf)
–epub-stylesheet=FILENAME
Tuple Fields of EpubStylesheet
0: PathBuf
EpubCoverImage(PathBuf)
–epub-cover-image=FILENAME
Tuple Fields of EpubCoverImage
0: PathBuf
EpubMetadata(PathBuf)
–epub-metadata=FILENAME
Tuple Fields of EpubMetadata
0: PathBuf
EpubEmbedFont(PathBuf)
–epub-embed-font=FILE
Tuple Fields of EpubEmbedFont
0: PathBuf
EpubChapterLevel(u32)
–epub-chapter-level=NUMBER
Tuple Fields of EpubChapterLevel
0: u32
PdfEngine(PathBuf)
–pdf-engine=PROGRAM
Tuple Fields of PdfEngine
0: PathBuf
PdfEngineOpt(String)
–pdf-engine-opt=STRING
Tuple Fields of PdfEngineOpt
0: String
–citeproc
Bibliography(PathBuf)
–bibliography=FILE
Tuple Fields of Bibliography
0: PathBuf
Csl(PathBuf)
–csl=FILE
Tuple Fields of Csl
0: PathBuf
CitationAbbreviations(PathBuf)
–citation-abbreviations=FILE
Tuple Fields of CitationAbbreviations
0: PathBuf
–natbib
–biblatex
-mURL –latexmathml[=URL], –asciimathml[=URL]
–asciimathml[=URL]
–mathml[=URL]
–mimetex[=URL]
–webtex[=URL]
–jsmath[=URL]
–mathjax[=URL]
–katex[=URL]
KatexStylesheet(URL)
–katex-stylesheet=URL
Tuple Fields of KatexStylesheet
0: URL
-gladtex
–trace
–dump-args
–ignore-args
–verbose
–resource-path=PATH
RuntimeSystem(Vec<PandocRuntimeSystemOption>)
+RTS OPTIONS -RTS
In Pandoc’s “A note on security” section of the manual (link), there is a recommendation to set a heap size limit to prevent pathological corner cases.
The full list of “RTS” options can be found in the Haskell “Runtime control” section of the manual (link). The Runtime System options are way more extensive than the -M option, and cover a lot of use-cases that aren’t needed while using pandoc in a production setting.
Example Usage
let mut pandoc = pandoc::new();
pandoc.add_option(pandoc::PandocOption::RuntimeSystem(vec![
// Limit the heap size to 512 MB while processing an arbitrary input file.
pandoc::PandocRuntimeSystemOption::MaximumHeapMemory("512M".to_string()),
]));
Tuple Fields of RuntimeSystem
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for PandocOption
impl Send for PandocOption
impl Sync for PandocOption
impl Unpin for PandocOption
impl UnwindSafe for PandocOption
Blanket Implementations
Mutably borrows from an owned value. Read more