From 9dc9ec5939ad2e9ed648335fe8d9c050170bc3d6 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sat, 19 Feb 2022 21:31:24 +0000 Subject: disabled pdfx, tex4ht r1081 git-svn-id: svn://tug.org/texlive/trunk@62088 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/source/generic/tex4ht/ChangeLog | 10 ++++ .../source/generic/tex4ht/tex4ht-4ht.tex | 57 ++++++++++++++++++++-- .../texmf-dist/tex/generic/tex4ht/pdfx-hooks.4ht | 23 +++++++++ .../texmf-dist/tex/generic/tex4ht/usepackage.4ht | 5 +- 4 files changed, 89 insertions(+), 6 deletions(-) create mode 100644 Master/texmf-dist/tex/generic/tex4ht/pdfx-hooks.4ht diff --git a/Master/texmf-dist/source/generic/tex4ht/ChangeLog b/Master/texmf-dist/source/generic/tex4ht/ChangeLog index f6ae9d408dd..e051c4ff772 100644 --- a/Master/texmf-dist/source/generic/tex4ht/ChangeLog +++ b/Master/texmf-dist/source/generic/tex4ht/ChangeLog @@ -1,3 +1,13 @@ +2022-02-19 Michal Hoftich + + * 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 * tex4ht-html4.tex (html4.4ht): write CSS for table column width diff --git a/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex b/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex index 40696a0a643..8b2b3e86ace 100644 --- a/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex +++ b/Master/texmf-dist/source/generic/tex4ht/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 @@ -4657,6 +4657,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. + +\<<< +\Configure{PackageHooks}{pdfx.sty}{pdfx-hooks.4ht} +>>> + +\<<< +% pdfx-hooks.4ht (|version), generated from |jobname.tex +% Copyright 2022 TeX Users Group +| +\: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 | -% we don't have any code here for now +\:AtEndOfPackage{% | +| +} >>> \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. \<<< -\: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. + +\<<< +\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} +>>> \<<< diff --git a/Master/texmf-dist/tex/generic/tex4ht/pdfx-hooks.4ht b/Master/texmf-dist/tex/generic/tex4ht/pdfx-hooks.4ht new file mode 100644 index 00000000000..88963254623 --- /dev/null +++ b/Master/texmf-dist/tex/generic/tex4ht/pdfx-hooks.4ht @@ -0,0 +1,23 @@ +% pdfx-hooks.4ht (2022-02-19-13:30), generated from tex4ht-4ht.tex +% Copyright 2022 TeX Users Group +% +% This work may be distributed and/or modified under the +% 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 +% 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 . +% +% If you modify this program, changing the +% version identification would be appreciated. +\immediate\write-1{version 2022-02-19-13:30} + +\:dontusepackage{pdfx} +\endinput + diff --git a/Master/texmf-dist/tex/generic/tex4ht/usepackage.4ht b/Master/texmf-dist/tex/generic/tex4ht/usepackage.4ht index 87e14c8173a..c4cc5c514b9 100644 --- a/Master/texmf-dist/tex/generic/tex4ht/usepackage.4ht +++ b/Master/texmf-dist/tex/generic/tex4ht/usepackage.4ht @@ -1,4 +1,4 @@ -% usepackage.4ht (2022-02-10-13:40), generated from tex4ht-4ht.tex +% usepackage.4ht (2022-02-19-13:30), generated from tex4ht-4ht.tex % Copyright 2003-2009 Eitan M. Gurari % Copyright 2009-2022 TeX Users Group % @@ -17,7 +17,7 @@ % % If you modify this program, changing the % version identification would be appreciated. -\immediate\write-1{version 2022-02-10-13:40} +\immediate\write-1{version 2022-02-19-13:30} \def\:temp{tex4ht}\ifx \:temp\@currname \:warning{\string\usepackage{tex4ht} again?} @@ -61,6 +61,7 @@ \Configure{PackageHooks}{fontspec.sty}{fontspec-hooks.4ht} \Configure{PackageHooks}{tikz.sty}{tikz-hooks.4ht} \Configure{PackageHooks}{pdfbase.sty}{pdfbase-hooks.4ht} +\Configure{PackageHooks}{pdfx.sty}{pdfx-hooks.4ht} \Configure{PackageHooks}{breakurl.sty}{breakurl-hooks.4ht} \Configure{PackageHooks}{hyperref.sty}{hyperref-hooks.4ht} \Configure{PackageHooks}{caption.sty}{caption-hooks.4ht} -- cgit v1.2.3