pub struct EpubExportOptions {
pub title: String,
pub author: String,
pub language: String,
pub rtl: bool,
pub images: ExportImages,
pub cover: Option<ExportImage>,
}Expand description
Book-level metadata for an EPUB export. Every field is required by the container format in
some form, so unlike super::docx_options::DocxExportOptions there is no “no overrides”
default that matches an unconfigured EPUB — Default instead picks the most reasonable
placeholders.
Fields§
§title: StringBook title, used for the package’s dc:title and (when a chapter has no heading of its
own — the front-matter chapter, or the whole document when it has no headings at all) as
that chapter’s title too.
Author name, used for the package’s dc:creator. Empty ⇒ no author is emitted.
language: StringBCP-47/ISO 639-1 language code (e.g. "en", "fr"), used for the package’s dc:language
and every chapter XHTML document’s xml:lang/lang. Empty ⇒ "en".
rtl: boolRight-to-left reading direction: sets the package’s page-progression-direction to rtl
and adds dir="rtl" to every chapter’s <html> element.
images: ExportImagesBytes for the book’s inline images, keyed by their src. Each one is
written into the package and listed in the OPF manifest; an image with no
entry here degrades to its alt text.
cover: Option<ExportImage>The book’s cover.
Separate from Self::images because a cover is not inline content: it
is never referenced by a src in the prose, it is marked in the OPF
manifest so a reader shows it in the library rather than mid-chapter, and
it gets a page of its own at the front of the book. None ⇒ no cover,
which is what every EPUB this crate produced before the field existed.
Trait Implementations§
Source§impl Clone for EpubExportOptions
impl Clone for EpubExportOptions
Source§fn clone(&self) -> EpubExportOptions
fn clone(&self) -> EpubExportOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more