texlive[61505] Master/texmf-dist: adjustbox and tcolorbox fixes,
commits+karl at tug.org
commits+karl at tug.org
Thu Jan 6 01:23:06 CET 2022
Revision: 61505
http://tug.org/svn/texlive?view=revision&revision=61505
Author: karl
Date: 2022-01-06 01:23:06 +0100 (Thu, 06 Jan 2022)
Log Message:
-----------
adjustbox and tcolorbox fixes, tex4ht 1047, 1048
Modified Paths:
--------------
trunk/Master/texmf-dist/source/generic/tex4ht/ChangeLog
trunk/Master/texmf-dist/source/generic/tex4ht/Makefile
trunk/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex
trunk/Master/texmf-dist/tex/generic/tex4ht/adjustbox.4ht
trunk/Master/texmf-dist/tex/generic/tex4ht/tcolorbox.4ht
Modified: trunk/Master/texmf-dist/source/generic/tex4ht/ChangeLog
===================================================================
--- trunk/Master/texmf-dist/source/generic/tex4ht/ChangeLog 2022-01-06 00:21:59 UTC (rev 61504)
+++ trunk/Master/texmf-dist/source/generic/tex4ht/ChangeLog 2022-01-06 00:23:06 UTC (rev 61505)
@@ -1,3 +1,13 @@
+2022-01-05 Michal Hoftich <michal.h21 at gmail.com>
+
+ * tex4ht-4ht.tex (adjustbox.4ht): prevent undefined control
+ sequences with Adjusbox.
+
+2022-01-04 Michal Hoftich <michal.h21 at gmail.com>
+
+ * tex4ht-4ht.tex (tcolorbox.4ht): fixed conflict with updated
+ Tcolorbox package.
+
2022-01-02 Karl Berry <karl at freefriends.org>
* tex4ht-4ht.tex (ifthen.4ht, url.4ht): use |<TeX4ht copywrite>
Modified: trunk/Master/texmf-dist/source/generic/tex4ht/Makefile
===================================================================
--- trunk/Master/texmf-dist/source/generic/tex4ht/Makefile 2022-01-06 00:21:59 UTC (rev 61504)
+++ trunk/Master/texmf-dist/source/generic/tex4ht/Makefile 2022-01-06 00:23:06 UTC (rev 61505)
@@ -1,4 +1,4 @@
-# $Id: Makefile 936 2021-05-16 16:21:01Z karl $
+# $Id: Makefile 1039 2021-12-25 21:56:53Z karl $
# This file is public domain. Originally written 2010, Karl Berry.
# Assumes GNU make.
@@ -106,7 +106,7 @@
fontspec.4ht fontspec-4ht.lua fontspec-luatex.4ht fontspec-xetex.4ht \
footmisc.4ht framed.4ht frenchb.4ht floatpag.4ht \
geometry.4ht graphics.4ht graphicx.4ht \
- hyperref.4ht \
+ hyperref.4ht hyperxmp.4ht \
imakeidx.4ht \
jurabib.4ht \
latex.4ht lettrine.4ht listings.4ht longtable.4ht \
@@ -193,8 +193,8 @@
derived += $(tex4ht_fonts_ebgaramond_derived)
tex4ht_fonts_ebgaramond_derived = \
- $(ht_fonts_devdir)/unicode/EB_Garamond/EBGaramond-Regular-lf-swash-t1.htf \
- $(ht_fonts_devdir)/alias/EB_Garamond/EBGaramond-Bold-lf-titling-t1.htf
+ $(ht_fonts_devdir)/unicode/EB_Garamond_Regular/EBGaramond-Regular-lf-t1.htf \
+ $(ht_fonts_devdir)/alias/EB_Garamond_Bold/EBGaramond-Bold-osf-t1.htf
derived += $(tex4ht_fonts_libertine_derived)
tex4ht_fonts_libertine_derived = \
@@ -211,6 +211,11 @@
derived += $(tex4ht_fonts_spectral_derived)
tex4ht_fonts_spectral_derived = \
$(ht_fonts_devdir)/unicode/Spectral/Spectral-Regular-lf-sc-ly1.htf
+
+derived += $(tex4ht_fonts_kpfonts_derived)
+tex4ht_fonts_kpfonts_derived = \
+ $(ht_fonts_devdir)/unicode/Kp-Light-M-Syd/jkplsyd.htf
+
# xx and many more
# whither tmp? how change target dir? what happened to cmtex.htf? etc.
@@ -241,7 +246,7 @@
derived += $(tex4ht_html4_derived)
tex4ht_html4_derived = \
- html4.4ht html4-math.4ht html4-uni.4ht \
+ html4.4ht html4-math.4ht \
html4-l2-url.4ht html4-russian-accents.4ht \
onmouseover.4ht exerqz.4ht
@@ -426,6 +431,9 @@
$(tex4ht_fonts_spectral_derived): tex4ht-fonts-spectral.tex
$(HTTEX) $< ""
+$(tex4ht_fonts_kpfonts_derived): tex4ht-fonts-kpfonts.tex
+ $(HTTEX) $< ""
+
# requires more memory than configured in other tex programs.
$(tex4ht_fonts_4hf): tex4ht-fonts-4hf.tex
dvilualatex $<
@@ -710,6 +718,7 @@
# Perl scripts (mk4ht) at present.
#
diff-scripts:
+ @echo; echo '>>> $@'
for f in *.unix; do \
inst_f=$(inst_dir_scripts)/`basename $$f .unix`.sh; \
test -r $$inst_f || continue; \
@@ -717,6 +726,7 @@
# Diff from installed to dev, but install from dev to installed.
install-scripts:
+ @echo; echo '>>> $@'
for f in *.unix; do \
inst_f=$(inst_dir_scripts)/`basename $$f .unix`.sh; \
test -r $$inst_f || continue; \
@@ -764,9 +774,12 @@
diff-htfonts:
# put the raw diff in /tmp/htd:
-$(diff) -r $(ht_fonts_instdir) $(ht_fonts_devdir) >/tmp/htd
-# just the filenames in htf:
- sed -n 's,^diff.*ht-fonts/,,p' /tmp/htd |sort >/tmp/htf
-# new files in htnew:
+# just the changed filenames in /tmp/htf; but this includes date changes,
+# so will have lots of false matches. must fixx ...
+# also we don't ever remove $(ht_fonts_instdir), so old stuff stays
+# around; must fixx again.
+ sed -n 's,^diff.*ht-fonts/,,p' /tmp/htd | sort >/tmp/htf
+# and new filenames in /tmp/htnew:
sed -n -e 's,^Only in.*ht-fonts/,,' \
-e 's,: ,/,p' /tmp/htd >/tmp/htnew
# for human consumption, remove generation lines (hopefully there are no
@@ -786,9 +799,11 @@
# The diff-scripts output is usually empty, so we can run that;
# but diff-htfonts is too verbose to run every time.
diff-all: diff-scripts #diff-htfonts
+ @echo; echo '>>> $@'
-for f in $(inst_dir_4ht)/*; do $(diff) $$f .; done \
| tee /tmp/u | egrep -v '^ *[-+]%|^@@ |^- *$$|-1.version' \
- | egrep -v '^..ifx.infoIVht.UnDeF.*//$$'
+ | egrep -v '^..ifx.infoIVht.UnDeF.*//$$' \
+ | egrep -v '^--- '
# For checking the derived files that are explicitly listed above
# against installed (in TL) files. This is a small subset of all the
@@ -797,6 +812,7 @@
mk4ht.perl ht.unix ht.bat,\
$(derived))
diff-derived:
+ @echo; echo '>>> $@'
-for f in $(diff_files); do $(diff) $(inst_dir_4ht)/$$f .; done \
| tee /tmp/u | egrep -v '^ *[-+]%|^@@ |^- *$$|-1.version' \
| egrep -v '^..ifx.infoIVht.UnDeF.*//$$'
@@ -804,7 +820,7 @@
# Check that anything with a \version of this year
# also has a copyright of this year.
inst-check-copyright:
- @echo '>>> $@'
+ @echo; echo '>>> $@'
-cd $(inst_dir_4ht) && for f in *; do \
if grep "version.*`date +%Y`" $$f >/dev/null; then \
grep "Copyright.*`date +%Y`" $$f >/dev/null || echo $$f; fi; done
@@ -812,7 +828,7 @@
# Check that all *.4ht in dev are installed. Other file types are
# difficult, but all 4ht's should be present, except mktex4ht.4ht.
inst-check-files:
- @echo '>>> $@'
+ @echo; echo '>>> $@'
cd $(inst_dir_4ht) && ls -1 *.4ht >/tmp/instlist
ls -1 *.4ht | fgrep -v mktex4ht.4ht >/tmp/devlist
comm -3 /tmp/devlist /tmp/instlist
@@ -819,7 +835,7 @@
# Check for missing version identifications.
inst-check-version:
- @echo '>>> $@'
+ @echo; echo '>>> $@'
-cd $(inst_dir_4ht) && for f in *; do \
grep 'write-1.*version' $$f >/dev/null || echo $$f; done
@@ -832,6 +848,11 @@
diff = diff -u0 --ignore-all-space --ignore-blank-lines \
--ignore-matching-lines='write-1.version\|, generated from\|Copyright'
+# run weekly by karl.
+croncheck: diff-all \
+ inst-check-copyright inst-check-files inst-check-version \
+ diff-htfonts
+
# final simple abbrev for convenience.
upmake upm:
svn update && make
Modified: trunk/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex
===================================================================
--- trunk/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex 2022-01-06 00:21:59 UTC (rev 61504)
+++ trunk/Master/texmf-dist/source/generic/tex4ht/tex4ht-4ht.tex 2022-01-06 00:23:06 UTC (rev 61505)
@@ -1,4 +1,4 @@
-% $Id: tex4ht-4ht.tex 1046 2022-01-02 22:32:28Z karl $
+% $Id: tex4ht-4ht.tex 1048 2022-01-05 13:16:37Z michal_h21 $
% tex tex4ht-4ht or ht tex tex4ht-4ht
%
% Copyright 2009-2022 TeX Users Group
@@ -26949,7 +26949,7 @@
% use custom counter that increments for every \tcolorbox
\newcounter{:tcbcolcount}
-\def\tcb at drawcolorbox{%
+\def\:tempa{%
\stepcounter{:tcbcolcount}%
% save text and background colors for use in CSS
\get:xcolorcss{tcbcolbacktitle}\:tcbcolbacktitle%
@@ -26979,13 +26979,21 @@
\box\tcb at lowerbox%
\b:tcolorlowerbox%
\fi%
- % close box
- \d:tcolorbox%
+ % We need to close box in \tcb at endboxanddraw
}
+\HLet\tcb at drawcolorbox\:tempa
% overwrite other versions of box drawing macros
-\let\tcb at drawcolorbox@standalone\tcb at drawcolorbox
+\HLet\tcb at drawcolorbox@standalone\:tempa
+% we need to close tcolorbox environment here,
+% in the box. otherwise, last paragraph end
+% would be ignored and we would get invalid XML
+\def\:tempb{\d:tcolorbox\o:tcb at endboxanddraw:}
+\HLet\tcb at endboxanddraw\:tempb
+
+
+
\NewConfigure{tcolorbox}{4}
\NewConfigure{tcolorlowerbox}{2}
@@ -26996,12 +27004,8 @@
}
\HLet\tcb at set@label\:tempa
+|<tcolorbox minipage|>
-% this is a trick to fix issues with paragraphs
-% spurious end </p> tags were inserted
-\def\tcb at minipage#1{\SaveEndP\vbox\bgroup\par}
-\def\endtcb at savebox{\EndP\egroup\RecallEndP}
-
\Hinput{tcolorbox}
\endinput
@@ -27009,6 +27013,17 @@
>>> \AddFile{9}{tcolorbox}
+
+this is a trick to fix issues with paragraphs
+where spurious end \`'</p>' tags were inserted
+\<tcolorbox minipage\><<<
+\pend:def\tcb at minipage{\SaveEndP}
+\pend:def\tcb at minipage@top{\SaveEndP}
+\pend:def\tcb at minipage@bottom{\SaveEndP}
+\pend:def\tcb at minipage@center{\SaveEndP}
+
+>>>
+
%%%%%%%%%%%%%%%%%%%%%%%
\Section{dvipsnam}
%%%%%%%%%%%%%%%%%%%%%%%
@@ -31245,7 +31260,9 @@
\def\update:adjustbox:id{\stepcounter{adjustbox at 4ht}\def\AdjustboxId{adjustbox-\arabic{adjustbox at 4ht}}}
\NewConfigure{Adjustbox}{2}
-\def\:tempa#1#2#3#4{\update:adjustbox:id\a:Adjustbox\o:adjbox@@frame:{#1}{#2}{#3}{#4}\b:Adjustbox}
+
+\def\:tempa#1#2#3#4{\update:adjustbox:id\a:Adjustbox\o:adjbox@@frame:{#1}{#2}{#3}{#4}\b:Adjustbox
+}
\HLet\adjbox@@frame\:tempa
% suppress trying to draw the frame
@@ -31254,15 +31271,27 @@
% patch macro that collects adjustbox contents and draw box. we disable this functionality, as all
% of this should be handled by CSS
% keys are set, so it should be possible to extract colors or frame size in theory
-\long\def\:temp#1#2{\update:adjustbox:id\adjbox at setkeys{#1}\a:Adjustbox #2\b:Adjustbox\endgroup}
+\long\def\:temp#1#2{%
+ % copy of definitions from \@adjustbox, to prevent compilation errors
+ \edef\adjbox at line{\the\inputlineno}%
+ \let\collectbox at mode\relax
+ \let\collectbox at noindent\relax
+ \let\adjbox at collectbox\@collectbox
+ \let\adjbox at begininnercode\@empty
+ \let\adjbox at endinnercode\@empty
+ \chardef\adjbox at innerlevel\z@
+ \update:adjustbox:id\adjbox at setkeys{#1}\a:Adjustbox #2\b:Adjustbox\endgroup}
\HLet\@adjustbox\:temp
% definitions for macros
% we don't save any colors and just use one configuration for all box types.
-\def\@bgcolorbox#1{\update:adjustbox:id\a:Adjustbox\BOXCONTENT\b:Adjustbox}
-\def\@foregroundbox#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
-\def\@backgroundbox#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\def\:tempa#1{\update:adjustbox:id\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@bgcolorbox\:tempa
+\def\:tempa#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@foregroundbox\:tempa
+\def\:tempa#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@backgroundbox\:tempa
\Hinput{adjustbox}
\endinput
Modified: trunk/Master/texmf-dist/tex/generic/tex4ht/adjustbox.4ht
===================================================================
--- trunk/Master/texmf-dist/tex/generic/tex4ht/adjustbox.4ht 2022-01-06 00:21:59 UTC (rev 61504)
+++ trunk/Master/texmf-dist/tex/generic/tex4ht/adjustbox.4ht 2022-01-06 00:23:06 UTC (rev 61505)
@@ -1,4 +1,4 @@
-% adjustbox.4ht (2021-11-26-13:53), generated from tex4ht-4ht.tex
+% adjustbox.4ht (2022-01-05-16:22), generated from tex4ht-4ht.tex
% Copyright 2019-2021 TeX Users Group
%
% This work may be distributed and/or modified under the
@@ -16,7 +16,7 @@
%
% If you modify this program, changing the
% version identification would be appreciated.
-\immediate\write-1{version 2021-11-26-13:53}
+\immediate\write-1{version 2022-01-05-16:22}
\NewConfigure{AdjustboxValignTop}{1}
\NewConfigure{AdjustboxValignMiddle}{1}
@@ -36,7 +36,9 @@
\def\update:adjustbox:id{\stepcounter{adjustbox at 4ht}\def\AdjustboxId{adjustbox-\arabic{adjustbox at 4ht}}}
\NewConfigure{Adjustbox}{2}
-\def\:tempa#1#2#3#4{\update:adjustbox:id\a:Adjustbox\o:adjbox@@frame:{#1}{#2}{#3}{#4}\b:Adjustbox}
+
+\def\:tempa#1#2#3#4{\update:adjustbox:id\a:Adjustbox\o:adjbox@@frame:{#1}{#2}{#3}{#4}\b:Adjustbox
+}
\HLet\adjbox@@frame\:tempa
% suppress trying to draw the frame
@@ -45,15 +47,27 @@
% patch macro that collects adjustbox contents and draw box. we disable this functionality, as all
% of this should be handled by CSS
% keys are set, so it should be possible to extract colors or frame size in theory
-\long\def\:temp#1#2{\update:adjustbox:id\adjbox at setkeys{#1}\a:Adjustbox #2\b:Adjustbox\endgroup}
+\long\def\:temp#1#2{%
+ % copy of definitions from \@adjustbox, to prevent compilation errors
+ \edef\adjbox at line{\the\inputlineno}%
+ \let\collectbox at mode\relax
+ \let\collectbox at noindent\relax
+ \let\adjbox at collectbox\@collectbox
+ \let\adjbox at begininnercode\@empty
+ \let\adjbox at endinnercode\@empty
+ \chardef\adjbox at innerlevel\z@
+ \update:adjustbox:id\adjbox at setkeys{#1}\a:Adjustbox #2\b:Adjustbox\endgroup}
\HLet\@adjustbox\:temp
% definitions for macros
% we don't save any colors and just use one configuration for all box types.
-\def\@bgcolorbox#1{\update:adjustbox:id\a:Adjustbox\BOXCONTENT\b:Adjustbox}
-\def\@foregroundbox#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
-\def\@backgroundbox#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\def\:tempa#1{\update:adjustbox:id\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@bgcolorbox\:tempa
+\def\:tempa#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@foregroundbox\:tempa
+\def\:tempa#1#2#3{\update:adjustbox:id\leavevmode\a:Adjustbox\BOXCONTENT\b:Adjustbox}
+\HLet\@backgroundbox\:tempa
\Hinput{adjustbox}
\endinput
Modified: trunk/Master/texmf-dist/tex/generic/tex4ht/tcolorbox.4ht
===================================================================
--- trunk/Master/texmf-dist/tex/generic/tex4ht/tcolorbox.4ht 2022-01-06 00:21:59 UTC (rev 61504)
+++ trunk/Master/texmf-dist/tex/generic/tex4ht/tcolorbox.4ht 2022-01-06 00:23:06 UTC (rev 61505)
@@ -1,4 +1,4 @@
-% tcolorbox.4ht (2021-11-24-13:48), generated from tex4ht-4ht.tex
+% tcolorbox.4ht (2022-01-05-16:22), generated from tex4ht-4ht.tex
% Copyright 2020-2021 TeX Users Group
%
% This work may be distributed and/or modified under the
@@ -16,13 +16,13 @@
%
% If you modify this program, changing the
% version identification would be appreciated.
-\immediate\write-1{version 2021-11-24-13:48}
+\immediate\write-1{version 2022-01-05-16:22}
% use custom counter that increments for every \tcolorbox
\newcounter{:tcbcolcount}
-\def\tcb at drawcolorbox{%
+\def\:tempa{%
\stepcounter{:tcbcolcount}%
% save text and background colors for use in CSS
\get:xcolorcss{tcbcolbacktitle}\:tcbcolbacktitle%
@@ -52,13 +52,21 @@
\box\tcb at lowerbox%
\b:tcolorlowerbox%
\fi%
- % close box
- \d:tcolorbox%
+ % We need to close box in \tcb at endboxanddraw
}
+\HLet\tcb at drawcolorbox\:tempa
% overwrite other versions of box drawing macros
-\let\tcb at drawcolorbox@standalone\tcb at drawcolorbox
+\HLet\tcb at drawcolorbox@standalone\:tempa
+% we need to close tcolorbox environment here,
+% in the box. otherwise, last paragraph end
+% would be ignored and we would get invalid XML
+\def\:tempb{\d:tcolorbox\o:tcb at endboxanddraw:}
+\HLet\tcb at endboxanddraw\:tempb
+
+
+
\NewConfigure{tcolorbox}{4}
\NewConfigure{tcolorlowerbox}{2}
@@ -69,12 +77,13 @@
}
\HLet\tcb at set@label\:tempa
+\pend:def\tcb at minipage{\SaveEndP}
+\pend:def\tcb at minipage@top{\SaveEndP}
+\pend:def\tcb at minipage@bottom{\SaveEndP}
+\pend:def\tcb at minipage@center{\SaveEndP}
-% this is a trick to fix issues with paragraphs
-% spurious end </p> tags were inserted
-\def\tcb at minipage#1{\SaveEndP\vbox\bgroup\par}
-\def\endtcb at savebox{\EndP\egroup\RecallEndP}
+
\Hinput{tcolorbox}
\endinput
More information about the tex-live-commits
mailing list.