diff options
author | Norbert Preining <norbert@preining.info> | 2022-02-21 03:01:01 +0000 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2022-02-21 03:01:01 +0000 |
commit | a9409c96664c73e4fd0586f358845df19b1afd62 (patch) | |
tree | 21f96cdf0ef94f104e43ce589bd0837cd898ce0d /support/TeX4ht | |
parent | b7690ea2dcb14cafb49e6231940993e677bfc217 (diff) |
CTAN sync 202202210301
Diffstat (limited to 'support/TeX4ht')
-rw-r--r-- | support/TeX4ht/source/ChangeLog | 10 | ||||
-rw-r--r-- | support/TeX4ht/source/tex4ht-4ht.tex | 57 |
2 files changed, 63 insertions, 4 deletions
diff --git a/support/TeX4ht/source/ChangeLog b/support/TeX4ht/source/ChangeLog index f6ae9d408d..e051c4ff77 100644 --- a/support/TeX4ht/source/ChangeLog +++ b/support/TeX4ht/source/ChangeLog @@ -1,3 +1,13 @@ +2022-02-19 Michal Hoftich <michal.h21@gmail.com> + + * tex4ht-4ht.tex (hyperref-hooks.4ht): define autoref captions, so + they are available in the preamble. + https://tex.stackexchange.com/q/634043/2891 + + * tex4ht-4ht.tex (usepackage.4ht, pdfx-hooks.4ht): disable loading + of the Pdfx package. + https://tex.stackexchange.com/q/634043/2891 + 2022-02-16 Michal Hoftich <michal.h21@gmail.com> * tex4ht-html4.tex (html4.4ht): write CSS for table column width diff --git a/support/TeX4ht/source/tex4ht-4ht.tex b/support/TeX4ht/source/tex4ht-4ht.tex index 40696a0a64..8b2b3e86ac 100644 --- a/support/TeX4ht/source/tex4ht-4ht.tex +++ b/support/TeX4ht/source/tex4ht-4ht.tex @@ -1,4 +1,4 @@ -% $Id: tex4ht-4ht.tex 1079 2022-02-16 21:13:48Z michal_h21 $ +% $Id: tex4ht-4ht.tex 1082 2022-02-19 21:28:26Z michal_h21 $ % tex tex4ht-4ht or ht tex tex4ht-4ht % % Copyright 2009-2022 TeX Users Group @@ -4658,6 +4658,25 @@ The pdfbase package redefines \`|\@outputpage| macro, which causes tex4ht patche >>> \AddFile{9}{pdfbase-hooks} %%%%%%%%%%%%%%%%% +\Section{pdfx.sty} +%%%%%%%%%%%%%%%%% + +The pdfx package causes fatal error for TeX4ht. As it's features make sense only in the +PDF mode, it is safest thing to do to just disable the package. + +\<add to usepackage\><<< +\Configure{PackageHooks}{pdfx.sty}{pdfx-hooks.4ht} +>>> + +\<pdfx-hooks.4ht\><<< +% pdfx-hooks.4ht (|version), generated from |jobname.tex +% Copyright 2022 TeX Users Group +|<TeX4ht license text|> +\:dontusepackage{pdfx} +\endinput +>>> \AddFile{9}{pdfx-hooks} + +%%%%%%%%%%%%%%%%% \Section{animate.sty} %%%%%%%%%%%%%%%%% @@ -5162,8 +5181,10 @@ We can load nameref from the early hook file % hyperref-hooks.4ht (|version), generated from |jobname.tex % Copyright 2021 TeX Users Group |<TeX4ht license text|> -% we don't have any code here for now +\:AtEndOfPackage{% |<load nameref in hyperref hooks|> +|<define autoref captions|> +} >>> \AddFile{9}{hyperref-hooks} We need to load Nameref here, otherwise lot of documents @@ -5175,7 +5196,6 @@ and then revert to it's original definition before applying of TeX4ht hooks. \<load nameref in hyperref hooks\><<< -\:AtEndOfPackage{% \@ifpackageloaded{nameref}{} {% \RequirePackage{ifthen}% @@ -5183,9 +5203,38 @@ TeX4ht hooks. \RequirePackage{nameref}% \let\label\sv:label %\input nameref.4ht -}} +} >>> +Hyperref defines following captions at the end of the package. +The problem is that Hyperref detects TeX4ht, and stops its +loading too early, before the captions are declared. +They are available in the document, but not in the preamble. +This can result in compilation errors if user tries to redefine +one of these captions in the preamble. + +\<define autoref captions\><<< +\providecommand*\AMSautorefname{\equationautorefname} +\providecommand*\Hfootnoteautorefname{\footnoteautorefname} +\providecommand*\Itemautorefname{\itemautorefname} +\providecommand*\itemautorefname{item} +\providecommand*\equationautorefname{Equation} +\providecommand*\footnoteautorefname{footnote} +\providecommand*\itemautorefname{item} +\providecommand*\figureautorefname{Figure} +\providecommand*\tableautorefname{Table} +\providecommand*\partautorefname{Part} +\providecommand*\appendixautorefname{Appendix} +\providecommand*\chapterautorefname{chapter} +\providecommand*\sectionautorefname{section} +\providecommand*\subsectionautorefname{subsection} +\providecommand*\subsubsectionautorefname{subsubsection} +\providecommand*\paragraphautorefname{paragraph} +\providecommand*\subparagraphautorefname{subparagraph} +\providecommand*\FancyVerbLineautorefname{line} +\providecommand*\theoremautorefname{Theorem} +\providecommand*\pageautorefname{page} +>>> \<nameref moved from old hyperref\><<< |