summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/frenchmath
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2022-10-26 20:01:49 +0000
committerKarl Berry <karl@freefriends.org>2022-10-26 20:01:49 +0000
commit6c4d5ccb1ad74b03e8e20a9ae49e1d8d88b233bf (patch)
treec226d4968d2678df6124fe3e03a6b9449e13c08a /Master/texmf-dist/tex/latex/frenchmath
parent970dfb5cce2f77432281bd2a31d2d6956b92f899 (diff)
frenchmath (26oct22)
git-svn-id: svn://tug.org/texlive/trunk@64823 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/frenchmath')
-rw-r--r--Master/texmf-dist/tex/latex/frenchmath/frenchmath.sty168
1 files changed, 129 insertions, 39 deletions
diff --git a/Master/texmf-dist/tex/latex/frenchmath/frenchmath.sty b/Master/texmf-dist/tex/latex/frenchmath/frenchmath.sty
index cb618303dbe..fb17dad33a6 100644
--- a/Master/texmf-dist/tex/latex/frenchmath/frenchmath.sty
+++ b/Master/texmf-dist/tex/latex/frenchmath/frenchmath.sty
@@ -22,22 +22,35 @@
%%
\NeedsTeXFormat{LaTeX2e}[2005/12/01]
\ProvidesPackage{frenchmath}
-[2022/10/16 v1.6 .dtx frenchmath file]
+ [2022/10/25 v2.0 .dtx frenchmath file]
\RequirePackage{ifthen}
\newboolean{capsit}
\DeclareOption{capsit}{\setboolean{capsit}{true}}
+\newboolean{upgreek}
+\newboolean{Upgreek}
+\DeclareOption{upgreek}{\setboolean{upgreek}{true}}
+\DeclareOption{Upgreek}{\setboolean{upgreek}{true}
+ \setboolean{Upgreek}{true}}
\ProcessOptions \relax
-\RequirePackage{mathrsfs} % fournit les majuscules cursives
-\RequirePackage{amssymb} % fournit \leqslant, \geqslant et \varnothing
+\@ifpackageloaded{mathdesign}{
+ \PackageWarningNoLine{frenchmath}{Package mathdesign is loaded,
+ I don't load mathrsfs and amssymb packages}
+}{
+ \RequirePackage{mathrsfs} % fournit les majuscules cursives
+ \RequirePackage{amssymb} % fournit \leqslant, \geqslant, \varnothing
+}
\RequirePackage{amsopn} % fournit \DeclareMathOperator
\RequirePackage{xspace} % utile pour les commandes \curs, \ssi, \Oij
\RequirePackage{ncccomma} % virgule intelligente
\AtBeginDocument{\mathcode`\,="8000\relax
- \@ifpackageloaded{babel}{\addto\extrasfrench{\mathcode`\,="8000\relax}}{}}
-
-\ifthenelse{\boolean{capsit}}{}{\AtBeginDocument{
- \DeclareMathSymbol{A}\mathalpha{operators}{`A} %'A codage octal du A
+ \@ifpackageloaded{babel}{
+ \addto\extrasfrench{\mathcode`\,="8000\relax}
+ }{}
+}
+\ifthenelse{\boolean{capsit}}{}{
+ \AtBeginDocument{
+ \DeclareMathSymbol{A}\mathalpha{operators}{`A}
\DeclareMathSymbol{B}\mathalpha{operators}{`B}
\DeclareMathSymbol{C}\mathalpha{operators}{`C}
\DeclareMathSymbol{D}\mathalpha{operators}{`D}
@@ -63,7 +76,88 @@
\DeclareMathSymbol{X}\mathalpha{operators}{`X}
\DeclareMathSymbol{Y}\mathalpha{operators}{`Y}
\DeclareMathSymbol{Z}\mathalpha{operators}{`Z}
- }}
+ }
+}
+
+\ifthenelse{\boolean{upgreek}}{
+ \@ifpackageloaded{upgreek}{}{\RequirePackage[Euler]{upgreek}}
+ \@ifundefined{italpha}{\let\italpha\alpha}{
+ \PackageWarningNoLine{frenchmath}{Italicized Greek \bslash italpha
+ also defined, no more warning for the other letters}
+ }
+ \@ifundefined{itbeta}{\let\itbeta\beta}{}
+ \@ifundefined{itgamma}{\let\itgamma\gamma}{}
+ \@ifundefined{itdelta}{\let\itdelta\delta}{}
+ \@ifundefined{itepsilon}{\let\itepsilon\epsilon}{}
+ \@ifundefined{itzeta}{\let\itzeta\zeta}{}
+ \@ifundefined{iteta}{\let\iteta\eta}{}
+ \@ifundefined{ittheta}{\let\ittheta\theta}{}
+ \@ifundefined{itiota}{\let\itiota\iota}{}
+ \@ifundefined{itkappa}{\let\itkappa\kappa}{}
+ \@ifundefined{itlambda}{\let\itlambda\lambda}{}
+ \@ifundefined{itmu}{\let\itmu\mu}{}
+ \@ifundefined{itnu}{\let\itnu\nu}{}
+ \@ifundefined{itxi}{\let\itxi\xi}{}
+ \@ifundefined{itpi}{\let\itpi\pi}{}
+ \@ifundefined{itrho}{\let\itrho\rho}{}
+ \@ifundefined{itsigma}{\let\itsigma\sigma}{}
+ \@ifundefined{ittau}{\let\ittau\tau}{}
+ \@ifundefined{itupsilon}{\let\itupsilon\upsilon}{}
+ \@ifundefined{itphi}{\let\itphi\phi}{}
+ \@ifundefined{itchi}{\let\itchi\chi}{}
+ \@ifundefined{itpsi}{\let\itpsi\psi}{}
+ \@ifundefined{itomega}{\let\itomega\omega}{}
+ \@ifundefined{itvarepsilon}{\let\itvarepsilon\varepsilon}{}
+ \@ifundefined{itvartheta}{\let\itvartheta\vartheta}{}
+ \@ifundefined{itvarpi}{\let\itvarpi\varpi}{}
+ \@ifundefined{itvarsigma}{\let\itvarsigma\varsigma}{}
+ \@ifundefined{itvarphi}{\let\itvarphi\varphi}{}
+
+ \renewcommand\alpha{\upalpha}
+ \renewcommand\beta{\upbeta}
+ \renewcommand\gamma{\upgamma}
+ \renewcommand\delta{\updelta}
+ \renewcommand\epsilon{\upepsilon}
+ \renewcommand\zeta{\upzeta}
+ \renewcommand\eta{\upeta}
+ \renewcommand\theta{\uptheta}
+ \renewcommand\iota{\upiota}
+ \renewcommand\kappa{\upkappa}
+ \renewcommand\lambda{\uplambda}
+ \renewcommand\mu{\upmu}
+ \renewcommand\nu{\upnu}
+ \renewcommand\xi{\upxi}
+ \renewcommand\pi{\uppi}
+ \renewcommand\rho{\uprho}
+ \renewcommand\sigma{\upsigma}
+ \renewcommand\tau{\uptau}
+ \renewcommand\upsilon{\upupsilon}
+ \renewcommand\phi{\upphi}
+ \renewcommand\chi{\upchi}
+ \renewcommand\psi{\uppsi}
+ \renewcommand\omega{\upomega}
+ \renewcommand\varepsilon{\upvarepsilon}
+ \renewcommand\vartheta{\upvartheta}
+ \renewcommand\varpi{\upvarpi}
+ \renewcommand\varrho{\upvarrho}
+ \renewcommand\varsigma{\upvarsigma}
+ \renewcommand\varphi{\upvarphi}
+}{}
+
+\ifthenelse{\boolean{Upgreek}}{
+ \renewcommand\Gamma{\Upgamma}
+ \renewcommand\Delta{\Updelta}
+ \renewcommand\Theta{\Uptheta}
+ \renewcommand\Lambda{\Uplambda}
+ \renewcommand\Xi{\Upxi}
+ \renewcommand\Pi{\Uppi}
+ \renewcommand\Sigma{\Upsigma}
+ \renewcommand\Upsilon{\Upupsilon}
+ \renewcommand\Phi{\Upphi}
+ \renewcommand\Psi{\Uppsi}
+ \renewcommand\Omega{\Upomega}
+}{}
+
\DeclareMathSymbol{;}\mathbin{operators}{'73} % \mathpunct à l'origine
\AtBeginDocument{\@ifpackageloaded{pstricks-add}{\psset{comma=true}}{}}
@@ -86,48 +180,44 @@
\DeclareMathOperator{\ch}{ch}
\DeclareMathOperator{\sh}{sh}
\AtBeginDocument{\let\oldth\th %\th existe déjà (mode texte uniquement)
- \renewcommand{\th}{\TextOrMath{\oldth}{\mathop{\operatorfont th}}}
-}
+\renewcommand{\th}{\TextOrMath{\oldth}{\mathop{\operatorfont th}}}}
+{\catcode`\|=\z@ \catcode`\\=12 |gdef|bslash{\}} % la commande \bslash
\PackageWarningNoLine{frenchmath}{
- command \bslash tgh in now obsolete, use \bslash th instead
-}
+ Command \bslash tgh in now obsolete, use \bslash th instead}
-\newcommand\@Oij{\ensuremath{
- \left(O, \vec{\imath}, \vec{\jmath}\,\right)}\xspace
-}
-\newcommand\@@Oij{\ensuremath{
- \left(O ; \vec{\imath}, \vec{\jmath}\,\right)}\xspace
-}
+
+\newcommand\@Oij{%
+ \ensuremath{\left(O, \vec{\imath}, \vec{\jmath}\,\right)}\xspace}
+\newcommand\@@Oij{%
+ \ensuremath{\left(O ; \vec{\imath}, \vec{\jmath}\,\right)}\xspace}
\newcommand\Oij{\@ifstar{\@@Oij}{\@Oij}}
-\newcommand\@Oijk{\ensuremath{
+\newcommand\@Oijk{%
+ \ensuremath{%
\left(O, \vec{\vphantom{t}\imath}, \vec{\vphantom{t}\jmath},
- \vec{\vphantom{t}\smash{k}}\,\right)
- }\xspace
-}
-\newcommand\@@Oijk{\ensuremath{
+ \vec{\vphantom{t}\smash{k}}\,\right)}%
+ \xspace}
+\newcommand\@@Oijk{%
+ \ensuremath{%
\left(O ; \vec{\vphantom{t}\imath}, \vec{\vphantom{t}\jmath},
- \vec{\vphantom{t}\smash{k}}\,\right)
- }\xspace
-}
+ \vec{\vphantom{t}\smash{k}}\,\right)}%
+ \xspace}
\newcommand\Oijk{\@ifstar{\@@Oijk}{\@Oijk}}
-\newcommand\@Ouv{\ensuremath{
- \left(O, \vec{u}, \vec{v}\,\right)}\xspace
-}
-\newcommand\@@Ouv{\ensuremath{
- \left(O ; \vec{u}, \vec{v}\,\right)}\xspace
-}
+\newcommand\@Ouv{%
+ \ensuremath{\left(O, \vec{u}, \vec{v}\,\right)}\xspace}
+\newcommand\@@Ouv{%
+ \ensuremath{\left(O ; \vec{u}, \vec{v}\,\right)}\xspace}
\newcommand\Ouv{\@ifstar{\@@Ouv}{\@Ouv}}
-\AtBeginDocument{\renewcommand\ij{\ensuremath{
- \left(\vec{\imath}, \vec{\jmath}\,\right)}\xspace
- }}
-\newcommand\ijk{\ensuremath{
+\AtBeginDocument{
+ \renewcommand\ij{%
+ \ensuremath{\left(\vec{\imath}, \vec{\jmath}\,\right)}\xspace}}
+\newcommand\ijk{%
+ \ensuremath{%
\left(\vec{\vphantom{t}\imath}, \vec{\vphantom{t}\jmath},
- \vec{\vphantom{t}\smash{k}}\,\right)
- }\xspace
-}
+ \vec{\vphantom{t}\smash{k}}\,\right)}%
+ \xspace}
\endinput
%%