summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-08-22 22:44:45 +0000
committerKarl Berry <karl@freefriends.org>2023-08-22 22:44:45 +0000
commita3dafb4266d952ee8f9f70de327d8a77ff7738ec (patch)
tree5149b26c2a6c4144397d27c1e51fff2cf3b51b9d /Master/texmf-dist/tex
parenta277d8784243616c436c6c095a9fd9de33c8b006 (diff)
notomath (23aug23)
git-svn-id: svn://tug.org/texlive/trunk@68014 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r--Master/texmf-dist/tex/latex/notomath/notomath.sty77
1 files changed, 40 insertions, 37 deletions
diff --git a/Master/texmf-dist/tex/latex/notomath/notomath.sty b/Master/texmf-dist/tex/latex/notomath/notomath.sty
index 715d9d341ba..9939912d3bc 100644
--- a/Master/texmf-dist/tex/latex/notomath/notomath.sty
+++ b/Master/texmf-dist/tex/latex/notomath/notomath.sty
@@ -1,6 +1,6 @@
\NeedsTeXFormat{LaTeX2e}
-\def\fileversion{1.00}
-\def\filedate{2020/08/04}
+\def\fileversion{1.03}
+\def\filedate{2023/08/21}
\ProvidesPackage{notomath}
[\filedate\space v\fileversion.\space (Michael Sharpe) Supports Noto text and math fonts for LaTeX usage.]
@@ -16,55 +16,58 @@
\newcommand*{\NotoMath@scale}{1}
\newcommand*{\NotoText@scale}{1}
\newif\ifnoto@sfdefault \noto@sfdefaultfalse
-\newif\ifnoto@pf \noto@pffalse
-\newif\ifnoto@osf \noto@osffalse
+%\newif\ifnoto@pf \noto@pffalse
+%\newif\ifnoto@osf \noto@osffalse
%\newcommand*{\NotoSerifMono@scale}{1}
+\newcommand{\noto@MO}[1]{\PassOptionsToPackage{#1}{newtxmath}}% pass math option
+\newcommand{\noto@TO}[1]{\PassOptionsToPackage{#1}{noto-serif}\PassOptionsToPackage{#1}{noto-sans}
+}% pass text option to each possible text font
+\newcommand{\noto@TTO}[1]{\PassOptionsToPackage{#1}{noto-mono}}
+\noto@TTO{type1}
\DeclareOptionX{scaled}{\renewcommand*{\NotoMath@scale}{#1}}
\DeclareOptionX{scale}{\renewcommand*{\NotoMath@scale}{#1}}
-\edef\noto@mopt{noto}
-
\newif\ifnotomath@mono \notomath@monofalse
-\DeclareOptionX{sfdefault}{\edef\noto@mopt{notosans}\noto@sfdefaulttrue}
-\DeclareOptionX{proportional}{\noto@pftrue}
-\DeclareOptionX{pf}{\noto@pftrue}
-\DeclareOptionX{oldstyle}{\noto@osftrue}
-\DeclareOptionX{osf}{\noto@osftrue}
+\DeclareOptionX{sfdefault}{\noto@sfdefaulttrue}
+\DeclareOptionX{proportional}{\noto@TO{pf}}
+\DeclareOptionX{pf}{\noto@TO{pf}}
+\DeclareOptionX{oldstyle}{\noto@TO{osf}}
+\DeclareOptionX{osf}{\noto@TO{osf}}
\DeclareOptionX{mono}{\notomath@monotrue}
-\DeclareOptionX{varbb}{\edef\noto@mopt{\noto@mopt,varbb}}
-\DeclareOptionX{vvarbb}{\edef\noto@mopt{\noto@mopt,vvarbb}}
-\DeclareOptionX{upint}{\edef\noto@mopt{\noto@mopt,upint}}
-\DeclareOptionX{noamssymbols}{\edef\noto@mopt{\noto@mopt,noamssymbols}}
-\DeclareOptionX{slantedGreek}{\edef\noto@mopt{\noto@mopt,slantedGreek}}
-\DeclareOptionX{frenchmath}{\edef\noto@mopt{\noto@mopt,frenchmath}}
-\DeclareOptionX{nosymbolsc}{\edef\noto@mopt{\noto@mopt,nosymbolsc}}
-\DeclareOptionX{subscriptcorrection}{\edef\noto@mopt{\noto@mopt,subscriptcorrection}}
-\DeclareOptionX{timesmathacc}{\edef\noto@mopt{\noto@mopt,timesmathacc}}
-\DeclareOptionX{uprightscript}{\edef\noto@mopt{\noto@mopt,uprightscript}}
-\DeclareOptionX{smallerops}{\edef\noto@mopt{\noto@mopt,smallerops}}
-\DeclareOptionX{useBImacros}{\edef\noto@mopt{\noto@mopt,useBImacros}}
-\DeclareOptionX{noOT1}{\edef\noto@mopt{\noto@mopt,noOT1}}
+\DeclareOptionX{varbb}{\noto@MO{varbb}}
+\DeclareOptionX{vvarbb}{\noto@MO{vvarbb}}
+\DeclareOptionX{upint}{\noto@MO{upint}}
+\DeclareOptionX{noamssymbols}{\noto@MO{noamssymbols}}
+\DeclareOptionX{slantedGreek}{\noto@MO{slantedGreek}}
+\DeclareOptionX{frenchmath}{\noto@MO{frenchmath}}
+\DeclareOptionX{nosymbolsc}{\noto@MO{nosymbolsc}}
+\DeclareOptionX{subscriptcorrection}{\noto@MO{subscriptcorrection}}
+\DeclareOptionX{timesmathacc}{\noto@MO{timesmathacc}}
+\DeclareOptionX{uprightscript}{\noto@MO{uprightscript}}
+\DeclareOptionX{smallerops}{\noto@MO{smallerops}}
+\DeclareOptionX{useBImacros}{\noto@MO{useBImacros}}
+\DeclareOptionX{noOT1}{\noto@MO{noOT1}}
\ProcessOptionsX\relax
-\edef\noto@mopt{scale=\NotoMath@scale,\noto@mopt}
-%\show\noto@mopt
+
+\ifnoto@sfdefault{\noto@MO{notosans}\else\noto@MO{noto}\fi
+%\edef\noto@mopt{scale=\NotoMath@scale,\noto@mopt}
\newdimen\notomath@dima
% use the scale for math to set noto text scale factors
\notomath@dima=\NotoMath@scale\p@
\notomath@dima=.9\notomath@dima
\edef\NotoText@scale{\strip@pt\notomath@dima}
-%\let\NotoSans@scale\NotoText@scale
-%\let\NotoSansMono@scale\NotoSerif@scale
-\edef\nototext@opt{scale=\NotoText@scale}
-\ifnoto@pf\edef\nototext@opt{\nototext@opt,pf}\fi
-\ifnoto@osf\edef\nototext@opt{\nototext@opt,osf}\fi
-\usepackage[\nototext@opt]{noto-serif}
-\ifnoto@sfdefault\edef\nototext@opt{\nototext@opt,sfdefault}\fi
-\usepackage[\nototext@opt]{noto-sans}
-\ifnotomath@mono\usepackage[type1,scale=\NotoText@scale]{noto-mono}\fi
-%\show\noto@mopt
-\usepackage[\noto@mopt]{newtxmath}
+
+\noto@TO{scale=\NotoText@scale}
+\noto@TTO{scale=\NotoText@scale}
+\noto@MO{scale=\NotoMath@scale}
+
+\ifnotomath@mono\usepackage{noto-mono}\fi
+\usepackage{noto-serif}
+\ifnoto@sfdefault\noto@TO{sfdefault}\fi
+\usepackage{noto-sans}
+\usepackage{newtxmath}
\def\seriesdefault{\mdseries@rm}
\def\mdseries@rm{m}
\def\bfseries@rm{b}