summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/lwarp/lwarp.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/lwarp/lwarp.dtx')
-rw-r--r--macros/latex/contrib/lwarp/lwarp.dtx137
1 files changed, 90 insertions, 47 deletions
diff --git a/macros/latex/contrib/lwarp/lwarp.dtx b/macros/latex/contrib/lwarp/lwarp.dtx
index a4c164964e..26c58843b5 100644
--- a/macros/latex/contrib/lwarp/lwarp.dtx
+++ b/macros/latex/contrib/lwarp/lwarp.dtx
@@ -16,7 +16,7 @@
% \iffalse
%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<package>\ProvidesPackage{lwarp}
-%<package> [2020/03/25 v0.82 Allows LaTeX to directly produce HTML5 output.]
+%<package> [2020/03/25 v0.83 Allows LaTeX to directly produce HTML5 output.]
%
%<*driver>
\documentclass{ltxdoc}
@@ -2925,7 +2925,7 @@ This boolean may be tested by the user for later use.
%<*package>
% \fi
%
-% \CheckSum{43557}
+% \CheckSum{43597}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -3050,6 +3050,7 @@ This boolean may be tested by the user for later use.
% \changes{v0.80}{2020/02/19}{\ 2020/02/19}
% \changes{v0.81}{2020/03/04}{\ 2020/03/04}
% \changes{v0.82}{2020/03/25}{\ 2020/03/25}
+% \changes{v0.83}{2020/03/27}{\ 2020/03/27}
@@ -3272,6 +3273,14 @@ This boolean may be tested by the user for later use.
%
% \begin{description}
% \needspace{2\baselineskip}
+% \item[v0.83:] \pkg{memoir} fixes.
+% \begin{itemize}
+% \item \pkg{memoir}: Various fixes and updates, but subcaption labels
+% \margintag{packages}
+% still need work. (Out of time\dots)
+% \item \pkg{physunits}: Updated to v1.0.4.
+% \end{itemize}
+% \needspace{2\baselineskip}
% \item[v0.82:] \brand{MathJax} notes, \pkg{xpinyin} improvements, various updates.
% \begin{itemize}
% \item Improved footnotes with \brand{MathJax}.
@@ -18605,7 +18614,7 @@ src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.6/MathJax.js?config=TeX-
-- Copyright 2016-2020 Brian Dunn
-printversion = "v0.82"
+printversion = "v0.83"
requiredconfversion = "2" -- also at *lwarpmk.conf
function printhelp ()
@@ -49394,7 +49403,7 @@ name = \chemmacros_translate:n {scheme-name}
%
%
% \begin{macrocode}
-\RequirePackage{xcolor}% for \convertcolorspec
+\AtBeginDocument{\RequirePackage{xcolor}}% for \convertcolorspec
\LWR@ProvidesPackagePass{fancyvrb}[2008/02/07]
% \end{macrocode}
@@ -51613,7 +51622,7 @@ solid {\FancyVerbRuleColor{\LWR@origpound\LWR@tempcolor}} ; % space
% Accept all options for \pkg{lwarp-framed}:
% \begin{macrocode}
\LWR@ProvidesPackagePass{framed}[2011/10/22]
-\RequirePackage{xcolor}% for \convertcolorspec
+\AtBeginDocument{\RequirePackage{xcolor}}% for \convertcolorspec
% \end{macrocode}
@@ -64322,11 +64331,12 @@ remember to convert PDF images to SVG using 'lwarpmk pdftosvg *-fig.pdf',
% is emulated for \brand{MathJax}.
%
% \changes{v0.81}{2020/02/29}{\pkg{physunits}: Added.}
+% \changes{v0.83}{2020/03/26}{\pkg{physunits}: Updated to v1.0.4.}
%
% \codehtml
%
% \begin{macrocode}
-\LWR@ProvidesPackagePass{physunits}[2020/01/26]
+\LWR@ProvidesPackagePass{physunits}[2020/03/26]
% \end{macrocode}
%
% \begin{macrocode}
@@ -64350,7 +64360,7 @@ remember to convert PDF images to SVG using 'lwarpmk pdftosvg *-fig.pdf',
\CustomizeMathJax{\newcommand{\J}[1][ ]{\,\mathrm{#1J}}}
\CustomizeMathJax{\newcommand{\Joule}[1][ ]{\,\mathrm{#1J}}}
\CustomizeMathJax{\newcommand{\erg}{\,\mathrm{erg}}}
-\CustomizeMathJax{\newcommand{\kcal}[1]{\,\mathrm{kcal}}}% bug
+\CustomizeMathJax{\newcommand{\kcal}{\,\mathrm{kcal}}}
\CustomizeMathJax{\newcommand{\Cal}{\,\mathrm{Cal}}}
\CustomizeMathJax{\newcommand{\calorie}[1][ ]{\,\mathrm{#1cal}}}
\CustomizeMathJax{\newcommand{\BTU}{\,\mathrm{BTU}}}
@@ -64396,9 +64406,9 @@ remember to convert PDF images to SVG using 'lwarpmk pdftosvg *-fig.pdf',
\CustomizeMathJax{\newcommand{\ftpss}{\,\mathrm{ft}\,\mathrm{s}^{-2}}}
\CustomizeMathJax{\newcommand{\K}[1][ ]{\,\mathrm{#1K}}}
\CustomizeMathJax{\newcommand{\Kelvin}[1][ ]{\,\mathrm{#1K}}}
-\CustomizeMathJax{\newcommand{\Celcius}{^\circ{\,\mathrm{C}}}}% move space
-\CustomizeMathJax{\newcommand{\Rankine}{^\circ{\,\mathrm{R}}}}% move space
-\CustomizeMathJax{\newcommand{\Fahrenheit}{^\circ{\,\mathrm{F}}}}% move space
+\CustomizeMathJax{\newcommand{\Celcius}{\,^\circ{\mathrm{C}}}}
+\CustomizeMathJax{\newcommand{\Rankine}{\,^\circ{\mathrm{R}}}}
+\CustomizeMathJax{\newcommand{\Fahrenheit}{\,^\circ{\mathrm{F}}}}
\CustomizeMathJax{\newcommand{\rpm}{\,\mathrm{rev}\,\Min^{-1}}}
@@ -77206,17 +77216,26 @@ height:\LWR@printlength{\LWR@tempheight}%
% version of each, which happens to avoid \pkg{memoir}'s emulation system.
% \begin{macrocode}
\RequirePackage{lwarp-abstract}% req'd
-\RequirePackage{lwarp-array}% req'd
+% \RequirePackage{lwarp-array}% no longer req'd
\RequirePackage{lwarp-booktabs}% req'd
% \RequirePackage{lwarp-ccaption}% emualated below
\RequirePackage{lwarp-changepage}% req'd
\RequirePackage{lwarp-crop}
-\RequirePackage{lwarp-dcolumn}% req'd
+% \RequirePackage{lwarp-dcolumn}% no longer req'd
\RequirePackage{lwarp-enumerate}% req'd
\RequirePackage{lwarp-epigraph}% req'd
\RequirePackage{lwarp-fancyvrb}% req'd
\RequirePackage{lwarp-footmisc}% req'd
+% \end{macrocode}
+%
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Fixed \pkg{framed}.}
+% \begin{macrocode}
+\let\framed\relax \let\endframed\relax
+\let\shaded\relax \let\endshaded\relax
+\let\leftbar\relax \let\endleftbar\relax
+\let\snugshade\relax \let\endsnugshade\relax
\RequirePackage{lwarp-framed}% req'd
+
\RequirePackage{lwarp-hanging}% req'd
\RequirePackage{lwarp-makeidx}% req'd
\DisemulatePackage{moreverb}
@@ -77228,37 +77247,19 @@ height:\LWR@printlength{\LWR@tempheight}%
\RequirePackage{lwarp-parskip}
\RequirePackage{lwarp-setspace}% req'd
\RequirePackage{lwarp-showidx}
+\RequirePackage{lwarp-subcaption}% req'd for \subfloat
% \end{macrocode}
-% Avoids a conflict with \pkg{memoir}:
-% \changes{v0.79}{2020/01/06}{\pkg{subcaption}: Fix with \pkg{memoir}.}
-% \begin{macrocode}
-\AtBeginDocument{%
- \@ifpackageloaded{subcaption}{}{
- \RequirePackage{lwarp-subfigure}
- \let\subfigure\subbottom
- \let\subtable\subtop
- }%
-}%
-% \end{macrocode}
-%
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: No longer require \pkg{subfigure}.}
+
% ^^A Not sure why this is here:
% \begin{macrocode}
\makeindex
% \end{macrocode}
%
-% \pkg{subfigure} is emulated via \pkg{subfig}, which pre-defines
-% |subfigure| and |subtable|, but \pkg{memoir} does not, so
-% they must be tested for here:
+%
% \begin{macrocode}
-\LetLtxMacro\LWR@memorignewsubfloat\newsubfloat
-\RenewDocumentCommand{\newsubfloat}{O{} m}{%
- \@ifundefined{c@sub#2}{%
- \LWR@memorignewsubfloat[#1]{#2}%
- }{}%
-}
-
-\RequirePackage{lwarp-tabularx}% req'd
+% \RequirePackage{lwarp-tabularx}% no longer req'd
\RequirePackage{lwarp-titling}% req'd
% \RequirePackage{lwarp-tocbibind}% not emulated by memoir
\RequirePackage{lwarp-tocloft}% req'd
@@ -77286,24 +77287,29 @@ height:\LWR@printlength{\LWR@tempheight}%
%
% \subsection{Page layout}
%
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Updated for new sizes.}
% \begin{macrocode}
\renewcommand*{\stockavi}{}
\renewcommand*{\stockav}{}
\renewcommand*{\stockaiv}{}
\renewcommand*{\stockaiii}{}
+\renewcommand*{\stockavii}{}
\renewcommand*{\stockbvi}{}
\renewcommand*{\stockbv}{}
\renewcommand*{\stockbiv}{}
\renewcommand*{\stockbiii}{}
+\renewcommand*{\stockbvii}{}
% \renewcommand*{\stockmetriccrownvo}{}% in docs but not in the package
\renewcommand*{\stockmlargecrownvo}{}
\renewcommand*{\stockmdemyvo}{}
\renewcommand*{\stockmsmallroyalvo}{}
\renewcommand*{\pageavi}{}
+\renewcommand*{\pageavii}{}
\renewcommand*{\pageav}{}
\renewcommand*{\pageaiv}{}
\renewcommand*{\pageaiii}{}
\renewcommand*{\pagebvi}{}
+\renewcommand*{\pagebvii}{}
\renewcommand*{\pagebv}{}
\renewcommand*{\pagebiv}{}
\renewcommand*{\pagebiii}{}
@@ -77435,7 +77441,13 @@ height:\LWR@printlength{\LWR@tempheight}%
\let\DoubleSpacing\doublespacing
\renewcommand*{\setPagenoteSpacing}[1]{}
\renewcommand*{\setFloatSpacing}[1]{}
-\let\SingleSpacing\singlespacing
+% \end{macrocode}
+%
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Updated.}
+% \begin{macrocode}
+\renewcommand{\SingleSpacing}{\@ifstar\singlespacing\singlespacing}
+% \end{macrocode}
+% \begin{macrocode}
\let\setSingleSpace\SetSinglespace
\let\SingleSpace\singlespace
\let\endSingleSpace\endsinglespace
@@ -77477,6 +77489,11 @@ height:\LWR@printlength{\LWR@tempheight}%
% \newlength{\thanksmarksep}% already provided by memoir
% \end{macrocode}
+
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Updated.}
+% \begin{macrocode}
+\renewcommand\titlingpageend[2]{}
+% \end{macrocode}
%
% \subsection{Abstracts}
% \begin{macrocode}
@@ -78106,8 +78123,11 @@ height:\LWR@printlength{\LWR@tempheight}%
\renewcommand{\flegfigure}{\figurename}
\renewcommand{\flegtoctable}{}
\renewcommand{\flegtocfigure}{}
-
-
+% \end{macrocode}
+%
+% \cs{subfloat} is from the \pkg{subcaption} package.
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Use \pkg{subcaption} instead of \pkg{subfig}.}
+% \begin{macrocode}
\renewcommand{\subcaption}[2][]{%
\ifblank{#1}{\subfloat[#2]{}}{\subfloat[#1][#2]{}}%
}
@@ -78419,7 +78439,8 @@ height:\LWR@printlength{\LWR@tempheight}%
\LWR@new@label{LWRindex-\arabic{LWR@autoindex}}%
% \ifshowindexmark\@showidx{#1}\fi
\protected@write\@auxout{}%
- {\string\@@wrindexm@m{\@idxfile}{#1}{\arabic{LWR@autoindex}}}%
+% {\string\@@wrindexm@m{\@idxfile}{#1}{\thepage}}%
+ {\string\@@wrindexm@m{\@idxfile}{#1}{\arabic{LWR@autoindex}}}%
\endgroup
\@esphack}%
% \end{macrocode}
@@ -78436,16 +78457,34 @@ height:\LWR@printlength{\LWR@tempheight}%
\LWR@new@label{LWRindex-\arabic{LWR@autoindex}}%
% \ifshowindexmark\@showidx{#1}\fi
\protected@write\@auxout{}%
- {%
-% \string\@@wrindexm@m{\@idxfile}{#1}{\@nameuse{the\@sptheidx}}%
- \string\@@wrindexm@m{\@idxfile}{#1}{\arabic{LWR@autoindex}}%
- }%
+% {\string\@@wrindexm@m{\@idxfile}{#1}{\@nameuse{the\@sptheidx}}}%
+ {\string\@@wrindexm@m{\@idxfile}{#1}{\arabic{LWR@autoindex}}}%
\endgroup
\@esphack}%
}% \AtBeginDocument
% \end{macrocode}
+
+% Patched to append |_html| to the file:
+% \changes{v0.83}{2020/03/26}{\pkg{lwarp-patch-memoir}: Fixed: \cs{specialindex}.}
+% \begin{macrocode}
+\renewcommand{\@spindex}[2]{%
+ \@ifundefined{#1@idxfile}%
+ {\ifreportnoidxfile
+ \@memwarn{Undefined index file #1}%
+ \fi
+ \begingroup
+ \@sanitize
+ \@nowrindex}%
+ {\def\@idxfile{#1_html}%
+ \def\@sptheidx{#2}%
+ \begingroup
+ \@sanitize
+ \@wrspindex}}
+% \end{macrocode}
+
+
% Patched to use |_html| filename and \cs{BaseJobname}:
% \changes{v0.58}{2018/06/22}{\pkg{lwarp-patch-memoir}: Fix for multiple indexes.}
% \begin{macrocode}
@@ -78618,17 +78657,21 @@ height:\LWR@printlength{\LWR@tempheight}%
\RenewDocumentCommand{\subbottom}{O{} O{} m}{%
\subfloat[#1][#2]{#3}%
}
-
+% \end{macrocode}
+%
+% \changes{v0.83}{2020/03/27}{\pkg{lwarp-patch-memoir}: Fixed: \cs{contsubtop}, \cs{contsubbottom}.}
+% \begin{macrocode}
\renewcommand{\contsubtop}{%
- \ContinuedFloat\addtocounter{\@captype}{1}%
+ \ContinuedFloat
\subtop%
}
\renewcommand{\contsubbottom}{%
- \ContinuedFloat\addtocounter{\@captype}{1}%
+ \ContinuedFloat
\subbottom%
}
-
+% \end{macrocode}
+% \begin{macrocode}
\renewcommand{\subconcluded}{}
\let\contsubtable\contsubtop