aboutsummaryrefslogtreecommitdiff
path: root/pandoc-lua-engine/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <[email protected]>2023-01-12 09:01:56 -0800
committerJohn MacFarlane <[email protected]>2023-01-12 09:04:29 -0800
commitd7960212c0d3bf57659f5f6d3ad054eda2d20746 (patch)
tree97c92b385c5a136c267c9d611741add22494dd38 /pandoc-lua-engine/src/Text
parent2101dcf54ce5d3d2ecce300ca97dba47c5d61f02 (diff)
Replace `--epub-chapter-level` with `--split-level`.
Rationale: we need this splitting level now not just in EPUB but in chunked HTML. `--epub-chapter-level` will still function as a deprecated synonynm. `epub-chapter-level` will also continue to work in defaults files, ande `epub_chapter_level` will still work for Lua marshalling. [API changes] Text.Pandoc.App.Opt: remove `optEpubChapterLevel`, add `optSplitLevel`. Text.Pandoc.Options: remove `writerEpubChapterLevel`, add `writerSplitLevel`.
Diffstat (limited to 'pandoc-lua-engine/src/Text')
-rw-r--r--pandoc-lua-engine/src/Text/Pandoc/Lua/Marshal/WriterOptions.hs11
1 files changed, 8 insertions, 3 deletions
diff --git a/pandoc-lua-engine/src/Text/Pandoc/Lua/Marshal/WriterOptions.hs b/pandoc-lua-engine/src/Text/Pandoc/Lua/Marshal/WriterOptions.hs
index d08b7cc14..960972bed 100644
--- a/pandoc-lua-engine/src/Text/Pandoc/Lua/Marshal/WriterOptions.hs
+++ b/pandoc-lua-engine/src/Text/Pandoc/Lua/Marshal/WriterOptions.hs
@@ -75,10 +75,15 @@ typeWriterOptions = deftype "WriterOptions"
(pushViaJSON, writerEmailObfuscation)
(peekViaJSON, \opts x -> opts{ writerEmailObfuscation = x })
+ , property "split_level"
+ "Level at which EPUB or chunked HTML documents are split into files"
+ (pushIntegral, writerSplitLevel)
+ (peekIntegral, \opts x -> opts{ writerSplitLevel = x })
+
, property "epub_chapter_level"
- "Header level for chapters (separate files)"
- (pushIntegral, writerEpubChapterLevel)
- (peekIntegral, \opts x -> opts{ writerEpubChapterLevel = x })
+ "Deprecated synonym for split_level"
+ (pushIntegral, writerSplitLevel)
+ (peekIntegral, \opts x -> opts{ writerSplitLevel = x })
, property "epub_fonts"
"Paths to fonts to embed"