diff options
Diffstat (limited to 'support/TeX4ht/source')
-rw-r--r-- | support/TeX4ht/source/ChangeLog | 131 | ||||
-rw-r--r-- | support/TeX4ht/source/Makefile | 4 | ||||
-rw-r--r-- | support/TeX4ht/source/mktex4ht-cnf.tex | 6 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-4ht.tex | 241 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-cpright.tex | 4 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-env.tex | 17 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-fonts-noncjk.tex | 65 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-html4.tex | 82 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-jats.tex | 26 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-mathjax.tex | 24 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-mathml.tex | 204 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-ooffice.tex | 122 |
12 files changed, 870 insertions, 56 deletions
diff --git a/support/TeX4ht/source/ChangeLog b/support/TeX4ht/source/ChangeLog index 9c755d1d42..bf7907c9de 100644 --- a/support/TeX4ht/source/ChangeLog +++ b/support/TeX4ht/source/ChangeLog @@ -1,3 +1,134 @@ +2024-08-13 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (amsfonts.4ht): fixed support for \mathbb and + \mathfrak. + + * tex4ht-jats.tex (jats.4ht): added support for LaTeX + bibliographies. + +2024-08-11 Karl Berry <karl@freefriends.org> + + * tex4ht-mathml.tex (html-mml.4ht): copyright 2024. + +2024-08-02 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-mathml.tex (mathml.4ht): added "texsource" option. It will + keep the original LaTeX code as an annotation in MathML. + https://chat.stackexchange.com/rooms/154333/discussion-on-question-by-yannisl-alternatives-to-mathml-for-pdf-tagging + + * tex4ht-4ht.tex (esvect.4ht), + * tex4ht-mathml.tex (mathml.4ht): added support for the Esvect + package. + https://tex.stackexchange.com/a/723587/2891 + +2024-07-31 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-fonts-noncjk.tex ( + ./tex4ht.dir/texmf/tex4ht/ht-fonts/unicode/TeXvect10/vect10.htf + ): Added support for the vector font from the Esvect package. + https://tex.stackexchange.com/q/723560/2891 + +2024-07-28 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-mathjax.tex (mathjax-latex-4ht.4ht): don't add spaces after + LaTeX commands. + +2024-07-26 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (tagpdf-hooks.4ht, tagpdf-base-hooks.4ht): removed + \__tag_whatsits definitions, they fix is no longer necessary. + https://github.com/michal-h21/make4ht/issues/145#issuecomment-2085215582 + +2024-07-07 Karl Berry <karl@freefriends.org> + + * Makefile (tex4ht_env_derived), + * tex4ht-env.tex: no longer generate tex4ht.env, just + .env-unix and .env-win32, since those are the only ones we use. + +2024-07-06 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-html4.tex (html4.4ht): added itemize+ option. It will keep + original characters for itemize bullets. + https://tex.stackexchange.com/a/722062/2891 + +2024-07-03 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (fontawesome5.4ht): use icon name as the alt text. + +2024-06-21 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (arydshln.4ht): fixed clash between Colortbl and + Arydshln packages. + https://tex.stackexchange.com/a/721185/2891 + +2024-06-23 Karl Berry <karl@freefriends.org> + + * tex4ht-cpright.tex: https for urls. + +2024-06-21 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-html4.tex (html4.4ht): don't use picture name as alt in + \epsfbox, it can lead to spurious characters in the resulting HTML. + Thanks to Rolf Brigola + +2024-06-20 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (footmisc.4ht): fixed handling of footnote counter + reset. + https://tex.stackexchange.com/a/720989/2891 + + +2024-06-17 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (tabularray.4ht): updated names of token lists that + holds rowspan and colspan. + https://tex.stackexchange.com/a/720800/2891 + +2024-06-15 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (nameref.4ht): use \@currentlabelname if \NR:Title + is not set. + https://tex.stackexchange.com/a/720647/2891 + +2024-06-10 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (babel-sty-hooks.4ht): use \ProvideDocumentCommand + to define \:babelfont, in order to prevent errors if Babel is used + multiple times. + https://puszcza.gnu.org.ua/bugs/?626 + +2024-06-06 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (listings.4ht): fixed error with otherkeywords + style. + https://tex.stackexchange.com/a/719878/2891 + +2024-05-28 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-html4.tex (html4.4ht): renamed jurabib cofigurations to + jurabook. + + * tex4ht-4ht.tex (jurabook.4ht): fixed footnotes handling in + Jurabook. + https://github.com/michal-h21/make4ht/issues/148 + +2024-05-27 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-ooffice.tex (ooffice.4ht): added support for jurabook + sections and toc in the ODT format. + https://github.com/michal-h21/make4ht/issues/148 + + * tex4ht-4ht.tex (jurabook.4ht, juraovw.4ht, juraurtl.4ht), + * tex4ht-html4.tex (html4.4ht): added support for custom sectioning + commands provided by Jurabook. + https://github.com/michal-h21/make4ht/issues/148 + +2024-05-22 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (imakeidx.4ht): added support for the + \indexprologue command. + https://tex.stackexchange.com/a/714548/2891 + 2024-05-20 Michal Hoftich <michal.h21@gmail.com> * tex4ht-4ht.tex ( diff --git a/support/TeX4ht/source/Makefile b/support/TeX4ht/source/Makefile index fd6995f4a5..5328185f78 100644 --- a/support/TeX4ht/source/Makefile +++ b/support/TeX4ht/source/Makefile @@ -1,4 +1,4 @@ -# $Id: Makefile 1503 2024-04-18 22:51:03Z karl $ +# $Id: Makefile 1538 2024-07-07 15:55:16Z karl $ # This file is public domain. Originally written 2010, Karl Berry. # Assumes GNU make. @@ -138,7 +138,7 @@ tex4ht_docbook_xtpipes_derived = docbook.4xt $(wd)/src/DbUtilities.java endif derived += $(tex4ht_env_derived) -tex4ht_env_derived = tex4ht.env-unix tex4ht.env-win32 tex4ht.env +tex4ht_env_derived = tex4ht.env-unix tex4ht.env-win32 derived += $(tex4ht_fonts_cjk_derived) tex4ht_fonts_cjk_derived = \ diff --git a/support/TeX4ht/source/mktex4ht-cnf.tex b/support/TeX4ht/source/mktex4ht-cnf.tex index 9fdfe40b68..c57dbe1062 100644 --- a/support/TeX4ht/source/mktex4ht-cnf.tex +++ b/support/TeX4ht/source/mktex4ht-cnf.tex @@ -1,4 +1,4 @@ -% $Id: mktex4ht-cnf.tex 1502 2024-04-18 12:55:56Z michal_h21 $ +% $Id: mktex4ht-cnf.tex 1542 2024-08-02 14:58:42Z michal_h21 $ % Manually-maintained file, listing *.4ht files created by tex4ht-4ht.tex. % Read by tex4ht-cond4ht. % @@ -111,6 +111,9 @@ \AddFile{9}{scrbook} \AddFile{9}{scrartcl} \AddFile{9}{scrreprt} +\AddFile{9}{jurabook} +\AddFile{9}{juraurtl} +\AddFile{9}{juraovw} \AddFile{6}{letter} \AddFile{9}{elsart} \AddFile{9}{apa} @@ -412,4 +415,5 @@ \AddFile{9}{fontawesome5} \AddFile{9}{mhchem} \AddFile{9}{chemfig} +\AddFile{9}{esvect} % \AddFile{9}{mktex4ht} diff --git a/support/TeX4ht/source/tex4ht-4ht.tex b/support/TeX4ht/source/tex4ht-4ht.tex index c0a300cb01..7c0609dc17 100644 --- a/support/TeX4ht/source/tex4ht-4ht.tex +++ b/support/TeX4ht/source/tex4ht-4ht.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-4ht.tex 1521 2024-05-20 13:02:00Z michal_h21 $ +% $Id: tex4ht-4ht.tex 1546 2024-08-13 19:30:20Z michal_h21 $ % tex tex4ht-4ht or ht tex tex4ht-4ht % % Copyright 2009-2024 TeX Users Group @@ -3487,11 +3487,20 @@ configuration until now. It seems to be useful when we need to inject something into the environment without messing the existing \`|\ConfigureEnv| definitions. +% Michal 2024-06-15 +% I've added use of \a:newlabel{\@currentlabelname} if \NR:Type is empty. +% It seems to add support for name ref labels that are not supported yet +% We need to empty \NR:Type after \label. I hope this doesn't break anything. +% https://tex.stackexchange.com/a/720647/2891 + \<nameref v.2 configurations\><<< \let\NR:Type\relax \let\ltx@label\label -\def\prf:label{{\ifx \NR:Title\:UnDef \else \NR:Title\fi}% +\def\prf:label{{\ifx \NR:Title\:UnDef \a:newlabel{\@currentlabelname}\else \NR:Title\fi}% {\ifx \NR:Type\relax \else \NR:Type .1\fi}{}}% + +\append:defI\label{\let\NR:Title\undefined} + \let\NR:StartSec\:StartSec \let\NR:no@sect\no@sect \def\no@sect#1#2#3#4#5#6[#7]#8{\gdef\NR:Title{\a:newlabel{#7}}% @@ -4256,18 +4265,19 @@ icons to pictures by TeX4ht conversion. \<fontawesome5.4ht\><<< % fontawesome5.4ht (|version), generated from |jobname.tex -% Copyright 2021 TeX Users Group +% Copyright 2021-2024 TeX Users Group |<TeX4ht license text|> \NewConfigure{fontawesome}{2} \ExplSyntaxOn \cs_new_protected:Nn\temp:nn{% +\def\:fontawesomeicon{#2}% to be used in the alt text \a:fontawesome% \o:fontawesome_use_icon:nn:{#1}{#2} \b:fontawesome} \HLet\fontawesome_use_icon:nn\temp:nn \ExplSyntaxOff -\Configure{fontawesome}{\Picture+{}}{\EndPicture} +\Configure{fontawesome}{\Picture+[icon: \:fontawesomeicon]{}}{\EndPicture} \Hinput{fontawesome5} \endinput >>> \AddFile{9}{fontawesome5} @@ -5090,13 +5100,14 @@ as it leads to a fatal error. \Configure{PackageHooks}{tagpdf.sty}{tagpdf-hooks.4ht} >>> +% This is no longer useful, it was fixed in tagpdf code +% \cs_set_protected:Npn \__tag_whatsits: {} + \<tagpdf-hooks.4ht\><<< % tagpdf-hooks.4ht (|version), generated from |jobname.tex % Copyright 2022-2024 TeX Users Group |<TeX4ht license text|> \ExplSyntaxOn -% ignore tagpdf's specials -\cs_set_protected:Npn \__tag_whatsits: {} \ExplSyntaxOff \:AtEndOfPackage{% \RenewDocumentCommand \tagpdfsetup { m }{} @@ -5108,16 +5119,17 @@ as it leads to a fatal error. \Configure{PackageHooks}{tagpdf-base.sty}{tagpdf-base-hooks.4ht} >>> -This file can be used explicitly, we need to provide the whatsits command -here as well. +This file can be used explicitly, we used to provide the whatsits command +here as well, but it is no longer neeeded. + +% ignore tagpdf's specials +% we use csname, because \ExplSyntaxOn .. Off caused catcode issues +% \expandafter\def\csname __tag_whatsits:\endcsname{} \<tagpdf-base-hooks.4ht\><<< % tagpd-base-hooks.4ht (|version), generated from |jobname.tex % Copyright 2024 TeX Users Group |<TeX4ht license text|> -% ignore tagpdf's specials -% we use csname, because \ExplSyntaxOn .. Off caused catcode issues -\expandafter\def\csname __tag_whatsits:\endcsname{} \endinput >>> \AddFile{9}{tagpdf-base-hooks} @@ -11216,12 +11228,13 @@ compilation errors \<arydshln.4ht\><<< %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % arydshln.4ht (|version), generated from |jobname.tex -% Copyright 2022 TeX Users Group +% Copyright 2022-2024 TeX Users Group |<TeX4ht license text|> % this is a copy of code that arydshln inserts to \@array \def\:new:array{\adl@everyvbox\everyvbox \everyvbox{\adl@arrayinit \the\adl@everyvbox \everyvbox\adl@everyvbox}% - \ifadl@inactive \adl@inactivate \else \adl@activate \fi + % this line may lead to errors if the document uses Colortbl: + % \ifadl@inactive \adl@inactivate \else \adl@activate \fi \let\adl@noalign\noalign} \ifcsname n:@array:\endcsname% if \@array was already patched by TeX4ht \let\orig:n@array\n:@array: @@ -11335,7 +11348,7 @@ We need to load the tabularx package, because we use it instead of Tabu for actu \<tabularray.4ht\><<< % tabularray.4ht (|version), generated from |jobname.tex -% Copyright 2022-2023 TeX Users Group +% Copyright 2022-2024 TeX Users Group |<TeX4ht license text|> |<tabularray definitions|> |<tabularray table and rows|> @@ -11441,13 +11454,13 @@ for horizontal and vertical alignment, background color and rules. % find columns that are covered by rowspan and colspan \xdef\HCol{\@arabic\c@colnum} \xdef\HRow{\@arabic\c@rownum} - \xdef\HMultispan{\l__tblr_cell_colspan_tl} - \xdef\HRowspan{\l__tblr_cell_rowspan_tl} + \xdef\HMultispan{\lTblrCellColSpanTl} + \xdef\HRowspan{\lTblrCellRowSpanTl} \let\CellAttributes\@empty \let\CellStyle\@empty % calculate ignored cells, if the current cell uses colspan or rowspan - \int_step_inline:nnn{\c@rownum }{\c@rownum - 1 + \l__tblr_cell_rowspan_tl}{ - \int_step_inline:nnn{\c@colnum }{\c@colnum - 1 + \l__tblr_cell_colspan_tl}{ + \int_step_inline:nnn{\c@rownum }{\c@rownum - 1 + \lTblrCellRowSpanTl}{ + \int_step_inline:nnn{\c@colnum }{\c@colnum - 1 + \lTblrCellColSpanTl}{ % the loop always matches the current cell, we must ignore it \str_if_eq:eeF{\HCol.\HRow}{####1.##1}{% \cs_gset:cpn{ignoredcell-####1-##1}{} @@ -19223,6 +19236,119 @@ UnDFexyz}% \HtmlEnv \Toc:Title{#1}\:addchap{#2}} >>> +%%%%%%%%%%%%%%%%%% +\Chapter{juramisc} +%%%%%%%%%%%%%%%%%% + +Classes in the Juramisc bundle + +\<jurabook.4ht\><<< +% jurabook.4ht (|version), generated from |jobname.tex +% Copyright 2024 TeX Users Group +|<TeX4ht copywrite|> +|<jurabook subsections|> +|<jurabook toc|> +|<jurabook footnotes|> +\Hinput{jurabook} +>>> \AddFile{9}{jurabook} + +\<juraurtl.4ht\><<< +% juraurtl.4ht (|version), generated from |jobname.tex +% Copyright 2024 TeX Users Group +|<TeX4ht copywrite|> +\Hinput{juraurtl} +>>> \AddFile{9}{juraurtl} + +\<juraovw.4ht\><<< +% juraovw.4ht (|version), generated from |jobname.tex +% Copyright 2024 TeX Users Group +|<TeX4ht copywrite|> +\Hinput{juraovw} +>>> \AddFile{9}{juraovw} + +\Section{Jurabook sections} + +Jurabook defines lot of extra sectioning commands, so we need to +define them. Other than that, it reuses classic LaTeX classes, so +other sectioning commands should work out of the box. + +\<jurabook subsections\><<< +\let\no@subthreesection\subthreesection +\Def:Section\subthreesection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubthreesection \fi}{#1} +\let\no:subthreesection\subthreesection +\def\subthreesection{\rdef:sec{subthreesection}} + +\let\no@subfoursection\subfoursection +\Def:Section\subfoursection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubfoursection \fi}{#1} +\let\no:subfoursection\subfoursection +\def\subfoursection{\rdef:sec{subfoursection}} + +\let\no@subfivesection\subfivesection +\Def:Section\subfivesection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubfivesection \fi}{#1} +\let\no:subfivesection\subfivesection +\def\subfivesection{\rdef:sec{subfivesection}} + +\let\no@subsixsection\subsixsection +\Def:Section\subsixsection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubsixsection \fi}{#1} +\let\no:subsixsection\subsixsection +\def\subsixsection{\rdef:sec{subsixsection}} + + +\let\no@subsevensection\subsevensection +\Def:Section\subsevensection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubsevensection \fi}{#1} +\let\no:subsevensection\subsevensection +\def\subsevensection{\rdef:sec{subsevensection}} + + +\let\no@subeightsection\subeightsection +\Def:Section\subeightsection{\ifnum \c:secnumdepth>\c@secnumdepth \else + \thesubeightsection \fi}{#1} +\let\no:subeightsection\subeightsection +\def\subeightsection{\rdef:sec{subeightsection}} +>>> + +We need to include these sectionins in the TOC + +\<jurabook toc\><<< +\NewConfigure{tableofcontents*}[1]{% + \def\:tempa{#1}\ifx\empty\:tempa + \ifx \au:StartSec\:UnDef \else \gdef\:StartSec{\au:StartSec}\fi + \else + \edef\auto:toc{#1}% + \ifx \au:StartSec\:UnDef + \let\au:StartSec\:StartSec + \def\:StartSec{\:tableofcontents + \global\let\auto:toc\:UnDef \global\let\:StartSec\au:StartSec\:StartSec}% + \append:def\tableofcontents{\gdef\:StartSec{\au:StartSec}}% + \fi \fi +} + +\Configure{tableofcontents*}{part,chapter,section,subsection,subsubsection,subthreesection,subfoursection,subfivesection,subsixsection,subsevensection,subeightsection} +>>> + +This code is a copy from jurabook.cls. It rewrites the default version used by +Jurabook, which starts a list environment. This leads to HTML tag mismatches +and is unnecessary in general. + +The \`'\@makefntext' command will be redefined again in book.4ht, so we don't need to +insert TeX4ht hooks in this version. + +\<jurabook footnotes\><<< + \renewcommand{\@makefntext}[1]{% + \stepcounter{totalfootnotes}% + \renewcommand{\baselinestretch}{\@ne}% (nur) dieses hinzugefuegt fuer einzeilige Ausgabe + \parindent 1em% + \noindent% + \@infootnotetrue% + \hb@xt@1.8em{\hss\@makefnmark}#1% + \@infootnotefalse} +>>> + %%%%%%%%%%%%%%%%%%% \Chapter{letter} %%%%%%%%%%%%%%%%% @@ -22153,14 +22279,14 @@ $$ \<amsfonts sty\><<<< \NewConfigure{mathbb}{2} -\def\:temp#1{{\a:mathbb \o:@mathbb:{#1}\b:mathbb}} -\HLet\@mathbb\:temp +\def\:temp#1{{\a:mathbb \o:mathbb:{#1}\b:mathbb}} +\HLet\mathbb\:temp >>> \<amsfonts sty\><<<< \NewConfigure{mathfrak}{2} -\def\:temp#1{{\a:mathfrak \o:@mathfrak:{#1}\b:mathfrak}} -\HLet\@mathfrak\:temp +\def\:temp#1{{\a:mathfrak \o:mathfrak:{#1}\b:mathfrak}} +\HLet\mathfrak\:temp >>> Commands like \''\rm' need low level implemetation through @@ -24829,7 +24955,7 @@ Handle circumflex catcodes when the \Verb|early^| option is used. \<babel-sty-hooks.4ht\><<< % babel-sty-hooks.4ht, generated from |jobname.tex -% Copyright 2022 TeX Users Group +% Copyright 2022-2024 TeX Users Group |<TeX4ht license text|> |<disable early sup|> |<babelfont|> @@ -24841,7 +24967,7 @@ It can cause fatal errors, because it changes font encodings and can cause loating of OTF fonts \<babelfont\><<< -\NewDocumentCommand\:babelfont{o m o m}{} +\ProvideDocumentCommand\:babelfont{o m o m}{} \:AtEndOfPackage{% % disable \babelfont @@ -31284,6 +31410,20 @@ for output formats. \ExplSyntaxOff >>> +%%%%%%%%%%%%%%% +\Section{Esvect} +%%%%%%%%%%%%%%% + +\<esvect.4ht\><<< +% esvect.4ht (|version), generated from |jobname.tex +% Copyright 2024 TeX Users Group +|<TeX4ht license text|> +|<esvect redefinitions|> + +\Hinput{esvect} +\endinput +>>> \AddFile{9}{esvect} + %%%%%%%%%%%%% \Section{Ushort} %%%%%%%%%%%%% @@ -32569,10 +32709,10 @@ destination to the idx file \fi >>> -Support for the intoc option of Imakeidx: +Support for the intoc option of Imakeidx and the \`'\indexprologue' command. \<imakeidx.sty\><<< -\Configure{@begin}{theindex}{\ind:defs\imki@maybeaddtotoc} +\Configure{@begin}{theindex}{\ind:defs\imki@maybeaddtotoc\imki@idxprologue\global\let\imki@idxprologue\relax} >>> Prevent the automatic index compilation, the index produced by tex4ht @@ -33230,10 +33370,17 @@ content. \NewConfigure{listings-init}{2} >>> +Use the TextStyle hook to insert markup for inline listings. This hook can +be used also in other contexts, so we need to execute it conditionally, +based on the \Verb|\lst@ifmode| condition. +See \Link[https://tex.stackexchange.com/q/719828/2891]{}{}for example\EndLink. + \<listings sty\><<< \lst@AddToHook{TextStyle}{% \Configure{listings}{}{}{}{}% - \a:lstinline \bgroup \aftergroup\b:lstinline\aftergroup\egroup + \lst@ifmode\else% + \a:lstinline \bgroup \aftergroup\b:lstinline\aftergroup\egroup% + \fi% } \NewConfigure{lstinline}{2} >>> @@ -37771,9 +37918,39 @@ Use \<footmisc.4ht\><<< % footmisc.4ht (|version), generated from |jobname.tex -% Copyright 2019 TeX Users Group +% Copyright 2019-2024 TeX Users Group |<TeX4ht license text|> +|<footmisc footnote counter|> +|<footmisc footnotetext|> +|<footmisc symbols|> + + +\Hinput{footmisc} +\endinput +>>> \AddFile{9}{footmisc} +Footmisc can reset the normal footnote counter on every page. Footnote links are +then wrong, as they point to an earlier footnote. My solution is to use a global +counter that gives each footnote unique number and which doesn't rely on the footnote +symbol. + +\<footmisc footnote counter\><<< +\newcounter{:footnotes} + +\def\FNnum{\the\:footnotes} + +\HRestore\footnote + +\def\:tempc{% + \HAssign\FNnum = \csname c@:footnotes\endcsname% + \stepcounter{:footnotes}% + \HAdvance\FNnum by 1% + \o:footnote:% +} +\HLet\footnote=\:tempc +>>> + +\<footmisc footnotetext\><<< \long\def\@footnotetext#1{\leavevmode \vbox{%\IgnorePar \leftskip0pt {\ht:everypar{}\parindent0pt\leavevmode}% @@ -37792,6 +37969,9 @@ Use \color@endgroup \ht:special{t4ht@[}}\ht:special{t4ht@]}} +>>> + +\<footmisc symbols\><<< % detect if the symbol or symbol* option were used % we can detect that by testing of \thefootnote macro @@ -37808,10 +37988,7 @@ Use \newcommand\p@footmisc@footnote[1]{\p@footnote{#1}} \fi \fi - -\Hinput{footmisc} -\endinput ->>> \AddFile{9}{footmisc} +>>> %%%%%%%%%%%%%%% \Section{tablefootnote} diff --git a/support/TeX4ht/source/tex4ht-cpright.tex b/support/TeX4ht/source/tex4ht-cpright.tex index 3527690921..c15155fcc5 100644 --- a/support/TeX4ht/source/tex4ht-cpright.tex +++ b/support/TeX4ht/source/tex4ht-cpright.tex @@ -4,14 +4,14 @@ % conditions of the LaTeX Project Public License, either % version 1.3c of this license or (at your option) any % later version. The latest version of this license is in -% http://www.latex-project.org/lppl.txt +% https://www.latex-project.org/lppl.txt % and version 1.3c or later is part of all distributions % of LaTeX version 2005/12/01 or later. % % This work has the LPPL maintenance status "maintained". % % The Current Maintainer of this work -% is the TeX4ht Project <http://tug.org/tex4ht>. +% is the TeX4ht Project <https://tug.org/tex4ht>. % % If you modify this program, changing the % version identification would be appreciated.>>> diff --git a/support/TeX4ht/source/tex4ht-env.tex b/support/TeX4ht/source/tex4ht-env.tex index 5d66aa43d0..3ac0f4443d 100644 --- a/support/TeX4ht/source/tex4ht-env.tex +++ b/support/TeX4ht/source/tex4ht-env.tex @@ -1,8 +1,8 @@ -% $Id: tex4ht-env.tex 1419 2023-12-11 23:23:52Z karl $ +% $Id: tex4ht-env.tex 1538 2024-07-07 15:55:16Z karl $ % latex tex4ht-env % or htlatex tex4ht-env "xhtml,3" % -% Copyright 2009-2023 TeX Users Group +% Copyright 2009-2024 TeX Users Group % Copyright 1997-2009 Eitan M. Gurari % Released under LPPL 1.3c+. % See tex4ht-cpright.tex for license text. @@ -1650,27 +1650,30 @@ Note: the permission option `S' takes into account also trailing spaces. \<unix copyright\><<< % tex4ht.env-unix (@version), generated from @jobname.tex -% (can be used as ~/.tex4ht) -% Copyright 2009-2023 TeX Users Group +% Copyright 2009-2024 TeX Users Group % Copyright @CopyYear.1997. Eitan M. Gurari @<TeX4ht copyright@>>>> \<private copyright\><<< % tex4ht.env (private) (@version), generated from @jobname.tex % (can be used as ~/.tex4ht) -% Copyright 2009-2023 TeX Users Group +% Copyright 2009-2024 TeX Users Group % Copyright @CopyYear.1997. Eitan M. Gurari @<TeX4ht copyright@>>>> \<win32 copyright\><<< % tex4ht.env-win32 (@version), generated from @jobname.tex -% Copyright 2009-2023 TeX Users Group +% Copyright 2009-2024 TeX Users Group % Copyright @CopyYear.1997. Eitan M. Gurari @<TeX4ht copyright@>>>> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\OutputCode\<tex4ht\> +% Let's no longer create tex4ht.env; it's too easy to mistakenly update +% a system version with it. Post-Eitan, we haven't tried to keep it in +% sync with the others. +%\OutputCode\<tex4ht\> + \OutputCodE\<tex4ht.env-unix\> \OutputCodE\<tex4ht.env-win32\> diff --git a/support/TeX4ht/source/tex4ht-fonts-noncjk.tex b/support/TeX4ht/source/tex4ht-fonts-noncjk.tex index ae68aa34d5..0e22004638 100644 --- a/support/TeX4ht/source/tex4ht-fonts-noncjk.tex +++ b/support/TeX4ht/source/tex4ht-fonts-noncjk.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-fonts-noncjk.tex 1517 2024-05-10 11:27:42Z michal_h21 $ +% $Id: tex4ht-fonts-noncjk.tex 1541 2024-07-31 10:01:14Z michal_h21 $ % tex tex4ht-fonts-noncjk % or ht tex tex4ht-fonts-noncjk % @@ -24483,6 +24483,69 @@ fplmbb 49 90 +\Section{Esvect} + +Font file for the Esvect package. + +% writing vect10.htf hash: d9018d0b41b7639bd8c3bf0419c3b8a5 +\<vect10\><<< +vect10 0 47 +'`' '' grave 0 % generated from vect10.tfm, 2024-07-31-11:51 +'´' '' acute 1 % Copyright 2024 TeX Users Group +'ˆ' '' circumflex 2 % +'˜' '' tilde 3 % This work may be distributed and/or modified under the +'¨' '' dieresis 4 % conditions of the LaTeX Project Public License, either +'˝' '' hungarumlaut 5 % version 1.3c of this license or (at your option) any +'˚' '' ring 6 % later version. The latest version of this license is in +'ˇ' '' caron 7 % http://www.latex-project.org/lppl.txt +'˘' '' breve 8 % and version 1.3c or later is part of all distributions +'' '' % of LaTeX version 2005/12/01 or later. +'' '' % +'' '' % This work has the LPPL maintenance status "maintained". +'' '' % +'' '' % The Current Maintainer of this work +'' '' % is the TeX4ht Project <http://tug.org/tex4ht>. +'' '' % +'“' '' quotedblleft 16 % If you modify this program, changing the +'”' '' quotedblright 17 % version identification would be appreciated. +'„' '' quotedblbase 18 +'«' '' guillemotleft 19 +'»' '' guillemotright 20 +'–' '' endash 21 +'—' '' emdash 22 +'‌' '' cwm 23 +'‰' '' perthousand 24 +'' '' +'' '' +'' '' +'' '' +'' '' +'' '' +'' '' +' ' '' space 32 +'!' '' exclam 33 +'"' '' quotedbl 34 +'#' '' numbersign 35 +'$' '' dollar 36 +'%' '' percent 37 +'&' '' ampersand 38 +'’' '' quoteright 39 +'(' '' parenleft 40 +')' '' parenright 41 +'*' '' asterisk 42 +'+' '' plus 43 +',' '' comma 44 +'-' '' hyphen 45 +'.' '' period 46 +'/' '' slash 47 +vect10 0 47 +htfcss: vect10 font-family: 'TeXvect10', serif; + +>>> +\AddFont{vect10}{unicode/TeXvect10/vect10}{} + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/support/TeX4ht/source/tex4ht-html4.tex b/support/TeX4ht/source/tex4ht-html4.tex index 6f3e1402a4..13bf280c88 100644 --- a/support/TeX4ht/source/tex4ht-html4.tex +++ b/support/TeX4ht/source/tex4ht-html4.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-html4.tex 1518 2024-05-13 20:19:03Z michal_h21 $ +% $Id: tex4ht-html4.tex 1537 2024-07-06 19:48:42Z michal_h21 $ % Compile 4 times: latex tex4ht-html4 % Copy html4.4ht into the work directory before all but the last compilation. % @@ -2950,6 +2950,22 @@ such a case, we don't have proper nestings of environments. \EndP\HCode{</li></ul>}\ShowPar} {\end:itm \global\def\end:itm{\EndP\Tg</li>}\DeleteMark} {\HCode{<li class="\getClass{li}itemize">}\afterGetClass{li}|<list par|>} + +\:CheckOption{itemize+}\if:Option +\ConfigureList{itemize}% + {\EndP\HCode{<ul \a:LRdir + class="\getClass{itemize}itemize\expandafter\the + \csname @itemdepth\endcsname">}% + \afterGetClass{itemize}% + |<save end:itm|>\global\let\end:itm=\empty} + {|<recall end:itm|>\ifvmode \IgnorePar\fi + \EndP\HCode{</li></ul>}\ShowPar} + {\end:itm \global\def\end:itm{\EndP\Tg</li>}\HCode{<li class="\getClass{li}itemize"><span class="itemizeHead" aria-hidden="true">}\afterGetClass{li}} + {\HCode{</span>}|<list par|>} +\Css{.itemizeHead{float: left; margin-left: -1em; width: 1em;}} +\Css{li.itemize{list-style: none;}} +\fi + \NewConfigure{itemizeClass}{2} \Configure{itemizeClass}{}{} \NewConfigure{liClass}{2} @@ -9041,8 +9057,70 @@ The hbox is for avoiding the start of a new paragraph, if in vmode. +%%%%%%%%%%%%%%%%%% +\section{juramisc} +%%%%%%%%%%%%%%%%%% + +\<configure html4 jurabook\><<< +|<jurabook sections|> +|<jurabook toc|> +>>> + +\<configure html4 juraurtl\><<< +>>> + +\<configure html4 juraovw\><<< +>>> + +\<jurabook sections\><<< +\Configure{subthreesection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subthreesection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} +\ConfigureMark{subthreesection}{\HCode{<span class="titlemark">}\thesubthreesection\HCode{</span>}} +\Configure{subfoursection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subfoursection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} + +\ConfigureMark{subfoursection}{\HCode{<span class="titlemark">}\thesubfoursection\HCode{</span>}} + +\Configure{subfivesection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subfivesection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} + +\ConfigureMark{subfivesection}{\HCode{<span class="titlemark">}\thesubfivesection\HCode{</span>}} + +\Configure{subsixsection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subsixsection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} + +\ConfigureMark{subsixsection}{\HCode{<span class="titlemark">}\thesubsixsection\HCode{</span>}} + + +\Configure{subsevensection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subsevensection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} + +\ConfigureMark{subsevensection}{\HCode{<span class="titlemark">}\thesubsevensection\HCode{</span>}} + + +\Configure{subeightsection} + {}{} + {\ifvmode\IgnorePar\fi\EndP\HCode{<h5 class="subeightsection">}\TitleMark\space} {\HCode{</h5>}\par\ShowPar} + +\ConfigureMark{subeightsection}{\HCode{<span class="titlemark">}\thesubeightsection\HCode{</span>}} +>>> + +\<jurabook toc\><<< +\def\tocsubthreesection#1#2#3{\par\toc:num{subthreesection}{#1}{#2}\par} +\def\tocsubfoursection#1#2#3{\par\toc:num{subfoursection}{#1}{#2}\par} +\def\tocsubfivesection#1#2#3{\par\toc:num{subfivesection}{#1}{#2}\par} +\def\tocsubsixsection#1#2#3{\par\toc:num{subsixsection}{#1}{#2}\par} +\def\tocsubsevensection#1#2#3{\par\toc:num{subsevensection}{#1}{#2}\par} +\def\tocsubeightsection#1#2#3{\par\toc:num{subeightsection}{#1}{#2}\par} + +>>> %%%%%%%%%%%%%%%%%% \section{letter} @@ -13762,7 +13840,7 @@ for margin pars. \<configure html4 epsf\><<< \Configure{epsfsetgraph} - {\Picture+[\PicName]{}} + {\Picture+[]{}} {\EndPicture} >>> diff --git a/support/TeX4ht/source/tex4ht-jats.tex b/support/TeX4ht/source/tex4ht-jats.tex index e54de5ad20..16182ba8f5 100644 --- a/support/TeX4ht/source/tex4ht-jats.tex +++ b/support/TeX4ht/source/tex4ht-jats.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-jats.tex 1473 2024-02-23 12:26:51Z michal_h21 $ +% $Id: tex4ht-jats.tex 1545 2024-08-13 19:02:54Z michal_h21 $ % compile 3 times: latex tex4ht-jats % or xhlatex tex4ht-jats "html,3,sections+" % @@ -201,6 +201,7 @@ Configurations that are shared only for article and report |<latex footnotes|> |<latex quotes|> |<latex lists|> +|<latex bibliography|> >>> \<shared article,report\><<< @@ -841,6 +842,29 @@ them separatelly. {\EndNoFonts\HCode{</term><def>}\HtmlParOn|<list par|>} >>> + +We cannot create a structured bibliographic record for plain LaTeX references, so we +at least mark individual entries. + +Entry id is set on the label element. The id comes from a child xref element that is removed +by make4ht. Ideally, it should be set on ref, but we need to use label here, to catch +potential entry number. + + +\<latex bibliography\><<< +\ConfigureList{thebibliography}% + {\ifvmode\IgnorePar\fi \EndP \HCode{<ref-list>}\let\en:bib=\empty} + {\en:bib \ifvmode\IgnorePar\fi \EndP \HCode{</ref-list>}} + {\en:bib\def\en:bib{\HCode{</mixed-citation></ref>}}% + \HCode{<ref><label>}% + \Configure{HtmlPar}% + {\EndP}% + {\EndP}% + {} {}% + } + {\HCode{</label><mixed-citation>}} +>>> + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \chapter{Packages} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/support/TeX4ht/source/tex4ht-mathjax.tex b/support/TeX4ht/source/tex4ht-mathjax.tex index 23ca24a586..25f324ab7f 100644 --- a/support/TeX4ht/source/tex4ht-mathjax.tex +++ b/support/TeX4ht/source/tex4ht-mathjax.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-mathjax.tex 1474 2024-02-25 16:27:19Z karl $ +% $Id: tex4ht-mathjax.tex 1540 2024-07-28 17:10:17Z michal_h21 $ % compile: latex tex4ht-mathjax % % Copyright 2018-2024 TeX Users Group @@ -37,12 +37,14 @@ in LaTeX kernel now. \<required packages\><<< >>> -The \verb|\alteqtoks| command saves the used command in HTML. It uses detokenize command -to insert arguments verbatim. The side effect of this is that detokeize inserts space +The \verb|\alteqtoks| command prints the used LaTeX math code to the output document in +verbatim. + +In the past, we used \verb|\detokenize|. The side effect of this is that detokeize inserts space after each control sequence. This is completely valid TeX code, but earlier versions of MathJax didn't like that, rendering resulted in error. -Fortunatelly, MathJax 3 supports these spaces, so we can remove regular expressions for space handling. +Fortunatelly, MathJax 3 supports these spaces, so we could remove regular expressions for space handling. The original code was this: % % convert \ { to \:{ @@ -52,14 +54,24 @@ The original code was this: % % replace \\:{ back to \\ { -- this can be introduced by the previous regex % \regex_replace_all:nnN { \x{5C} \x{5C} \x{3A} \x{7B} } { \x{5C} \x{5C} \x{20} \x{7B} } \l_tmpa_tl +Now (July 2024), when I researched another issue, I've found that it is actually possible to avoid these +extra spaces using LaTeX 3 commands. The inspiration comes from +\Link[https://tex.stackexchange.com/a/44444/2891]this Bruno Le Foch\EndLink. +One ongoing issue is that newlines are not presented. But they weren't preserved with \verb|\detokenize| +either, so it shouldn't be a problem. + -We still use regula expressions to escape invalid XML characters to entities, so it works only with LaTeX. +We still use regular expressions to escape invalid XML characters to entities, so it works only with LaTeX. \<defined commands\><<< \ExplSyntaxOn \cs_new_protected:Npn \alteqtoks #1 { - \tl_set:Ne \l_tmpa_tl {\detokenize{#1}} + % save tokens, but preserve spaces + % https://tex.stackexchange.com/a/44444/2891 + \tl_set:Nn \l_tmpa_tl {#1} + \regex_replace_all:nnN { . } { \c{string} \0 } \l_tmpa_tl + \tl_set:Nx \l_tmpa_tl { \l_tmpa_tl } % % replace < > and & with xml entities \regex_replace_all:nnN { \x{26} } { & } \l_tmpa_tl \regex_replace_all:nnN { \x{3C} } { < } \l_tmpa_tl diff --git a/support/TeX4ht/source/tex4ht-mathml.tex b/support/TeX4ht/source/tex4ht-mathml.tex index e7f496d6bf..c8298dfadb 100644 --- a/support/TeX4ht/source/tex4ht-mathml.tex +++ b/support/TeX4ht/source/tex4ht-mathml.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-mathml.tex 1495 2024-03-21 16:39:31Z michal_h21 $$ +% $Id: tex4ht-mathml.tex 1543 2024-08-02 20:01:17Z michal_h21 $$ % compile 3 times: latex tex4ht-mathltx % or xhlatex tex4ht-mathltx "html,3,sections+" % @@ -1939,6 +1939,189 @@ primes. \fi >>> + +We may want to include LaTeX source as an annotation in MathML. In particular LaTeX PDF tagging code can use +this feature. We will not use it by default, but only with texsource option, as it can potentially +break some functionality. + +The code is based on the LaTeX MathJax code, but heavily modified. + +\<configure html-mml latex\><<< +\:CheckOption{texsource}\if:Option + +\newtoks\mmleqtoks +\ExplSyntaxOn +\cs_new_protected:Npn \mmlalteqtoks #1 +{ + % save tokens, but preserve spaces + % https://tex.stackexchange.com/a/44444/2891 + \tl_set:Nn \l_tmpa_tl {#1} + \regex_replace_all:nnN { . } { \c{string} \0 } \l_tmpa_tl + \tl_set:Nx \l_tmpa_tl { \l_tmpa_tl } + % % replace < > and & with xml entities + \regex_replace_all:nnN { \x{26} } { & } \l_tmpa_tl + \regex_replace_all:nnN { \x{3C} } { < } \l_tmpa_tl + \regex_replace_all:nnN { \x{3E} } { > } \l_tmpa_tl + % \regex_replace_all:nnN { \n } {\HCode{ \Hnewline }} \l_tmpa_tl + % replace \par command with blank lines + \regex_replace_all:nnN { \x{5C}par\b } {\x{A}\x{A}} \l_tmpa_tl + \tl_set:Nx \mmleqtoks{ \l_tmpa_tl } + + %\HCode{\l_tmpb_tl} +} +\ExplSyntaxOff + + +\def\AltMath#1${\mmlalteqtoks{#1}% + #1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$} +\Configure{$}{\Configure{@math}{display="inline"}\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}}{\HCode{</\a:mathml semantics>}\EndDviMath}{\expandafter\AltMath} + +\def\AltMathParen#1\){\mmlalteqtoks{#1}% + #1\HCode{</\a:mathml mrow><a\a:mathml nnotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$} + +\def\AltMathParen#1\){\mmlalteqtoks{#1}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}\)} +%\Configure{()}{\Configure{@math}{display="inline"}\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}\AltMathParen$}{\EndDviMath\HCode{</\a:mathml semantics>}} +\Configure{()} + {\Configure{@math}{%\a:mathml + display="inline" +}\csname a:mathml()\endcsname +\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}$\expandafter\AltMathParen} +{$\HCode{</\a:mathml semantics>}\EndDviMath\csname b:mathml()\endcsname} + + +\long\def\AltDisplay#1\]{\mmlalteqtoks{#1}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation></\a:mathml semantics>}\]} +\Configure{[]}{\Configure{@math}{display="block"}\DviMath$$\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow>}\AltDisplay}{$$\EndDviMath} + + +% \long\def\MMLAltlDisplayDollars#1$${\mmlalteqtoks{\[#1\]}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$$} + +% configuarartion of display math doesn't work yet. need to investigate it. +% \Configure{$$} +% {\Configure{@math}{%\a:mathml +% display="block" +% }\IgnorePar +% \ifvmode\else \HCode{<!--tex4ht:inline-->}\fi +% \EndP\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}} +% {\HCode{</\a:mathml semantics>}\EndDviMath\ShowPar\par{\csname HCondtrue\endcsname\noindent}} +% {\DisplayMathtrue\expandafter\MMLAltlDisplayDollars} + + +% \renewcommand\eqannotate[1]{\mmlalteqtoks{#1}\HCode{<\a:mathml semantics><\a:mathml mrow>}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation></\a:mathml semantics>}} + + +% environment support +\newcommand\MMLVerbMathToks[2]{% + \mmlalteqtoks{\begin{#2} + #1 + \end{#2}}% + \begingroup% + \ifvmode\IgnorePar\fi\EndP\Configure{@math}{display="block"}\DviMath\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow>} + \Configure{$$}{}{}{} + \begin{old#2} + #1 + \end{old#2} + \HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">} + \HCode{\mmleqtoks} + \HCode{</\a:mathml annotation></\a:mathml semantics>} + \EndDviMath + \endgroup +} + +% we must handle equations separatelly. +% it is a bit messy +\newcommand\MMLVerbMathToksEquation[2]{% + \mmlalteqtoks{\begin{#2} + #1 + \end{#2}}% + \begingroup% + \def\@tempa{#2}% + \def\@equationname{equation}% + \def\mlabeledtr{mtr} + \ifx\@equationname\@tempa% + \def\mlabeledtr{mlabeledtr} % this element can be used to print the equation number, but it is supported only by MathJax + \fi + \ifvmode\IgnorePar\fi\EndP\Configure{@math}{display="block"}\DviMath\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow><\a:mathml mtable><\a:mathml \mlabeledtr><\a:mathml mtd>}% + \ifx\@equationname\@tempa% + \incr@eqnum% + \print@eqnum% + \HCode{</\a:mathml mtd><\a:mathml mtd>}% + \fi + #1% + \HCode{</\a:mathml mtd></\a:mathml \mlabeledtr></\a:mathml mtable></\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">}% + \HCode{\mmleqtoks}% + \HCode{</\a:mathml annotation></\a:mathml semantics>}% + \EndDviMath% + \endgroup% +} + +\ExplSyntaxOn +\newcommand\MMLVerbMath[1]{% + \cs_if_exist:cTF{#1}{ + \expandafter\let\csname old#1\expandafter\endcsname\csname #1\endcsname + \expandafter\let\csname endold#1\expandafter\endcsname\csname end#1\endcsname + \RenewDocumentEnvironment{#1}{+!b}{% + \NoFonts\expandafter\MMLVerbMathToks\expandafter{##1}{#1}\EndNoFonts% + }{} + }{}% +} + +\newcommand\MMLVerbEquation[1]{% + \cs_if_exist:cTF{#1}{ + \expandafter\let\csname old#1\expandafter\endcsname\csname #1\endcsname + \expandafter\let\csname endold#1\expandafter\endcsname\csname end#1\endcsname + \RenewDocumentEnvironment{#1}{+!b}{% + \NoFonts\expandafter\MMLVerbMathToksEquation\expandafter{##1}{#1}\EndNoFonts% + }{} + }{}% +} +\ExplSyntaxOff + +% \MMLVerbEquation{equation} +% \MMLVerbEquation{equation*} + +\fi +>>> + +\<configure html-mml amsmath\><<< +\:CheckOption{texsource}\if:Option +\MMLVerbMath{subarray} +\MMLVerbMath{smallmatrix} +\MMLVerbMath{matrix} +\MMLVerbMath{pmatrix} +\MMLVerbMath{bmatrix} +\MMLVerbMath{Bmatrix} +\MMLVerbMath{vmatrix} +\MMLVerbMath{Vmatrix} +\MMLVerbMath{cases} +\MMLVerbMath{subequations} +\MMLVerbMath{aligned} +\MMLVerbMath{alignedat} +\MMLVerbMath{gathered} +\MMLVerbMath{gather} +\MMLVerbMath{gather*} +\MMLVerbMath{alignat} +\MMLVerbMath{alignat*} +\MMLVerbMath{xalignat} +\MMLVerbMath{xalignat*} +\MMLVerbMath{xxalignat} +\MMLVerbMath{align} +\MMLVerbMath{align*} +\MMLVerbMath{flalign} +\MMLVerbMath{flalign*} +\MMLVerbMath{split} +\MMLVerbMath{multline} +\MMLVerbMath{multline*} +% equations fails with errors, even though it worked in a .cfg +% I will need to investigate it more +% \MMLVerbEquation{equation} +% \MMLVerbEquation{equation*} +\MMLVerbMath{math} +\MMLVerbMath{displaymath} +\MMLVerbMath{eqnarray} +\MMLVerbMath{eqnarray*} +\fi +>>> + %%%%%%%%%%%%%%%%%%%%%%%%%% \subsection{plain.sty} %%%%%%%%%%%%%%%%%%%%%%%%%% @@ -5703,6 +5886,25 @@ elements that are printed to support the munderover element easily. >>> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\section{esvec} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +We need to redefine these commands only for MathML. By default, Esvect produces images, which is OK. + +\<configure mathml esvect\><<< +\def\:tempa#1{% + \bgroup\HCode{<\a:mathml mover><\a:mathml mrow>}#1\HCode{</\a:mathml mrow><\a:mathml mo>→</\a:mathml mo></\a:mathml mover>}\egroup +} + +\HLet\ESV@vecteur\:tempa +\def\:tempa#1#2{% + \ESV@vecteur{{#1}\sb{#2}} +} +\HLet\vvstar\:tempa + +>>> + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \chapter{Notes} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/support/TeX4ht/source/tex4ht-ooffice.tex b/support/TeX4ht/source/tex4ht-ooffice.tex index 65a79d3dcc..ed0a77f4ff 100644 --- a/support/TeX4ht/source/tex4ht-ooffice.tex +++ b/support/TeX4ht/source/tex4ht-ooffice.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-ooffice.tex 1455 2024-01-29 13:45:00Z michal_h21 $ +% $Id: tex4ht-ooffice.tex 1524 2024-05-27 19:41:45Z michal_h21 $ % compile 3 times: latex tex4ht-ooffice % htlatex tex4ht-ooffice "xhtml,4,sections+" % @@ -4620,6 +4620,81 @@ a more desirable for translations into MS Word. {\HCode{</text:h>\Hnewline}\par\ShowPar} >>> +\<jurabook sections\><<< +\ConfigureMark{subthreesection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subthreesection}\fi } +\Configure{subthreesection} + {\IgnorePar\EndP \HCode{<!--start of subthreesection-->}} + {\IgnorePar\EndP \HCode{<!--end of subthreesection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subthreesection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +\ConfigureMark{subfoursection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subfoursection}\fi } +\Configure{subfoursection} + {\IgnorePar\EndP \HCode{<!--start of subfoursection-->}} + {\IgnorePar\EndP \HCode{<!--end of subfoursection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subfoursection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +\ConfigureMark{subfivesection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subfivesection}\fi } +\Configure{subfivesection} + {\IgnorePar\EndP \HCode{<!--start of subfivesection-->}} + {\IgnorePar\EndP \HCode{<!--end of subfivesection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subfivesection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +\ConfigureMark{subsixsection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subsixsection}\fi } +\Configure{subsixsection} + {\IgnorePar\EndP \HCode{<!--start of subsixsection-->}} + {\IgnorePar\EndP \HCode{<!--end of subsixsection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subsixsection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +\ConfigureMark{subsevensection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subsevensection}\fi } +\Configure{subsevensection} + {\IgnorePar\EndP \HCode{<!--start of subsevensection-->}} + {\IgnorePar\EndP \HCode{<!--end of subsevensection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subsevensection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +\ConfigureMark{subeightsection} + {\ifnum \c:secnumdepth>\c@secnumdepth \expandafter\:gobble + \else \@seccntformat{subeightsection}\fi } +\Configure{subeightsection} + {\IgnorePar\EndP \HCode{<!--start of subeightsection-->}} + {\IgnorePar\EndP \HCode{<!--end of subeightsection-->}} + {\HCode{<text:h + text:style-name="\csname a:Heading-4|<cond rtl class|>\endcsname" + \text:outlinelevel="4" ><text:span + text:style-name="subeightsection" >}\TitleMark\space + \HCode{</text:span>}\IgnoreIndent} + {\HCode{</text:h>\Hnewline}\par\ShowPar} +>>> + @@ -5346,6 +5421,46 @@ Why we need the following in content.xml instead of styles.xml |<content style 8|>% >>> +\<jurabook tocs\><<< +\ConfigureToc{subthreesection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} + +\ConfigureToc{subfoursection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} +\ConfigureToc{subfivesection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} +\ConfigureToc{subsixsection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} +\ConfigureToc{subsevensection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} +\ConfigureToc{subeightsection} + {\HCode{<text:p text:style-name="P3" ><text:span + text:style-name="toc-mark" >}} + { \HCode{</text:span>}} + {} + {\HCode{</text:p>}} +>>> + %%%%%%%%%%%%% \subsection{Tables of Figures} @@ -9427,6 +9542,11 @@ fn\the\c@footnote x\minipageNum |<mwcls sections|> >>> +\<configure ooffice jurabook\><<< +|<jurabook sections|> +|<jurabook tocs|> +>>> + \<configure ooffice slides\><<< \Configure{maketitle} {\HCode{<!--begin maketitle-->}} |