texlive[60965] trunk: tex4ebook (5nov21)

commits+karl at tug.org commits+karl at tug.org
Fri Nov 5 23:05:25 CET 2021


Revision: 60965
          http://tug.org/svn/texlive?view=revision&revision=60965
Author:   karl
Date:     2021-11-05 23:05:24 +0100 (Fri, 05 Nov 2021)
Log Message:
-----------
tex4ebook (5nov21)

Modified Paths:
--------------
    trunk/Build/source/texk/texlive/linked_scripts/tex4ebook/tex4ebook
    trunk/Master/texmf-dist/doc/support/tex4ebook/README
    trunk/Master/texmf-dist/doc/support/tex4ebook/changelog.tex
    trunk/Master/texmf-dist/doc/support/tex4ebook/readme.tex
    trunk/Master/texmf-dist/doc/support/tex4ebook/tex4ebook-doc.pdf
    trunk/Master/texmf-dist/scripts/tex4ebook/tex4ebook
    trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.4ht
    trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.sty

Modified: trunk/Build/source/texk/texlive/linked_scripts/tex4ebook/tex4ebook
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/tex4ebook/tex4ebook	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Build/source/texk/texlive/linked_scripts/tex4ebook/tex4ebook	2021-11-05 22:05:24 UTC (rev 60965)
@@ -67,7 +67,7 @@
 end
 
 if args.version then
-  print "tex4ebook v0.3e"
+  print "tex4ebook v0.3f"
   return 
 end
 

Modified: trunk/Master/texmf-dist/doc/support/tex4ebook/README
===================================================================
--- trunk/Master/texmf-dist/doc/support/tex4ebook/README	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/doc/support/tex4ebook/README	2021-11-05 22:05:24 UTC (rev 60965)
@@ -86,7 +86,7 @@
 `-e,--build-file (default nil)`  
 
 :    Specify make4ht build file^[https://github.com/michal-h21/make4ht#build-file].
-     Defaulf build file filename is `filename.mk4`, use this option if you use
+     Default build file filename is `filename.mk4`, use this option if you use
      different filename.
   
 `-f,--format (default epub)`

Modified: trunk/Master/texmf-dist/doc/support/tex4ebook/changelog.tex
===================================================================
--- trunk/Master/texmf-dist/doc/support/tex4ebook/changelog.tex	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/doc/support/tex4ebook/changelog.tex	2021-11-05 22:05:24 UTC (rev 60965)
@@ -3,6 +3,26 @@
 
 \begin{itemize}
 \item
+  2021/11/04
+
+  \begin{itemize}
+  \tightlist
+  \item
+    released version \texttt{0.3f}
+  \item
+    fixed spurious numbers in NCX TOC caused by wrong use of
+    \texttt{\textbackslash{}cs\_if\_exist\_use:cTF} command.
+  \end{itemize}
+\item
+  2021/10/08
+
+  \begin{itemize}
+  \tightlist
+  \item
+    fix for \texttt{\textbackslash{}author} support in \texttt{amsart}
+    class
+  \end{itemize}
+\item
   2021/09/30
 
   \begin{itemize}

Modified: trunk/Master/texmf-dist/doc/support/tex4ebook/readme.tex
===================================================================
--- trunk/Master/texmf-dist/doc/support/tex4ebook/readme.tex	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/doc/support/tex4ebook/readme.tex	2021-11-05 22:05:24 UTC (rev 60965)
@@ -101,7 +101,7 @@
 \begin{description}
 \item[\texttt{-e,-\/-build-file\ (default\ nil)}]
 Specify make4ht build file\footnote{\url{https://github.com/michal-h21/make4ht\#build-file}}.
-Defaulf build file filename is \texttt{filename.mk4}, use this option if
+Default build file filename is \texttt{filename.mk4}, use this option if
 you use different filename.
 \item[\texttt{-f,-\/-format\ (default\ epub)}]
 Output format. Possible values are \texttt{epub}, \texttt{epub3},

Modified: trunk/Master/texmf-dist/doc/support/tex4ebook/tex4ebook-doc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/scripts/tex4ebook/tex4ebook
===================================================================
--- trunk/Master/texmf-dist/scripts/tex4ebook/tex4ebook	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/scripts/tex4ebook/tex4ebook	2021-11-05 22:05:24 UTC (rev 60965)
@@ -67,7 +67,7 @@
 end
 
 if args.version then
-  print "tex4ebook v0.3e"
+  print "tex4ebook v0.3f"
   return 
 end
 

Modified: trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.4ht
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.4ht	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.4ht	2021-11-05 22:05:24 UTC (rev 60965)
@@ -231,8 +231,8 @@
 % Support for: chapter, section, subsection
 
 \def\resettoclevels#1{%
-  \def\do##1{\csgdef{nav##1finish}{}}
-  \docsvlist{#1}
+  \def\do##1{\csgdef{nav##1finish}{}}%
+  \docsvlist{#1}%
 }
 \def\usetoclevels#1{%
   \def\do##1{\csuse{nav##1finish}}%
@@ -239,21 +239,21 @@
   \docsvlist{#1}%
 }
 \def\finishtoclevel#1{%
-  \csgdef{nav#1finish}{\d:NavSection}
+  \csgdef{nav#1finish}{\d:NavSection}%
 }
 
-\def\closelevels#1{
-  \expandafter\usetoclevels\expandafter{#1}
-  \expandafter\resettoclevels\expandafter{#1}
-}
+\def\closelevels#1{%
+  \expandafter\usetoclevels\expandafter{#1}%
+  \expandafter\resettoclevels\expandafter{#1}%
+}%
 % 1 - section type 2 - closed sections 
 
-\def\navsection#1#2{
+\def\navsection#1#2{%
   \ConfigureToc{#1}%
-  {\expandafter\closelevels\expandafter{#2}
-  \def\curr:sect:type{#1}\a:NavSection\Ncx:Mark}
-  {\c:NavSection}
-  {}
+  {\expandafter\closelevels\expandafter{#2}%
+  \def\curr:sect:type{#1}\a:NavSection\Ncx:Mark}%
+  {\c:NavSection}%
+  {}%
   {\b:NavSection%
     \expandafter\finishtoclevel\expandafter{#1}%
   }
@@ -261,20 +261,20 @@
 
 % define closing groups for all levels defined in \Configure{resettoclevels}
 
-\def\tmp:processlevel#1{
-  \bgroup
-  \csxdef{tmp:resettoclevels#1}{}
-  \def\do##1{\csxdef{tmp:resettoclevels#1}{\csname tmp:resettoclevels#1\endcsname ##1,like##1,\appendix:type{##1}}}
-  \def\tmp:parse##1#1##2\nil{
-    \docsvlist{#1##2}
+\def\tmp:processlevel#1{%
+  \bgroup%
+  \csxdef{tmp:resettoclevels#1}{}%
+  \def\do##1{\csxdef{tmp:resettoclevels#1}{\csname tmp:resettoclevels#1\endcsname ##1,like##1,\appendix:type{##1}}}%
+  \def\tmp:parse##1#1##2\nil{%
+    \docsvlist{#1##2}%
   }
-  \expandafter\tmp:parse\a:resettoclevels\nil
-  \egroup
-  \navsection{#1}{\csname tmp:resettoclevels#1\endcsname}
+  \expandafter\tmp:parse\a:resettoclevels\nil%
+  \egroup%
+  \navsection{#1}{\csname tmp:resettoclevels#1\endcsname}%
   % define hierarchy also for starred sections
-  \navsection{like#1}{\csname tmp:resettoclevels#1\endcsname}
+  \navsection{like#1}{\csname tmp:resettoclevels#1\endcsname}%
   % and for appendices
-  \ifcsdef{appendix:type:#1}{\navsection{\csuse{appendix:type:#1}}{\csname tmp:resettoclevels#1\endcsname}}{}
+  \ifcsdef{appendix:type:#1}{\navsection{\csuse{appendix:type:#1}}{\csname tmp:resettoclevels#1\endcsname}}{}%
 }
 
 % define children levels for each sectioning level
@@ -289,9 +289,9 @@
 % so just strip then out
 % \TitleMark does similar thing, but this solution is simpler, I hope it works correctly
 \def\Ncx:Mark#1{%
-  \edef\:temp{#1}
-  \def\z at ro{0}
-  \ifx\:temp\z at ro\else#1\fi
+  \edef\:temp{#1}%
+  \def\z at ro{0}%
+  \ifx\:temp\z at ro\else#1\fi%
 }
 
 % to create correct hiearchical NCX for appendices, we register corresponding appendix types 
@@ -305,16 +305,16 @@
 
 %
 \def\ncx:head{%
-\HCode{<head>\Hnewline}
-\HCode{<meta name="dtb:uid" content="\a:UniqueIdentifier"/>\Hnewline}
-\HCode{<meta name="dtb:depth" content="3"/>\Hnewline}
-\HCode{<meta name="dtb:totalPageCount" content="0"/>\Hnewline}
-\HCode{<meta name="dtb:maxPageNumber" content="0"/>\Hnewline}
-\HCode{</head>\Hnewline}
+\HCode{<head>\Hnewline}%
+\HCode{<meta name="dtb:uid" content="\a:UniqueIdentifier"/>\Hnewline}%
+\HCode{<meta name="dtb:depth" content="3"/>\Hnewline}%
+\HCode{<meta name="dtb:totalPageCount" content="0"/>\Hnewline}%
+\HCode{<meta name="dtb:maxPageNumber" content="0"/>\Hnewline}%
+\HCode{</head>\Hnewline}%
 }
 
 \def\ncx:title{%
-  \HCode{<docTitle>\Hnewline<text>}\Title\HCode{</text>\Hnewline</docTitle>\Hnewline}
+  \HCode{<docTitle>\Hnewline<text>}\Title\HCode{</text>\Hnewline</docTitle>\Hnewline}%
 }
 
 % Get filename from tableofcontents anchor
@@ -326,16 +326,16 @@
 % the first number. we use the LaTeX 3 sequence list to get it.
 \tl_new:N\ncx:hfilename
 \def\ncx:newhfile#1{
-  \cs_if_exist_use:cTF{cw:)Q#1}{%
+  \cs_if_exist:cTF{cw:)Q#1}{%
     % cw:)Q#1 is csname of tag from the xref file. we convert it to sequence
-    \seq_set_from_clist:Nc\l_tmpa_seq{cw:)Q#1}
+    \seq_set_from_clist:Nc\l_tmpa_seq{cw:)Q#1}%
   % get first item and put it to a token list
-    \seq_get_left:NN \l_tmpa_seq \l_tmpa_tl
+    \seq_get_left:NN \l_tmpa_seq \l_tmpa_tl%
       % \RefFileNumber returns file name for the given file number
       % \ncx:hfilename contains the filename for later use
-      \tl_set:Nx \ncx:hfilename {\RefFileNumber{\l_tmpa_tl}}
-  }{%
-      \tl_set:Nn \ncx:hfilename {nic}
+      \tl_set:Nx \ncx:hfilename {\RefFileNumber{\l_tmpa_tl}}%
+  }{% This shouldn't happen?
+      \tl_set:Nn \ncx:hfilename {}%
   }
 }
 \ExplSyntaxOff
@@ -345,35 +345,35 @@
 \Configure{resettoclevels}{part,chapter,section,subsection,subsubsection,paragraph}
 
 \def\:tempa{%
-\EndP
-\HtmlParOff
-\setcounter{tocdepth}{3}
-\special{t4ht>\jobname.ncx}
+\EndP%
+\HtmlParOff%
+\setcounter{tocdepth}{3}%
+\special{t4ht>\jobname.ncx}%
 % We don't want crosslinks in xml
 % Basic sctructure of the ncx file
-\NoFonts
-{\HCode{<?xml version="1.0" encoding="utf-8"?>\Hnewline}}
-{\a:NcxDoctype}
-{\Tg<ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1">}{}
+\NoFonts%
+{\HCode{<?xml version="1.0" encoding="utf-8"?>\Hnewline}}%
+{\a:NcxDoctype}%
+{\Tg<ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1">}{}%
 % To print document map, we customize the tableofcontents. We don't want TOC title,
 % so:
-\let\contentsname=\empty
+\let\contentsname=\empty%
 \Configure{tableofcontents}{\boolfalse{tocnoempty}\Tg<navMap>}{%
 	\usetoclevels{part,appendix,chapter,likechapter,appendixsec,section,likesection,subsection,appendixsubsec,likesubsection,subsubsection,likesubsubsection,appendixsubsubsec,subsubsubsection,paragraph}%
 	\ifbool{tocnoempty}{}%
-	{\HCode{<navPoint id="mainentry" playOrder="1">
-	  <navLabel><text>Document</text></navLabel>
-	  <content src="\jobname.\:html" />
+	{\HCode{<navPoint id="mainentry" playOrder="1">%
+	  <navLabel><text>Document</text></navLabel>%
+	  <content src="\jobname.\:html" />%
 	  </navPoint>}}%
-	\Tg</navMap>}{}{}{}  
+	\Tg</navMap>}{}{}{}0
  % We need to configure TocLink
  % in navmapsrc is link to the file and anchor, where chapter or section is located
- \def\navmapsrc{}  
+ \def\navmapsrc{}%  
  \Configure{TocLink}{%
-   \ncx:newhfile{##2}
-   \def\navmapsrc{\ncx:hfilename\:sharp ##2}
-   \opf:registerfilename{\ncx:hfilename}
-   ##4
+   \ncx:newhfile{##2}%
+   \def\navmapsrc{\ncx:hfilename\:sharp ##2}%
+   \opf:registerfilename{\ncx:hfilename}%
+   ##4%
  }
  % Configuraion of entries
  \expandafter\resettoclevels\expandafter{\a:resettoclevels}%
@@ -386,14 +386,14 @@
 }{\HCode{</text>\Hnewline%
   </navLabel>\Hnewline}%
  \HCode{<content src="\navmapsrc" />}%
-}{\HCode{</navmark>}}{\HCode{</navPoint>\Hnewline}}
+}{\HCode{</navmark>}}{\HCode{</navPoint>\Hnewline}}%
 % Meta inf
-\ncx:head
+\ncx:head%
 % Book title
-\ncx:title
+\ncx:title%
 \tableofcontents[part,appendix,chapter,likechapter,appendixsec,section,likesection,appendixsubsec,subsection,likesubsection]%
 %Hack to get close tag working
-\HCode{</ncx>}
+\HCode{</ncx>}%
 \EndNoFonts
 \special{t4ht<\jobname.ncx}
  \HtmlParOn

Modified: trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.sty	2021-11-05 22:05:00 UTC (rev 60964)
+++ trunk/Master/texmf-dist/tex/latex/tex4ebook/tex4ebook.sty	2021-11-05 22:05:24 UTC (rev 60965)
@@ -166,4 +166,14 @@
 }
 %}
 
+
+% Fixes for AMS classess
+\AddToHook{class/after}{%
+  \ifx\authors\@empty%
+  \def\@maketitle at hook{
+  \global\let\Author\authors
+  }
+  \fi%
+}
+
 \newcommand\coverimage[2][]{\includegraphics[#1]{#2}}



More information about the tex-live-commits mailing list.