summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/mathfont
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/mathfont')
-rw-r--r--macros/latex/contrib/mathfont/README.txt74
-rw-r--r--macros/latex/contrib/mathfont/mathfont_code.dtx235
-rw-r--r--macros/latex/contrib/mathfont/mathfont_code.pdfbin371018 -> 363665 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_example_cormorant.pdfbin51264 -> 51367 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_example_kelvinch.pdfbin84913 -> 85049 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_example_roboto.pdfbin54246 -> 54342 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_example_typey.pdfbin38746 -> 47387 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_symbol_list.pdfbin232449 -> 186232 bytes
-rw-r--r--macros/latex/contrib/mathfont/mathfont_user_guide.pdfbin115029 -> 115314 bytes
9 files changed, 192 insertions, 117 deletions
diff --git a/macros/latex/contrib/mathfont/README.txt b/macros/latex/contrib/mathfont/README.txt
index 9cffe034ce..99ed16767f 100644
--- a/macros/latex/contrib/mathfont/README.txt
+++ b/macros/latex/contrib/mathfont/README.txt
@@ -1,35 +1,58 @@
-LaTeX package mathfont version 2.1 installation information.
+LaTeX package mathfont version 2.2 installation information,
+released December 2022.
-This file is README.txt from version 2.1 of the free and
+This file is README.txt from version 2.2 of the free and
open-source LaTeX package "mathfont," to be used with the
XeTeX or LuaTeX engines. The package is designed to adapt
text fonts for use in math mode, and if you typeset your
document with LuaLaTeX, mathfont adds resizable delimiters,
big operators, and a MathConstants table to your font.
-Besides this file, the installation contains the following
+*********************************************************
+
+To install mathfont automatically, update your TeXLive or
+MacTeX distribution or use a package manager such as tlmgr.
+
+To install mathfont manually, you need to generate the
+package file mathfont.sty from mathfont.dtx. You can do
+this in two ways:
+
+ (1) Running Plain TeX on mathfont_code.dtx will create
+ mathfont.sty as well as several other tex files
+ that can be used for typesetting documentation.
+
+ (2) Running LaTeX on mathfont_code.dtx will produce the
+ files listed in point (1) including mathfont.sty as
+ well as mathfont_code.pdf.
+
+Once you have created mathfont.sty, you should move it
+into a directory searchable by TeX to complete the
+installation.
+
+*********************************************************
+
+Besides this README, the installation contains the following
items:
- (1) mathfont_code.dtx: the primary file. Run this file
- through LaTeX to generate mathfont.sty and complete
- the installation.
+ (1) mathfont_code.dtx: the primary file. See above for
+ instructions to generate mathfont.sty from this file
+ and complete the installation.
(2) mathfont_code.pdf: documentation of the package code.
- (3) mathfont_symbol_list.pdf: a list of symbols that
+ (3) mathfont_symbol_list.pdf: a list of symbols that
mathfont provides access to.
(4) mathfont_user_guide.pdf: a user guide.
(5) four files called mathfont_example_<fontname>.pdf:
- example files showing mathfont in action.
+ examples of mathfont in action.
-To install mathfont automatically, update your TeXLive or
-MacTeX distribution or use a package manager such as tlmgr.
-To install mathfont manually, run mathfont_code.dtx through
-LaTeX. Doing so will create the file mathfont.sty, and you
-should then move mathfont.sty into a directory searchable
-by TeX.
+Typesetting mathfont_code.dtx will generate the tex files
+used to create the pdf documentation listed in points (3)
+through (5) above.
+
+*********************************************************
Copyright 2018-2022 by Conrad Kosowsky
@@ -76,7 +99,15 @@ of the following items:
and
- (6) the associated README.txt file
+ (6) this README.txt file
+
+The Work does not include any fonts, and the installation
+does not contain any font files. The fonts Bona Nova,
+Cormorant, Crimson, Kelvinch, Overpass, STIXGeneral, and
+Typey McTypeface have released under the SIL Open Font
+License and are used pursuant to that license. The font
+Roboto has been released under the Apache License and is
+used pursuant to that license.
PLEASE KNOW THAT THIS FREE SOFTWARE IS PROVIDED WITHOUT
ANY WARRANTY. SPECIFICALLY, THE "NO WARRANTY" SECTION OF
@@ -111,15 +142,6 @@ Derivative works based on this package may come with their
own license or terms of use, and the package author is not
responsible for any third-party software.
-The Work does not include any fonts, and the installation
-does not contain any font files. The fonts Bona Nova,
-Cormorant, Crimson, Kelvinch, Overpass, STIXGeneral, and
-Typey McTypeface have released under the SIL Open Font
-License and are used pursuant to that license. The font
-Roboto has been released under the Apache License and is
-used pursuant to that license.
-
-For more information, see mathfont_code.dtx.
-
-Happy TeXing!
+*********************************************************
+For more information, see mathfont_code.dtx. Happy TeXing!
diff --git a/macros/latex/contrib/mathfont/mathfont_code.dtx b/macros/latex/contrib/mathfont/mathfont_code.dtx
index cb579ee77c..8b73b6d587 100644
--- a/macros/latex/contrib/mathfont/mathfont_code.dtx
+++ b/macros/latex/contrib/mathfont/mathfont_code.dtx
@@ -1,39 +1,47 @@
% \iffalse ---!!! FIRST META-COMMENT !!!---
%
%
-% This file is mathfont_code.dtx from version 2.1 of the
+% This file is mathfont_code.dtx from version 2.2 of the
% free and open-source LaTeX package "mathfont," to be
-% used with the XeTeX or LuaTeX engines. Running LaTeX on
-% mathfont_code.dtx will produce the following files:
+% used with the XeTeX or LuaTeX engines. Running Plain
+% TeX mathfont_code.dtx will produce the following files:
%
% (1) the package file mathfont.sty;
%
-% (2) the pdf documentation file mathfont_code.pdf;
-%
-% (3) the derived files mathfont_symbol_list.tex,
+% (2) the derived files mathfont_symbol_list.tex,
% mathfont_user_guide.tex, and four files called
% mathfont_example_<fontname>.tex, which can be
% used to typeset further documentation for
% mathfont;
%
-% (4) the stand-alone derived files mathfont_doc_patch.tex,
+% (3) the stand-alone derived files mathfont_doc_patch.tex,
% mathfont_equations.tex, and mathfont_heading.tex,
% which are used to produce documentation;
%
% and
%
-% (5) a number of other derived files.
+% (4) a number of other derived files.
+%
+% Running LaTeX on mathfont_code.dtx will produce the files
+% listed above as well as the following:
+%
+% (5) the pdf documentation file mathfont_code.pdf;
+%
+% and
+%
+% (6) a number of other derived files.
%
% To install mathfont on your computer, run this file through
-% LaTeX and move mathfont.sty into a directory searchable by
-% TeX.
+% Plain TeX or LaTeX and move mathfont.sty into a directory
+% searchable by TeX. See the associated README.txt file for
+% installation information.
%
%
% \fi
% \iffalse ---!!! SECOND META-COMMENT !!!---
%
%
-% This file is from version 2.1 of the free and open-source
+% This file is from version 2.2 of the free and open-source
% LaTeX package "mathfont," to be used with the XeTeX or
% LuaTeX engines. (As of version 2.0, LuaTeX is recommended.)
%
@@ -84,6 +92,14 @@
%
% (6) the associated README.txt file
%
+% The Work does not include any fonts, and the installation
+% does not contain any font files. The fonts Bona Nova,
+% Cormorant, Crimson, Kelvinch, Overpass, STIXGeneral, and
+% Typey McTypeface have been released under the SIL Open
+% Font License and are used pursuant to that license. The
+% font Roboto has been released under the Apache License
+% and is used pursuant to that license.
+%
% PLEASE KNOW THAT THIS FREE SOFTWARE IS PROVIDED WITHOUT
% ANY WARRANTY. SPECIFICALLY, THE "NO WARRANTY" SECTION OF
% THE LATEX PROJECT PUBLIC LICENSE STATES THE FOLLOWING:
@@ -117,14 +133,6 @@
% own license or terms of use, and the package author is not
% responsible for any third-party software.
%
-% The Work does not include any fonts, and the installation
-% does not contain any font files. The fonts Bona Nova,
-% Cormorant, Crimson, Kelvinch, Overpass, STIXGeneral, and
-% Typey McTypeface have been released under the SIL Open
-% Font License and are used pursuant to that license. The
-% font Roboto has been released under the Apache License
-% and is used pursuant to that license.
-%
% Happy TeXing!
%
%
@@ -143,7 +151,7 @@
\askforoverwritefalse
\preamble
-This file is from version 2.1 of the free and open-source
+This file is from version 2.2 of the free and open-source
LaTeX package "mathfont," to be used with the XeTeX or
LuaTeX engines. (As of version 2.0, LuaTeX is recommended.)
@@ -193,9 +201,7 @@ Derivative works based on this package may come with their
own license or terms of use, and the package author is not
responsible for any third-party software.
-For more information, see mathfont_code.dtx.
-
-Happy TeXing!
+For more information, see mathfont_code.dtx. Happy TeXing!
\endpreamble
\generate{
@@ -210,23 +216,28 @@ Happy TeXing!
\file{mathfont_example_roboto.tex}{\from{mathfont_code.dtx}{roboto}}
\file{mathfont_example_typey.tex}{\from{mathfont_code.dtx}{typey}}}
\catcode`\ =12\relax
-\message{^^J^^J
-******************************************^^J
-* *^^J
-* To finish the installation, move the *^^J
-* following file into a directory *^^J
-* searchable by TeX once *^^J
-* mathfont_code.dtx finishes compiling: *^^J
-* *^^J
-* mathfont.sty *^^J
-* *^^J
-******************************************^^J^^J^^J^^J^^J^^J}
+\message{^^J
+****************************************************^^J
+* *^^J
+* To finish the installation, move the following *^^J
+* file into a directory searchable by TeX once *^^J
+* mathfont_code.dtx finishes compiling: *^^J
+* *^^J
+* mathfont.sty *^^J
+* *^^J
+****************************************************^^J^^J^^J^^J}
\endgroup
+\ifx\LaTeX\undefined
+ \message{Plain TeX format used; quitting now.}
+ \message{To create mathfont_code.pdf, run^^J%
+ mathfont_code.dtx through LaTeX.^^J}
+ \expandafter\end
+\fi
%</batchfile>
%<*driver>
-\documentclass[12pt,twoside]{ltxdoc}
+\documentclass[12pt,doc2,letterpaper]{ltxdoc}
\makeatletter
-\usepackage[margin=72.27pt]{geometry}
+\usepackage[margin=1in]{geometry}
\usepackage[factor=700,stretch=14,shrink=14,step=1]{microtype}
\usepackage{graphicx}
\usepackage{tabularx}
@@ -260,7 +271,7 @@ Happy TeXing!
entries indicate pages in the document. Bold means a
definition.
- \medskip
+ %\medskip
\input mathfont_code.ind
\end{document}
@@ -270,7 +281,7 @@ Happy TeXing!
% \fi
%
%
-% \CheckSum{6609}
+% \CheckSum{6615}
% \init@checksum
%
%
@@ -310,7 +321,7 @@ Happy TeXing!
% \ifM@agreeklower,\ifM@cyrillicupper,\ifM@cyrilliclower,%
% \ifM@hebrew,\ifM@digits,\ifM@operator,\ifM@symbols,%
% \ifM@extsymbols,\ifM@delimiters,\ifM@arrows,\ifM@bigops,%
-% \ifM@extbigops,\ifM@bb,\ifM@cal,\ifM@frak,\ifM@bcal,\M@font@loadedtrue%
+% \ifM@extbigops,\ifM@bb,\ifM@cal,\ifM@frak,\ifM@bcal,\M@font@loadedtrue,%
% \ifM@bfrak,\if@optionpresent,\if@suboptionpresent,%
% \mathgroup,\nolimits,\on@line,\PackageWarningNoLine,\RequirePackage,%
% \thr@@,\M@toks,\inputlineno,\mathchar@type,\DeclareMathAccent,%
@@ -349,7 +360,7 @@ Happy TeXing!
% \cyrya,\cyrvari}
%
%
-% \DoNotIndexMain{\@@set@mathchar,\@@set@mathsymbol,%
+% \DoNotIndex{\@@set@mathchar,\@@set@mathsymbol,%
% \@@set@mathaccent,\set@mathchar,\set@mathsymbol,%
% \set@mathaccent,\Umathcode,\Umathchardef,%
% \colon,\mathellipsis,\angle,\sqsubset,\sqsupset,\bowtie,%
@@ -379,7 +390,7 @@ Happy TeXing!
% First and foremost, the package needs to declare itself.
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{mathfont}[2022/11/30 v. 2.1 Package mathfont]
+\ProvidesPackage{mathfont}[2022/12/04 v. 2.2 Package mathfont]
% \end{macrocode}
% We specify conditionals that we will use later in handling options and setup.
% \begin{macrocode}
@@ -413,16 +424,16 @@ Happy TeXing!
\protected\def\newmathscit{\M@NoMathfontError\newmathscit\@gobbletwo}
\protected\def\newmathbfsc{\M@NoMathfontError\newmathbfsc\@gobbletwo}
\protected\def\newmathbfscit{\M@NoMathfontError\newmathbfscit\@gobbletwo}
-\protected\def\newmathfontcommand{\M@NoMathfontError\newmathfontcommand
- \@gobblefour}
-\protected\def\RuleThicknessFactor{\M@NoMathfontError\RuleThicknessFactor
- \@gobble}
-\protected\def\IntegralItalicFactor{\M@NoMathfontError\IntegralItalicFactor
- \@gobble}
-\protected\def\SurdVerticalFactor{\M@NoMathfontError\SurdVerticalFactor
- \@gobble}
-\protected\def\SurdHorizontalFactor{\M@NoMathfontError\SurdHorizontalFactor
- \@gobble}
+\protected\def\newmathfontcommand{%
+ \M@NoMathfontError\newmathfontcommand\@gobblefour}
+\protected\def\RuleThicknessFactor{%
+ \M@NoMathfontError\RuleThicknessFactor\@gobble}
+\protected\def\IntegralItalicFactor{%
+ \M@NoMathfontError\IntegralItalicFactor\@gobble}
+\protected\def\SurdVerticalFactor{%
+ \M@NoMathfontError\SurdVerticalFactor\@gobble}
+\protected\def\SurdHorizontalFactor{%
+ \M@NoMathfontError\SurdHorizontalFactor\@gobble}
\protected\def\CharmLine{\M@NoMathfontError\CharmLine\@gobble}
\protected\def\CharmFile{\M@NoMathfontError\CharmFile\@gobble}
% \end{macrocode}
@@ -531,9 +542,6 @@ Happy TeXing!
use #2\MessageBreak
instead. For more information,\MessageBreak
see the mathfont documentation.}}
-\IfFileExists{atveryend.sty}
- {\RequirePackage{atveryend}\let\E@sterEggHook\AtVeryVeryEnd}
- {\let\E@sterEggHook\AtEndDocument}
% \end{macrocode}
% Now we code the package options. The deprecated options now cause an error.
% \begin{macrocode}
@@ -553,25 +561,36 @@ Happy TeXing!
\ifE@sterEggDecl@red\else
\E@sterEggDecl@redtrue
\def\EasterEggUpdate{\show\E@sterEggUpd@te}
- \def\E@sterEggUpd@te{Okay, opening your Easter egg}
- \EasterEggUpdate
- \def\E@sterEggUpd@te{..}
+ \def\E@sterEggUpd@te{Easter Egg Status:^^J^^J%
+ Okay, opening your Easter egg.^^J^^J}
\EasterEggUpdate
+ \def\E@sterEggUpd@te{Easter Egg Status:^^J^^J%
+ Uh oh. It looks like^^J%
+ your Easter egg flew^^J%
+ out the window. I don't^^J%
+ suppose you know the^^J%
+ best kind of bait to^^J%
+ lure an egg?^^J^^J}
\EasterEggUpdate
- \typeout{^^JHm, I think it flew out the^^J%
- window. Check back here when^^J%
- everything's done compiling^^J}
- \def\E@sterEggUpd@te{Uh oh}
+ \def\E@sterEggUpd@te{Easter Egg Status:^^J^^J%
+ Still wrangling. Try back later.^^J^^J}
+ \AtBeginDocument{\bgroup
+ \def\E@sterEggUpd@te{Easter Egg Status:^^J^^J:%
+ If we have zero eggs^^J%
+ and zero bunnies, how^^J%
+ many gnats does it take^^J%
+ to change a lightbulb??^^J^^J}
\EasterEggUpdate
- \def\E@sterEggUpd@te{Still wrangling. Try back later}
- \AtBeginDocument\EasterEggUpdate
- \E@sterEggHook{%
- \typeout{^^JHappy, happy day! Happy,^^J%
- happy day! Clap your hands,^^J%
- and be glad your hovercraft^^J%
- isn't full of eels!^^J}
- \def\E@sterEggUpd@te{Got it :)\@gobble}
- \EasterEggUpdate}
+ \egroup}
+ \AtEndDocument{%
+ \def\E@sterEggUpd@te{Easter Egg Status:^^J^^J%
+ Happy, happy day! Happy,^^J%
+ happy day! Clap your hands,^^J%
+ and be glad your hovercraft^^J%
+ isn't full of eels!^^J^^J}
+ \EasterEggUpdate
+ \let\E@sterEggUpd@te\relax
+ \let\EasterEggUpdate\relax}
\fi}% my easter egg :)
% \end{macrocode}
% The three real package options. The options |adjust| and |no-adjust| overwrite \textsf{mathfont}'s default decision about whether to apply Lua-based font adjustments to all future fonts loaded.
@@ -753,16 +772,18 @@ Happy TeXing!
% \indexpage{your mathconstants on line=Your \texttt{\char`\\mathconstants} on line}
% \begin{macrocode}
\def\M@BadMathConstantsFontError#1{\PackageError{mathfont}
- {Invalid font specifier for \string\mathconstantsfont:\MessageBreak"#1"}
+ {Invalid\MessageBreak font specifier for
+ \string\mathconstantsfont:\MessageBreak"#1"}
{Your command was ignored--I can't parse your argument.\MessageBreak
Please make sure to use text that you have previously\MessageBreak
fed to \string\mathfont\space for the argument of
\string\mathconstantsfont.^^J}}
\def\M@BadMathConstantsFontTypeError#1{\PackageError{mathfont}
- {Invalid font specifier for \string\mathconstantsfont:\MessageBreak"#1"}
+ {Invalid\MessageBreak font specifier for
+ \string\mathconstantsfont:\MessageBreak"#1"}
{The optional argument of \string\mathconstantsfont\MessageBreak
should be "upright" or "italic." Right now,\MessageBreak
- it's neither.^^J}}
+ it's "#1."^^J}}
\def\M@LuaTeXOnlyWarning{\PackageWarning{mathfont}
{Your \string\mathconstantsfont\space
on line \the\inputlineno\space is\MessageBreak
@@ -888,17 +909,24 @@ Happy TeXing!
\protected\xdef#2{%
\Umathaccent\mathchar@type#3+\number#1+\the\count\z@\relax}}
% \end{macrocode}
-% We increase the upper bound on the number of symbol fonts to be 256. Lua\TeX\ and \XeTeX\ allow up to 256 math families, but the \LaTeX\ kernel keeps the old upper bound of 16 symbol fonts under these two engines. We patch |\DeclareSymbolFont| to change the |\count18<15| to |\count18<\e@mathgroup@top|, where |\e@mathgroup@top| is the number of math families and is 256 in \XeTeX\ and Lua\TeX. Because macro patching is complicated, the next few lines may seem esoteric. Our approach is to get a sanitized definition with |\meaning| and |\strip@prefix|, implement the patch by expanding |\M@p@tch@decl@re|, and retokenize the whole thing. A simpler approach, such as calling |\M@p@tch@decl@re| directly on the expansion of |\DeclareSymbolFont|, won't work because of the way \TeX\ stores and expands parameter symbols inside macros.
+% We increase the upper bound on the number of symbol fonts to be 256. Lua\TeX\ and \XeTeX\ allow up to 256 math families, but the \LaTeX\ kernel keeps the old upper bound of 16 symbol fonts under these two engines. We patch |\DeclareSymbolFont| to change the |\count18<15| to |\count18<\e@mathgroup@top|, where |\e@mathgroup@top| is the number of math families and is 256 in \XeTeX\ and Lua\TeX. Because macro patching is complicated, the next few lines may seem somewhat esoteric. Our approach is to get a sanitized definition with |\meaning| and |\strip@prefix|, implement the patch by expanding |\M@p@tch@decl@re|, and retokenize the whole thing. A simpler approach, such as calling |\M@p@tch@decl@re| directly on the expansion of |\DeclareSymbolFont|, won't work because of the way \TeX\ stores and expands parameter symbols inside macros.
+%
+% As of November 2022, the \LaTeX\ kernel has redefined |\DeclareSymbolFont@m@dropped| to have the same definition as the old |\DeclareSymbolFont|, and now |\DeclareSymbolFont| is a wrapper around this macro. This was done for error checking purposes to remove extra |m|'s from certain \textsc{nfss} family names. This means that if |\DeclareSymbolFont@m@dropped| is defined, we should patch that macro, and otherwise, we should patch |\DeclareSymbolFont|.
% \begin{macrocode}
+\ifx\DeclareSymbolFont@m@dropped\@undefined
+ \edef\@tempa{\expandafter\strip@prefix\meaning\DeclareSymbolFont}
+ \def\@tempb{\def\DeclareSymbolFont##1##2##3##4##5}
+\else
+ \edef\@tempa{\expandafter\strip@prefix\meaning\DeclareSymbolFont@m@dropped}
+ \def\@tempb{\def\DeclareSymbolFont@m@dropped##1##2##3##4##5}
+\fi
\def\M@p@tch@decl@re#1<15#2\@nil{#1<\e@mathgroup@top#2}
-\edef\M@DecSymDef{\expandafter\expandafter\expandafter
- \M@p@tch@decl@re\expandafter\strip@prefix\meaning\DeclareSymbolFont\@nil}
+\edef\M@DecSymDef{\expandafter\M@p@tch@decl@re\@tempa\@nil}
% \end{macrocode}
% Now |\M@DecSymDef| contains the patched text of our new |\DeclareSymbolFont|, all with catcode 12. In order to make it useable, we have to retokenize it. We use |\scantextokens| in Lua\TeX\ and a safe version of |\scantokens| in \XeTeX. We store the |\def\DeclareSymbolFont| and parameter declaration in a separate macro |\@tempa| to make it easy to expand around them when we redefine |\DeclareSymbolFont|.
% \begin{macrocode}
-\def\@tempa{\def\DeclareSymbolFont##1##2##3##4##5}
\ifdefined\directlua
- \expandafter\@tempa\expandafter{\scantextokens\expandafter{\M@DecSymDef}}
+ \expandafter\@tempb\expandafter{\scantextokens\expandafter{\M@DecSymDef}}
% \end{macrocode}
% Unfortunately, while |\scantextokens| is straightforward, |\scantokens| is a menace. The problem is that when it expands, the primitive inserts an end-of-file token (because |\scantokens| mimics writing to a file and |\input|ing what it just wrote) after the retokenized code, and this is why |\scantokens| can produce an end-of-file error. The easiest way to make the command useable is to put a |\noexpand| before the end-of-file token with |\everyeof|, and at the same time, this needs to happen inside an |\edef| so that \TeX\ handles the |\noexpand| as it is first seeing the end-of-file token. In order to prevent the |\edef| from also expanding our retokenized definition of |\DeclareSymbolFont|, we put the definition inside an |\unexpanded|.
% \begin{macrocode}
@@ -912,7 +940,7 @@ Happy TeXing!
\edef\M@retokenize{\noexpand\scantokens{\noexpand\unexpanded{\M@DecSymDef}}}
\edef\M@retokenize{\M@retokenize}
\expandafter\endgroup
- \expandafter\@tempa\expandafter{\M@retokenize}
+ \expandafter\@tempb\expandafter{\M@retokenize}
\fi
% \end{macrocode}
% We need to keep track of the number of times we have loaded fonts, and |\M@count| fulfills this role. The |\M@toks| object will record a message that displays in the |log| file when the user calls |\mathfont|. The |\newread| is for Lua-based font adjustments.
@@ -1432,8 +1460,7 @@ Happy TeXing!
{\@mathconstantsfont[upright]}}
\def\@mathconstantsfont[#1]#2{%
\edef\@tempa{\csname M@fontfamily@base@#2\endcsname}
- \def\@tempb{\relax}
- \ifx\@tempa\@tempb
+ \expandafter\ifx\@tempa\relax
\M@BadMathConstantsFontError{#2}
\else
% \end{macrocode}
@@ -1448,7 +1475,7 @@ Happy TeXing!
\ifx\@tempb\@tempc
\let\@tempc\itdefault
\else
- \M@BadMathConstantsFontTypeError{#2}
+ \M@BadMathConstantsFontTypeError{#1}
\fi
\fi
\ifcsname symM#1\csname M@fontid@\@tempa\endcsname\endcsname\else
@@ -1581,7 +1608,7 @@ Happy TeXing!
\endgroup % first branch \endgroup
\else
\@expandtwoargs\in@{\@backslashchar}{\@tempa}
- \ifin@ % is \ in #1?
+ \ifin@ % is backslash in #1?
\endgroup % second branch \endgroup
\else
\directlua{
@@ -1641,7 +1668,7 @@ Happy TeXing!
% \begin{macrocode}
\else
\@tfor\@i:=\RuleThicknessFactor\IntegralItalicFactor\SurdHorizontalFactor
- \SurdVerticalFactor\CharmLine\CharmFile\mathconstantsfont
+ \SurdVerticalFactor\CharmLine\CharmFile
\do{%
\protected\expandafter\edef\@i{\noexpand\M@NoFontAdjustError
\expandafter\noexpand\@i
@@ -1915,7 +1942,7 @@ Happy TeXing!
\fi
\else
\@expandtwoargs\in@{\@backslashchar}{\@tempa}
- \ifin@ % is \ in #1?
+ \ifin@ % is backslash in #1?
\ifM@fromCharmFile
\M@ForbiddenCharmFile{\@backslashchar}
\else
@@ -3071,7 +3098,7 @@ local delim_glyphs = {40, % (
41, % )
47, % /
91, % [
- 92, % \
+ 92, % backslash
93, % ]
123, % {
125, % }
@@ -3669,7 +3696,7 @@ mathfont:add_extensible_variants(smash, int_glyphs, int_scale)
\protected\gdef\backslash{\ifmmode\mathbackslash\else\textbackslash\fi}
\protected\xdef\mathbackslash{%
\Udelimiter+2+\number\csname sym\M@delimiters@font\endcsname
- +92\relax} % \
+ +92\relax} % backslash
\protected\xdef\lbrace{%
\Udelimiter+4+\number\csname sym\M@delimiters@font\endcsname
+123\relax} % {
@@ -3747,7 +3774,7 @@ mathfont:add_extensible_variants(smash, int_glyphs, int_scale)
\gdef\sqrtsign##1{\@sqrts@gn{\mkern\radicandoffset##1}}}
\else
\def\M@radical@set{%
- \edef\M@radical@font{M\@radicalshape\@tempa}
+ \edef\M@radical@font{M\M@radicalshape\@tempa}
\DeclareMathSymbol{\surd}{\mathord}{\M@radical@font}{"221A}}
\fi
% \end{macrocode}
@@ -4658,15 +4685,23 @@ mathfont:add_extensible_variants(smash, int_glyphs, int_scale)
% \item |\setfont| now sets |\mathrm|, etc.
% \item added |\newmathsc|, other math alphabet commands for small caps
%
-% \version{2.1}{December 2022\strut}
+% \version{2.1}{November 2022\strut}
% \item |\mathbb|, etc.\ commands change |\Umathcode|s of letters instead of |\M@|\meta{bb,etc.}|@|\meta{letter} commands
% \item removed warnings about non-letter contents of |\mathbb|, etc.
% \item fonts loaded twice, once with default settings (for text) and once in base mode (for math)
% \item |mathconstantsfont| accepts ``upright'' or ``italic'' as optional argument
%
+% \version{2.2}{December 2022\strut}
+% \item changed the easter egg text
+% \item updated patch for |\DeclareSymbolFont| to work with changes to the kernel
+% \item calling Plain \TeX\ on \texttt{mathfont\_code.dtx} produces sty file and no pdf file
+%
+%
% \egroup
% \end{multicols*}
%
+%
+%
% \iffalse
%
%</package>
@@ -5967,6 +6002,11 @@ This is Roboto with Overpass for the radical signs and STIXGeneral for the tenso
\DeclareMathOperator{\Res}{Res}
\usepackage{mathfont}
\mathfont[radical]{Crimson}
+
+%% We have to declare Typey McTypeface manually because
+%% it has no bold fontface---we use embolden from luaotflaod
+%% to make a fake bold
+
\DeclareFontFamily{TU}{Typey}{}
\DeclareFontShape{TU}{Typey}{m}{n}
{<->"Typey McTypeface:\M@otf@features"}{}
@@ -5976,6 +6016,18 @@ This is Roboto with Overpass for the radical signs and STIXGeneral for the tenso
{<->"Typey McTypeface:\M@otf@features;embolden=6"}{}
\DeclareFontShape{TU}{Typey}{b}{it}
{<->"Typey McTypeface/I:\M@otf@features;embolden=6"}{}
+
+%% We also need to declare Typey-base family for math mode
+
+\DeclareFontFamily{TU}{Typey-base}{}
+\DeclareFontShape{TU}{Typey-base}{\mddefault}{\shapedefault}
+ {<->"Typey McTypeface:\M@otf@features;mode=base"}{}
+\DeclareFontShape{TU}{Typey-base}{\mddefault}{\itdefault}
+ {<->"Typey McTypeface/I:\M@otf@features;mode=base"}{}
+\DeclareFontShape{TU}{Typey-base}{\bfdefault}{\shapedefault}
+ {<->"Typey McTypeface:\M@otf@features;embolden=6;mode=base"}{}
+\DeclareFontShape{TU}{Typey-base}{\bfdefault}{\itdefault}
+ {<->"Typey McTypeface/I:\M@otf@features;embolden=6;mode=base"}{}
\setfont{Typey}
\mathfont[]{STIXGeneral}
\DeclareSymbolFont{Mroman2}{TU}{STIXGeneral}{m}{n}
@@ -6003,8 +6055,8 @@ This is Typey McTypeface with Crimson for the radical signs and STIXGeneral for
%<*heading>
% package date and edition
-\def\packagedate{November 2022}
-\def\packageversion{2.1}
+\def\packagedate{December 2022}
+\def\packageversion{2.2}
% header and footer commands
@@ -6059,6 +6111,7 @@ This is Typey McTypeface with Crimson for the radical signs and STIXGeneral for
\egroup
\def\topfraction{1}
\def\bottomfraction{1}
+\let\code\@undefined
\newenvironment{code}
{\strut\vadjust\bgroup\medskip\parindent\z@\leftskip2em\relax
\noindent\strut\ignorespaces}
diff --git a/macros/latex/contrib/mathfont/mathfont_code.pdf b/macros/latex/contrib/mathfont/mathfont_code.pdf
index bc13cf288a..bfaf4e1268 100644
--- a/macros/latex/contrib/mathfont/mathfont_code.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_code.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_example_cormorant.pdf b/macros/latex/contrib/mathfont/mathfont_example_cormorant.pdf
index fd96765a92..ef8e4439c2 100644
--- a/macros/latex/contrib/mathfont/mathfont_example_cormorant.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_example_cormorant.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_example_kelvinch.pdf b/macros/latex/contrib/mathfont/mathfont_example_kelvinch.pdf
index 971da39b76..3ba6738320 100644
--- a/macros/latex/contrib/mathfont/mathfont_example_kelvinch.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_example_kelvinch.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_example_roboto.pdf b/macros/latex/contrib/mathfont/mathfont_example_roboto.pdf
index 80c4022a38..221f66ba6b 100644
--- a/macros/latex/contrib/mathfont/mathfont_example_roboto.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_example_roboto.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_example_typey.pdf b/macros/latex/contrib/mathfont/mathfont_example_typey.pdf
index efc1846e4e..25b8de0567 100644
--- a/macros/latex/contrib/mathfont/mathfont_example_typey.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_example_typey.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_symbol_list.pdf b/macros/latex/contrib/mathfont/mathfont_symbol_list.pdf
index 53981a25a3..13281e93c0 100644
--- a/macros/latex/contrib/mathfont/mathfont_symbol_list.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_symbol_list.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathfont/mathfont_user_guide.pdf b/macros/latex/contrib/mathfont/mathfont_user_guide.pdf
index 1a94d2b93f..b55e9db8fe 100644
--- a/macros/latex/contrib/mathfont/mathfont_user_guide.pdf
+++ b/macros/latex/contrib/mathfont/mathfont_user_guide.pdf
Binary files differ