summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty')
-rw-r--r--Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty176
1 files changed, 130 insertions, 46 deletions
diff --git a/Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty b/Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty
index 65af90c5b62..eca931db9a8 100644
--- a/Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty
+++ b/Master/texmf-dist/tex/latex/greek-fontenc/alphabeta.sty
@@ -14,7 +14,7 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{alphabeta}
-[2013/09/11 v0.4 macros for Greek letters in text and math]
+[2015/09/04 v0.13 macros for Greek letters in text and math]
% Changelog:
% .. class:: borderless
@@ -25,6 +25,7 @@
% 2013-05-28 0.3 use ``lgrenc.def`` from greek-fontenc,
% .. enable Unicode input in math mode.
% 2013-09-11 0.4 move to greek-fontenc_, support XeTeX/LuaTeX.
+% 2015-09-04 0.13 Support for `variant symbols`.
% ========== ===== =========================================================
%
% Motivation
@@ -59,6 +60,15 @@
%
% \usepackage{alphabeta}
%
+% The greek-inputenc_ package provides support for Unicode (utf-8) input
+% of Greek characters with 8-bit TeX and the inputenc_ package:
+%
+% .. code:: latex
+%
+% \usepackage[utf-8]{inputenc}
+% \usepackage{alphabeta}
+%
+%
% For details see `<alphabeta-doc.tex>`_ and `<alphabeta-doc.pdf>`_.
%
%
@@ -68,12 +78,12 @@
% Requirements
% ------------
%
-% This package extends the `textalpha <textalpha.sty.html>`_ package::
+% This package extends the `textalpha <textalpha.sty.html>`_ package.
+% Package options are passed on to `textalpha`::
-\RequirePackage{textalpha}
+\RequirePackageWithOptions{textalpha}
-% `textalpha` depends on greek-fontenc_ and (with 8-bit TeX) recommends
-% greek-inputenc_.
+% Just like `alphabeta`, `textalpha` is part of greek-fontenc_.
%
% This package requires the e-TeX_ extensions (i.e. a not too old TeX
% distribution) for the ``\ifdefined`` test.
@@ -81,8 +91,8 @@
% It uses the ``\TextOrMath`` test from the fixltx2e_ standard LaTeX
% package::
-\RequirePackage{fixltx2e}
-
+% fixltx2e is not required with releases after 2015
+%\RequirePackage{fixltx2e}
% Postpone the re-definitions
% ---------------------------
@@ -114,9 +124,11 @@
\let\mathgamma\gamma
\let\mathdelta\delta
\let\mathepsilon\epsilon
+\let\mathvarepsilon\varepsilon
\let\mathzeta\zeta
\let\matheta\eta
\let\maththeta\theta
+\let\mathvartheta\vartheta
\let\mathiota\iota
\let\mathkappa\kappa
\let\mathlambda\lambda
@@ -124,12 +136,16 @@
\let\mathnu\nu
\let\mathxi\xi
\let\mathpi\pi
+\let\mathvarpi\varpi
\let\mathrho\rho
+\let\mathvarrho\varrho
\let\mathsigma\sigma
\let\mathvarsigma\varsigma
+\let\mathfinalsigma\varsigma
\let\mathtau\tau
\let\mathupsilon\upsilon
\let\mathphi\phi
+\let\mathvarphi\varphi
\let\mathchi\chi
\let\mathpsi\psi
\let\mathomega\omega
@@ -137,6 +153,13 @@
\providecommand*{\digamma}{\textit{\textdigamma}}
\let\mathdigamma\digamma
+% \varkappa and \varbeta are defined by some math packages
+\ifdefined\varbeta
+ \let\mathvarbeta\varbeta
+\fi
+\ifdefined\varkappa % e.g. with newtxmath
+ \let\mathvarkappa\varkappa
+\fi
% Commands to access Greek letters by name
% ----------------------------------------
@@ -147,6 +170,21 @@
% used as variable symbols in math formulas. These letters are not defined in
% TeX's math mode, we provide an alias to the corrsponding ``\text...``
% command.
+%
+% Mathematical notation distinguishes `variant shape symbols`_ for pi, phi,
+% rho, theta (small and capital), beta, and kappa (characters for the latter
+% three symbols are not included in TeX’s math fonts). These variations have
+% no syntactic meaning in Greek text and are not given code-points in the LGR
+% encoding while Unicode defines separate code points for the symbol variants.
+%
+% Greek Alphabet:
+%
+% Macros keep their meaning in mathematical mode (i.e. use the same shape as
+% without this package) and refer to GREEK LETTER ... in text. For
+% ``\epsilon`` and ``phi``, this means that the selected symbol variant
+% differs in text vs. math mode. Use ``\varepsilon`` and ``\varphi`` (see
+% section `variant shape symbols`_ below) to select the GREEK LETTER ...” in both,
+% text and math mode.
% ::
\providecommand*{\Alpha}{\textAlpha}
@@ -178,7 +216,7 @@
\renewcommand*{\beta}{\TextOrMath{\textbeta}{\mathbeta}}
\renewcommand*{\gamma}{\TextOrMath{\textgamma}{\mathgamma}}
\renewcommand*{\delta}{\TextOrMath{\textdelta}{\mathdelta}}
-\renewcommand*{\epsilon}{\TextOrMath{\textepsilon}{\mathepsilon}}
+\renewcommand*{\epsilon}{\TextOrMath{\textepsilon}{\mathepsilon}} % ε/ϵ
\renewcommand*{\zeta}{\TextOrMath{\textzeta}{\mathzeta}}
\renewcommand*{\eta}{\TextOrMath{\texteta}{\matheta}}
\renewcommand*{\theta}{\TextOrMath{\texttheta}{\maththeta}}
@@ -196,7 +234,7 @@
\providecommand*{\finalsigma}{\varsigma}
\renewcommand*{\tau}{\TextOrMath{\texttau}{\mathtau}}
\renewcommand*{\upsilon}{\TextOrMath{\textupsilon}{\mathupsilon}}
-\renewcommand*{\phi}{\TextOrMath{\textphi}{\mathphi}}
+\renewcommand*{\phi}{\TextOrMath{\textphi}{\mathphi}} % ϕ/φ
\renewcommand*{\chi}{\TextOrMath{\textchi}{\mathchi}}
\renewcommand*{\psi}{\TextOrMath{\textpsi}{\mathpsi}}
\renewcommand*{\omega}{\TextOrMath{\textomega}{\mathomega}}
@@ -218,6 +256,46 @@
\providecommand*{\Sampi}{\textSampi} % Ϡ
\providecommand*{\sampi}{\textsampi} % ϡ
+% Variant shape symbols
+% '''''''''''''''''''''
+%
+% TeX’s concept of “standard” vs. “variant” math symbols does not map to the
+% distinction between GREEK LETTER ... vs. GREEK ... SYMBOL in the Unicode
+% standard (see `<greek-euenc-doc.pdf>`_).
+%
+% The ``\...symbol`` macros select the GREEK ... SYMBOL in both, text and
+% math mode. For ``\epsilonsymbol`` and ``\phisymbol`` this is the default
+% shape in math mode. The ``\var...`` macros select the shape used by TeX
+% math (or, if not supported, the SYMBOL shape)::
+
+% ..symbol == var..
+\renewcommand*{\varpi}{\TextOrMath{\textpisymbol}{\mathvarpi}} % ϖ
+\providecommand*{\pisymbol}{\varpi} % ϖ
+\renewcommand*{\varrho}{\TextOrMath{\textrhosymbol}{\mathvarrho}} % ϱ
+\providecommand*{\rhosymbol}{\TextOrMath{\textrhosymbol}{\mathvarrho}} % ϱ
+\renewcommand*{\vartheta}{\TextOrMath{\textthetasymbol}{\mathvartheta}} % ϑ
+\providecommand*{\thetasymbol}{\vartheta} % ϑ
+% ..symbol != var..
+\renewcommand*{\varepsilon}{\TextOrMath{\textepsilon}{\mathvarepsilon}} % ε
+\providecommand*{\epsilonsymbol}{\TextOrMath{\textepsilonsymbol}{\mathepsilon}} % ϵ
+\renewcommand*{\varphi}{\TextOrMath{\textphi}{\mathvarphi}} % φ
+\providecommand*{\phisymbol}{\TextOrMath{\textphisymbol}{\mathphi}} % ϕ
+% only text (in standard 8-bit TeX, may be defined with additional packages):
+\ifdefined\mathvarbeta
+ \renewcommand*{\varbeta}{\TextOrMath{\textbetasymbol}{\mathvarbeta}} % ϐ
+\else
+ \providecommand*{\varbeta}{\textbetasymbol}
+\fi
+\providecommand*{\betasymbol}{\varbeta}
+\ifdefined\mathvarkappa % ϰ
+ \renewcommand*{\varkappa}{\TextOrMath{\textkappasymbol}{\mathvarkappa}}
+\else
+ \providecommand*{\varkappa}{\textkappasymbol}
+\fi
+\providecommand*{\kappasymbol}{\varkappa}
+% \Theta/\varTheta are not a symbol variants but upright/italic shape of Theta
+\providecommand*{\Thetasymbol}{\textThetasymbol} % ϴ
+
% TextCompositeCommands for the generic macros
% --------------------------------------------
@@ -245,50 +323,56 @@
% Check with ``\ifdefined`` for the definition of
% ``\DeclareUnicodeCharacter``. In contrast to ``\@ifdefined``, this works
% without side-effects. It makes the package dependent on the `e-TeX`_
-% extensions but theses are standard in all current TeX distributions anyway.
+% extensions but these are standard in all current TeX distributions anyway.
%
% Map Greek characters that are also defined in math mode to the generic
% macros::
\ifdefined\DeclareUnicodeCharacter
- \DeclareUnicodeCharacter{0393}{\Gamma} % Γ
- \DeclareUnicodeCharacter{0394}{\Delta} % Δ
- \DeclareUnicodeCharacter{0398}{\Theta} % Θ
- \DeclareUnicodeCharacter{039B}{\Lambda} % Λ
- \DeclareUnicodeCharacter{039E}{\Xi} % Ξ
- \DeclareUnicodeCharacter{03A0}{\Pi} % Π
- \DeclareUnicodeCharacter{03A3}{\Sigma} % Σ
- \DeclareUnicodeCharacter{03A5}{\Upsilon} % Υ
- \DeclareUnicodeCharacter{03A6}{\Phi} % Φ
- \DeclareUnicodeCharacter{03A8}{\Psi} % Ψ
- \DeclareUnicodeCharacter{03A9}{\Omega} % Ω
+ \DeclareUnicodeCharacter{0393}{\Gamma} % Γ
+ \DeclareUnicodeCharacter{0394}{\Delta} % Δ
+ \DeclareUnicodeCharacter{0398}{\Theta} % Θ
+ \DeclareUnicodeCharacter{039B}{\Lambda} % Λ
+ \DeclareUnicodeCharacter{039E}{\Xi} % Ξ
+ \DeclareUnicodeCharacter{03A0}{\Pi} % Π
+ \DeclareUnicodeCharacter{03A3}{\Sigma} % Σ
+ \DeclareUnicodeCharacter{03A5}{\Upsilon} % Υ
+ \DeclareUnicodeCharacter{03A6}{\Phi} % Φ
+ \DeclareUnicodeCharacter{03A8}{\Psi} % Ψ
+ \DeclareUnicodeCharacter{03A9}{\Omega} % Ω
+
+ \DeclareUnicodeCharacter{03B1}{\alpha} % α
+ \DeclareUnicodeCharacter{03B2}{\beta} % β
+ \DeclareUnicodeCharacter{03B3}{\gamma} % γ
+ \DeclareUnicodeCharacter{03B4}{\delta} % δ
+ \DeclareUnicodeCharacter{03B5}{\varepsilon} % ε textepsilon/varepsilon
+ \DeclareUnicodeCharacter{03B6}{\zeta} % ζ
+ \DeclareUnicodeCharacter{03B7}{\eta} % η
+ \DeclareUnicodeCharacter{03B8}{\theta} % θ
+ \DeclareUnicodeCharacter{03B9}{\iota} % ι
+ \DeclareUnicodeCharacter{03BA}{\kappa} % κ
+ \DeclareUnicodeCharacter{03BB}{\lambda} % λ
+ \DeclareUnicodeCharacter{03BC}{\mu} % μ
+ \DeclareUnicodeCharacter{03BD}{\nu} % ν
+ \DeclareUnicodeCharacter{03BE}{\xi} % ξ
+ \DeclareUnicodeCharacter{03C0}{\pi} % π
+ \DeclareUnicodeCharacter{03C1}{\rho} % ρ
+ \DeclareUnicodeCharacter{03C2}{\varsigma} % ς
+ \DeclareUnicodeCharacter{03C3}{\sigma} % σ
+ \DeclareUnicodeCharacter{03C4}{\tau} % τ
+ \DeclareUnicodeCharacter{03C5}{\upsilon} % υ
+ \DeclareUnicodeCharacter{03C6}{\varphi} % φ textphi/varphi
+ \DeclareUnicodeCharacter{03C7}{\chi} % χ
+ \DeclareUnicodeCharacter{03C8}{\psi} % ψ
+ \DeclareUnicodeCharacter{03C9}{\omega} % ω
- \DeclareUnicodeCharacter{03B1}{\alpha} % α
- \DeclareUnicodeCharacter{03B2}{\beta} % β
- \DeclareUnicodeCharacter{03B3}{\gamma} % γ
- \DeclareUnicodeCharacter{03B4}{\delta} % δ
- \DeclareUnicodeCharacter{03B5}{\epsilon} % ε
- \DeclareUnicodeCharacter{03B6}{\zeta} % ζ
- \DeclareUnicodeCharacter{03B7}{\eta} % η
- \DeclareUnicodeCharacter{03B8}{\theta} % θ
- \DeclareUnicodeCharacter{03B9}{\iota} % ι
- \DeclareUnicodeCharacter{03BA}{\kappa} % κ
- \DeclareUnicodeCharacter{03BB}{\lambda} % λ
- \DeclareUnicodeCharacter{03BC}{\mu} % μ
- \DeclareUnicodeCharacter{03BD}{\nu} % ν
- \DeclareUnicodeCharacter{03BE}{\xi} % ξ
- \DeclareUnicodeCharacter{03C0}{\pi} % π
- \DeclareUnicodeCharacter{03C1}{\rho} % ρ
- \DeclareUnicodeCharacter{03C2}{\varsigma} % ς
- \DeclareUnicodeCharacter{03C3}{\sigma} % σ
- \DeclareUnicodeCharacter{03C4}{\tau} % τ
- \DeclareUnicodeCharacter{03C5}{\upsilon} % υ
- \DeclareUnicodeCharacter{03C6}{\phi} % φ
- \DeclareUnicodeCharacter{03C7}{\chi} % χ
- \DeclareUnicodeCharacter{03C8}{\psi} % ψ
- \DeclareUnicodeCharacter{03C9}{\omega} % ω
+ \DeclareUnicodeCharacter{03D1}{\thetasymbol} % ϑ
+ \DeclareUnicodeCharacter{03D5}{\phisymbol} % ϕ $\phi$
+ \DeclareUnicodeCharacter{03D6}{\pisymbol} % ϖ
+ \DeclareUnicodeCharacter{03DD}{\digamma} % ϝ
+ \DeclareUnicodeCharacter{03F1}{\rhosymbol} % ϱ
+ \DeclareUnicodeCharacter{03F5}{\epsilonsymbol} % ϵ $\epsilon$
- \DeclareUnicodeCharacter{03DD}{\digamma} % ϝ
\fi
% ::