summaryrefslogtreecommitdiff
path: root/support/tex4ebook
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-11-07 03:00:56 +0000
committerNorbert Preining <norbert@preining.info>2020-11-07 03:00:56 +0000
commitec3426946c37f270d71e8c4ad19d37beea726e7d (patch)
tree4f9a4ffaa8d056d3d160ba1be76408a2e20d6fb7 /support/tex4ebook
parentac4210da60306c356c4f9344b65e1f8345314267 (diff)
CTAN sync 202011070300
Diffstat (limited to 'support/tex4ebook')
-rw-r--r--support/tex4ebook/changelog.tex11
-rwxr-xr-xsupport/tex4ebook/tex4ebook2
-rw-r--r--support/tex4ebook/tex4ebook-doc.pdfbin79364 -> 79505 bytes
-rw-r--r--support/tex4ebook/tex4ebook-exec_epub.lua5
-rw-r--r--support/tex4ebook/tex4ebook-exec_epub3.lua1
5 files changed, 16 insertions, 3 deletions
diff --git a/support/tex4ebook/changelog.tex b/support/tex4ebook/changelog.tex
index f77423e85b..3d0d6c1c6c 100644
--- a/support/tex4ebook/changelog.tex
+++ b/support/tex4ebook/changelog.tex
@@ -3,6 +3,17 @@
\begin{itemize}
\item
+ 2020/11/06
+
+ \begin{itemize}
+ \tightlist
+ \item
+ bug fix: remove custom elements from the NCX file in the Epub 3
+ format.
+ \item
+ released version \texttt{0.3c}
+ \end{itemize}
+\item
2020/09/07
\begin{itemize}
diff --git a/support/tex4ebook/tex4ebook b/support/tex4ebook/tex4ebook
index dc602c4e72..91df031ffb 100755
--- a/support/tex4ebook/tex4ebook
+++ b/support/tex4ebook/tex4ebook
@@ -67,7 +67,7 @@ else
end
if args.version then
- print "tex4ebook v0.3b"
+ print "tex4ebook v0.3c"
return
end
diff --git a/support/tex4ebook/tex4ebook-doc.pdf b/support/tex4ebook/tex4ebook-doc.pdf
index 942a92df29..3546db973f 100644
--- a/support/tex4ebook/tex4ebook-doc.pdf
+++ b/support/tex4ebook/tex4ebook-doc.pdf
Binary files differ
diff --git a/support/tex4ebook/tex4ebook-exec_epub.lua b/support/tex4ebook/tex4ebook-exec_epub.lua
index b0ccee6202..75304e2494 100644
--- a/support/tex4ebook/tex4ebook-exec_epub.lua
+++ b/support/tex4ebook/tex4ebook-exec_epub.lua
@@ -393,12 +393,13 @@ local function fix_ncx_toc_levels(dom)
return dom
end
-local function clean_xml_files()
+function clean_xml_files()
local opf_file = outputdir .. "/content.opf"
update_file(opf_file, function(content)
-- remove wrong elements from the OPF file
-- open opf file and create LuaXML DOM
- local opf_dom = dom.parse(content)
+ -- the second argument to dom.parse is needed to avoid parsing issues due to the <meta> element.
+ local opf_dom = dom.parse(content, {})
-- remove child elements from elements that don't allow them
for _, el in ipairs(opf_dom:query_selector("dc|title, dc|creator")) do
-- get text content
diff --git a/support/tex4ebook/tex4ebook-exec_epub3.lua b/support/tex4ebook/tex4ebook-exec_epub3.lua
index 650eea4e6d..fc200bd866 100644
--- a/support/tex4ebook/tex4ebook-exec_epub3.lua
+++ b/support/tex4ebook/tex4ebook-exec_epub3.lua
@@ -273,6 +273,7 @@ function writeContainer()
log:info "write container"
eb.make_opf()
cleanOPF()
+ eb.clean_xml_files()
local ret = eb.pack_container()
return ret
end