From d5a1dce5fb16134a008ec1af895e89c753bcc3b2 Mon Sep 17 00:00:00 2001 From: Jeff LANCE Date: Thu, 27 May 2021 12:36:36 +0200 Subject: [PATCH] try to adapt to pdflatex --- commun/commun.sty | 48 +++++++++++++++++++++++------------------ shortcuts/shortcuts.sty | 12 +++++------ 2 files changed, 33 insertions(+), 27 deletions(-) diff --git a/commun/commun.sty b/commun/commun.sty index 8e83696..7ef48e9 100644 --- a/commun/commun.sty +++ b/commun/commun.sty @@ -136,7 +136,9 @@ % % Set the default monospaced font -\setmonofont[StylisticSet=3]{Inconsolatazi4} +\ifluatex + \setmonofont[StylisticSet=3]{Inconsolatazi4} +\fi % tasks \settasks{ @@ -396,26 +398,30 @@ % % -\newfontfamily\Annie[Ligatures=TeX]{Annie Use Your Telescope} -\newfontfamily\Architects[Ligatures=TeX]{Architects Daughter} -\newfontfamily\Bristol[Ligatures=TeX]{Bristol} -\newfontfamily\ChelseaMarket[Ligatures=TeX]{Chelsea Market} -\newfontfamily\DejaVuSans[Ligatures=TeX]{DejaVu Sans} -\newfontfamily\dominofont[Ligatures=TeX]{DejaVu Sans} -\newfontfamily\Delius[Ligatures=TeX]{Delius} -\newfontfamily\DeliusSC[Ligatures=TeX]{Delius Swash Caps} -\newfontfamily\FingerPaint[Ligatures=TeX]{Finger Paint} -\newfontfamily\Handlee[Ligatures=TeX]{Handlee} -\newfontfamily\Jd[Ligatures=TeX]{j.d.} -\newfontfamily\Julee[Ligatures=TeX]{Julee} -\newfontfamily\Morse[Ligatures=TeX]{Morse} -\newfontfamily\NixieOne[Ligatures=TeX]{Nixie One} -\newfontfamily\PenguinAttack[Ligatures=TeX]{PenguinAttack} -\newfontfamily\PokemonHollow[Ligatures=TeX]{Pokemon Hollow} -\newfontfamily\PokemonSolid[Ligatures=TeX]{Pokemon Solid} -\newfontfamily\Purisa[Ligatures=TeX]{Purisa} -\newfontfamily\ScratchedLetters[Ligatures=TeX]{Scratched Letters} -\newfontfamily\Lato[Ligatures=TeX]{Lato} +\ifluatex + \newfontfamily\Annie[Ligatures=TeX]{Annie Use Your Telescope} + \newfontfamily\Architects[Ligatures=TeX]{Architects Daughter} + \newfontfamily\Bristol[Ligatures=TeX]{Bristol} + \newfontfamily\ChelseaMarket[Ligatures=TeX]{Chelsea Market} + \newfontfamily\DejaVuSans[Ligatures=TeX]{DejaVu Sans} + \newfontfamily\dominofont[Ligatures=TeX]{DejaVu Sans} + \newfontfamily\Delius[Ligatures=TeX]{Delius} + \newfontfamily\DeliusSC[Ligatures=TeX]{Delius Swash Caps} + \newfontfamily\FingerPaint[Ligatures=TeX]{Finger Paint} + \newfontfamily\Handlee[Ligatures=TeX]{Handlee} + \newfontfamily\Jd[Ligatures=TeX]{j.d.} + \newfontfamily\Julee[Ligatures=TeX]{Julee} + \newfontfamily\Morse[Ligatures=TeX]{Morse} + \newfontfamily\NixieOne[Ligatures=TeX]{Nixie One} + \newfontfamily\PenguinAttack[Ligatures=TeX]{PenguinAttack} + \newfontfamily\PokemonHollow[Ligatures=TeX]{Pokemon Hollow} + \newfontfamily\PokemonSolid[Ligatures=TeX]{Pokemon Solid} + \newfontfamily\Purisa[Ligatures=TeX]{Purisa} + \newfontfamily\ScratchedLetters[Ligatures=TeX]{Scratched Letters} + \newfontfamily\Lato[Ligatures=TeX]{Lato} +% \else +% \newcommand\Jd[1]{{\usefont{T1}{j.d.}{m}{n} #1 } +\fi %-------------------------------------------------------- % Intent for a more general command. diff --git a/shortcuts/shortcuts.sty b/shortcuts/shortcuts.sty index b783783..456dacd 100644 --- a/shortcuts/shortcuts.sty +++ b/shortcuts/shortcuts.sty @@ -125,10 +125,10 @@ % double quoting %% -\NewDocumentCommand \og { }{ +\RenewDocumentCommand \og { }{ << } -\NewDocumentCommand \fg { }{ +\RenewDocumentCommand \fg { }{ >> } @@ -216,9 +216,9 @@ %% \NewDocumentCommand \coord { s m }{ \IfBooleanTF { #1 } { - \uplet*{#1} + \uplet*{#2} }{ - \uplet{#1} + \uplet{#2} } } @@ -324,7 +324,7 @@ } } } -\RenewDocumentCommand \C { s g } { +\ProvideDocumentCommand \C { s g } { \IfBooleanTF {#1} { \IfNoValueTF {#2} { \ensuremath{\mathbb{C} \setminus \{0\}} @@ -349,7 +349,7 @@ } }{ \ensuremath{ - \overrightarrow{#1\vphantom(} \cdot \overrightarrow{#2\vphantom(} + \overrightarrow{#2\vphantom(} \cdot \overrightarrow{#3\vphantom(} } } }