summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/source/generic/tex4ht/ChangeLog5
-rw-r--r--Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex10
-rw-r--r--Master/texmf-dist/tex/generic/tex4ht/nameref.4ht12
3 files changed, 22 insertions, 5 deletions
diff --git a/Master/texmf-dist/source/generic/tex4ht/ChangeLog b/Master/texmf-dist/source/generic/tex4ht/ChangeLog
index 6322e06c8eb..8960d204526 100644
--- a/Master/texmf-dist/source/generic/tex4ht/ChangeLog
+++ b/Master/texmf-dist/source/generic/tex4ht/ChangeLog
@@ -1,3 +1,8 @@
+2022-06-27 Michal Hoftich <michal.h21@gmail.com>
+
+ * tex4ht-4ht.tex (nameref.4ht): disable \index and \label inside
+ \caption, to prevent fatal errors.
+
2022-06-24 Michal Hoftich <michal.h21@gmail.com>
* tex4ht-jats.4ht (jats.4ht): added support for pictures.
diff --git a/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex b/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex
index 0c2bd009132..f99c6fbd42b 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 1158 2022-06-21 15:56:07Z michal_h21 $
+% $Id: tex4ht-4ht.tex 1161 2022-06-27 10:03:53Z michal_h21 $
% tex tex4ht-4ht or ht tex tex4ht-4ht
%
% Copyright 2009-2022 TeX Users Group
@@ -3475,9 +3475,15 @@ definitions.
% \NR:Type threw an undefined control sequence error. I think
% \@currenvir is safe, there is nothing special about \@captype.
%
+% use of \index and \label inside caption results in a fatal error
+% we need to disable them in \NR:Title
\long\def\@caption#1[#2]{%
\gdef\NR:Type{\@currenvir}%
- \gdef\NR:Title{\a:newlabel{#2}}%
+ \begingroup%
+ \let\index\:gobble%
+ \let\label\:gobble%
+ \xdef\NR:Title{\a:newlabel{#2}}%
+ \endgroup%
\o:NR@@caption{#1}[{#2}]%
}
diff --git a/Master/texmf-dist/tex/generic/tex4ht/nameref.4ht b/Master/texmf-dist/tex/generic/tex4ht/nameref.4ht
index 870920095ec..264739db7bd 100644
--- a/Master/texmf-dist/tex/generic/tex4ht/nameref.4ht
+++ b/Master/texmf-dist/tex/generic/tex4ht/nameref.4ht
@@ -1,4 +1,4 @@
-% nameref.4ht (2022-04-13-13:14), generated from tex4ht-4ht.tex
+% nameref.4ht (2022-06-27-13:57), generated from tex4ht-4ht.tex
% Copyright 2005-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-04-13-13:14}
+\immediate\write-1{version 2022-06-27-13:57}
\let\NR:Type\relax
\let\ltx@label\label
@@ -86,9 +86,15 @@
% \NR:Type threw an undefined control sequence error. I think
% \@currenvir is safe, there is nothing special about \@captype.
%
+% use of \index and \label inside caption results in a fatal error
+% we need to disable them in \NR:Title
\long\def\@caption#1[#2]{%
\gdef\NR:Type{\@currenvir}%
- \gdef\NR:Title{\a:newlabel{#2}}%
+ \begingroup%
+ \let\index\:gobble%
+ \let\label\:gobble%
+ \xdef\NR:Title{\a:newlabel{#2}}%
+ \endgroup%
\o:NR@@caption{#1}[{#2}]%
}