summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/babel-contrib/greek
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/babel-contrib/greek
Initial commit
Diffstat (limited to 'macros/latex/contrib/babel-contrib/greek')
-rw-r--r--macros/latex/contrib/babel-contrib/greek/README248
-rw-r--r--macros/latex/contrib/babel-contrib/greek/README.html1036
-rw-r--r--macros/latex/contrib/babel-contrib/greek/athnum.dtx277
-rw-r--r--macros/latex/contrib/babel-contrib/greek/athnum.pdfbin0 -> 176656 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/babel-greek.dtx1326
-rw-r--r--macros/latex/contrib/babel-contrib/greek/babel-greek.ins105
-rw-r--r--macros/latex/contrib/babel-contrib/greek/babel-greek.pdfbin0 -> 254908 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/grmath.dtx168
-rw-r--r--macros/latex/contrib/babel-contrib/greek/grmath.pdfbin0 -> 120534 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-greek.pdfbin0 -> 234442 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-greek.tex428
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-unicode-greek.pdfbin0 -> 43050 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-unicode-greek.tex258
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.pdfbin0 -> 43380 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.tex264
-rw-r--r--macros/latex/contrib/babel-contrib/greek/usage.pdfbin0 -> 176226 bytes
-rw-r--r--macros/latex/contrib/babel-contrib/greek/usage.tex257
17 files changed, 4367 insertions, 0 deletions
diff --git a/macros/latex/contrib/babel-contrib/greek/README b/macros/latex/contrib/babel-contrib/greek/README
new file mode 100644
index 0000000000..86678690a9
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/README
@@ -0,0 +1,248 @@
+babel-greek
+***********
+Babel support for the Greek language and script
+===============================================
+
+:Copyright: © 1997 Apostolos Syropoulos, Claudio Beccari, Johannes Brahms,
+ © 2013 Günter Milde
+:Licence: This work may be distributed and/or modified under the
+ conditions of the `LaTeX Project Public License`_, either
+ version 1.3 of this license or any later version.
+
+:Abstract: Babel-greek is a contributed package providing support for the
+ Greek language and script via the Babel_ system.
+
+ The file ``greek.ldf`` provides options for the monotonic
+ (single-diacritic), polytonic (multiple-diacritic) and ancient
+ orthography of the Greek language.
+
+ Since 2013-07-19, babel-greek supports also Unicode-aware TeX
+ engines (XeTeX/LuaTeX).
+
+News
+----
+
+.. class:: borderless
+
+===== ============ ============================================================
+1.4 2013-05-17 New maintainer.
+.. The encoding definition file ``lgrenc.def`` moved to the
+ greek-fontenc_ package.
+
+1.5 2013-06-21 bugfixes and cleanup,
+.. LICR macros in string definitions,
+.. LGR font encoding not used with XeTeX/LuaTeX,
+.. input "xgreek-fixes.def" from polyglossia_ with Xe/LuaTeX.
+1.5a 2013-07-02 Fix LaTeX bugs babel/3707, `babel/4303`_ and `babel/4305`_
+1.6 2013-07-19 Experimental support for XeTeX/LuaTeX.
+1.7 2013-09-09 CB-Fonts font definition files moved to CB-Fonts package.
+.. Do not auto-load euenc.def with XeTeX/LuaTeX.
+1.7a 2013-09-13 Fix bug `babel/4360`_: spurious ``\fi``.
+1.7b 2013-10-01 bugfix: correct upcasing of babel strings with Xe/LuaTeX.
+1.8 2013-12-02 Rename ``greek.dtx`` to ``babel-greek`` so that texdoc_
+ shows the right documentation.
+.. Compatibility with Xe/LuaTeX in Unicode and 8-bit mode.
+1.8a 2013-12-03 Set ``\encodingdefault`` in ``\greekscript`` to fix
+ Greek in footnotes etc. with document language Greek.
+1.9 2014-07-20 Added attribute for ancient Greek, load correct hyphenation
+ patterns: Patch by Claudio Beccari. Bugfix for Makeuppercase
+1.9a 2014-09-12 Remove duplicate code, documentation review.
+1.9b 2014-09-18 Remove spurious whitespace from "extrasgreek" definition.
+.. Use named macros instead of non-standard short macros
+ for psili and dasia in the string definitions.
+1.9c 2014-10-21 Fix dummy hyphenation language names (patch Ulrike Fischer).
+1.9d 2015-09-04 Remove `grsymb` (macros for Greek symbols).
+ This package is outdated and obsoleted by greek-fontenc_
+ (reported by Claudio Beccari).
+.. Unicode uc/lc corrections now in greek-fontenc
+ (polyglossia's ``xgreek-fixes.def`` has bugs).
+1.9e 2015-11-27 Fix bug in lccode-setting loop (patch by Enrico Gregorio).
+1.9f 2016-02-04 Support for standard Unicode text font encoding "TU"
+ (new in fontspec v2.5a).
+1.9g 2016-09-07 Babel 3.9i deprecated ``\textlatin``
+ and fixed ``\latinencoding``.
+1.9.h 2019-07-11 Move breathing composite commands to textalpha_.
+===== ============ ============================================================
+
+
+.. _babel/4303: http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4303
+.. _babel/4305: http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4305
+.. _babel/4360: http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4360
+
+Files
+-----
+
+`<babel-greek.ins>`_; `<babel-greek.pdf>`_
+ Source of the language definition file ``greek.ldf`` for use with Babel_.
+`<athnum.dtx>`_; `<athnum.pdf>`_
+ Athenian Numerals.
+`<grmath.dtx>`_; `<grmath.pdf>`_
+ Greek log-like Operators.
+`<test-greek.pdf>`_; `<test-greek.tex>`_
+ Tests and Examples for 8-bit TeX.
+`<test-unicode-greek.pdf>`_; `<test-unicode-greek.tex>`_
+ Tests and Examples for XeTeX/LuaTeX.
+`<test-unicode-lgr.pdf>`_; `<test-unicode-lgr.tex>`_
+ Tests and Examples for XeTeX/LuaTeX with LGR 8-bit fonts.
+
+`<usage.pdf>`_; `<usage.tex>`_
+ Description of the `LGR Latin transliteration`_.
+
+
+
+Requirements
+------------
+
+The "babel-greek" package requires the babel_ base package and font
+definition files from the greek-fontenc_ package. The greek-inputenc_
+package is recommended when using 8-bit TeX engines.
+
+Typesetting Greek texts requires `Greek text fonts`_.
+
+Plain TeX is currently not supported. Patches are welcome.
+
+
+Installation
+------------
+
+If possible, get this package from your distribution using its installation
+manager.
+
+Otherwise, make sure LaTeX can find the required files:
+
+* Download and unpack `babel-greek.zip`.
+
+* Run ``tex`` or ``latex`` on the batch file ``babel-greek.ins``.
+
+ This will generate the files ``greek.ldf``, ``athnum.sty``, and
+ ``grmath.sty`` in the current directory. [#]_
+
+* Move all files ending in ``.ldf`` or ``.sty`` into a directory searched by
+ TeX.
+
+* To produce the documentation, run the file ``usage.tex`` and all files
+ ending in ``.dtx`` through LaTeX.
+
+.. [#] If these files already exist somewhere in the TeX-path, you will be
+ warned that they might be overwritten. You can ignore this
+ warning and answer `y` unless the *current directory* contains versions
+ of these files you want to keep.
+
+ This is done by docstrip_. Try ``texdoc docstrip`` for details.
+
+Usage
+-----
+
+Use the "greek" document option or pass the "greek" option to babel::
+
+ \usepackage[greek]{babel}
+
+For polytonic Greek, set the language attribute "polutoniko"::
+
+ \usepackage[greek]{babel}
+ \languageattribute{greek}{polutoniko}
+
+or ::
+
+ \usepackage[greek.polutoniko,english]{babel}
+
+Similarly, the attribute "ancient" selects the ancient Greek language
+variant.
+
+For details see `<babel-greek.pdf>`_ and the babel_ documentation.
+
+With XeTeX/LuaTeX, load fontspec_ before babel_, so that babel-greek can
+set up the Unicode font encoding for use with Greek, e.g. ::
+
+ \usepackage{fontspec}
+ \setmainfont{Linux Libertine O}
+ \setsansfont{Linux Biolinum O}
+ \usepackage[greek,english]{babel}
+
+Note, that the default font used with XeTeX/LuaTeX (Latin Modern) misses most
+Greek letters. Warnings about missing charcters are only written to the log
+file, not the console output!
+
+
+Input of Greek characters is possible as literal characters (with the
+greek-inputenc_ package or with XeTeX or LuaTeX) or the `LGR Latin
+transliteration`_. See `<usage.pdf>`_ and the example files provided with
+greek-fontenc_.
+
+Greek text fonts
+----------------
+
+A list of Greek text fonts for use with LaTeX is available at the CTAN
+http://www.ctan.org/topic/font-greek
+
+With the XeTeX or LuaTeX engines, the user should ensure that the chosen
+font contains the required glyphs (the default Latin Modern fonts miss
+them). Examples for suitable fonts are the CM-unicode_ or the `Linux
+Libertine`_ OpenType fonts as well as any system-wide installed OTF fonts
+that support Greek (e.g. `Deja Vu`_).
+
+The LGR `font encoding`_ is the de-facto standard for typesetting Greek with
+8-bit LaTeX. Fonts in this encoding include the `CB fonts`_ (matching CM),
+grtimes_ (Greek Times), Kerkis_ (matching URW Bookman), and the `GFS font
+collection`_. Setup of these fonts as Greek variant to matching Latin fonts
+is facilitated by the substitutefont_ package.
+
+LGR Latin Transliteration
+-------------------------
+
+The LGR font encoding allows input of Greek characters via an ASCII
+transliteration. This enables simple input with a Latin keyboard. Characters
+with diacritics may be selected with accent macros (cf. greek-fontenc_) or
+via the ligature definitions in the font (see `<usage.pdf>`_).
+
+The following ASCII characters are converted to Greek symbols:
+
+= = = = = = = = = = = = = = = = = = = = = = = = =
+A B G D E Z H J I K L M N X O P R S T U F Q Y W
+Α Β Γ Δ Ε Ζ Η Θ Ι Κ Λ Μ Ν Ξ Ο Π Ρ Σ Τ Υ Φ Χ Ψ Ω
+a b g d e z h j i k l m n x o p r s c t u f q y w
+α β γ δ ε ζ η θ ι κ λ μ ν ξ ο π ρ σ ς τ υ φ χ ψ ω
+= = = = = = = = = = = = = = = = = = = = = = = = =
+
+Accent symbols and punctuation:
+
+================= ===== == ====================== ======== ====
+tonos ``'`` ά semicolon ``;`` ·
+varia \` ὰ question mark ``?`` ;
+perispomeni ``~`` ᾶ left apostrophe \` \` ‘
+dasia ``<`` ἁ right apostrophe ``''`` ’
+psili ``>`` ἀ left quotation mark ``((`` «
+ypogegrammeni ``|`` ᾳ right quotation mark ``))`` »
+dialytika ``"`` ϊ zero width non-joiner v
+================= ===== == ====================== ======== ====
+
+A major drawback of the LGR transliteration is that you cannot access Latin
+letters and some symbols if LGR is the active font encoding (e.g. in
+documents or parts of documents given the `Babel` language ``greek``). This
+means that for every Latin-written word or acronym an explicit
+language-switch is required. This problem can only be solved via a
+font-encoding comprising both Latin and Greek like the hypothetical T7 or
+Unicode (with XeTeX or LuaTeX).
+
+.. References
+ ----------
+
+.. _LaTeX Project Public License: http://www.latex-project.org/lppl.txt
+.. _babel: http://www.ctan.org/pkg/babel
+.. _docstrip: http://www.ctan.org/pkg/docstrip
+.. _font encoding: http://mirror.ctan.org/macros/latex/doc/encguide.pdf
+.. _fontspec: http://www.ctan.org/pkg/fontspec
+.. _CB Fonts: http://www.ctan.org/pkg/cbgreek-complete
+.. _CM-unicode: http://www.ctan.org/pkg/cm-unicode
+.. _Deja Vu: http://dejavu-fonts.org
+.. _e-TeX: http://www.tex.ac.uk/cgi-bin/texfaq2html?label=etex
+.. _grtimes: http://www.ctan.org/pkg/grtimes
+.. _textalpha:
+.. _greek-fontenc: http://www.ctan.org/pkg/greek-fontenc
+.. _greek-inputenc: http://www.ctan.org/pkg/greek-inputenc
+.. _GFS font collection: http://www.ctan.org/pkg/gfs
+.. _Kerkis: http://www.ctan.org/pkg/kerkis
+.. _Linux Libertine: http://www.ctan.org/pkg/libertine
+.. _polyglossia: http://www.ctan.org/pkg/polyglossia
+.. _substitutefont: http://www.ctan.org/pkg/substitutefont
+.. _texdoc: http://www.ctan.org/pkg/texdoc
diff --git a/macros/latex/contrib/babel-contrib/greek/README.html b/macros/latex/contrib/babel-contrib/greek/README.html
new file mode 100644
index 0000000000..5eb279899e
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/README.html
@@ -0,0 +1,1036 @@
+<!DOCTYPE html>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+<meta charset="utf-8"/>
+<meta name="generator" content="Docutils 0.15b.dev: http://docutils.sourceforge.net/" />
+<title>babel-greek</title>
+<meta name="dcterms.rights" content="© 1997 Apostolos Syropoulos, Claudio Beccari, Johannes Brahms, © 2013 Günter Milde" />
+<link rel="schema.dcterms" href="http://purl.org/dc/terms/">
+<style type="text/css">
+
+/* Minimal style sheet for the HTML output of Docutils. */
+/* */
+/* :Author: Günter Milde, based on html4css1.css by David Goodger */
+/* :Id: $Id$ */
+/* :Copyright: © 2015 Günter Milde. */
+/* :License: Released under the terms of the `2-Clause BSD license`_, */
+/* in short: */
+/* */
+/* Copying and distribution of this file, with or without modification, */
+/* are permitted in any medium without royalty provided the copyright */
+/* notice and this notice are preserved. */
+/* */
+/* This file is offered as-is, without any warranty. */
+/* */
+/* .. _2-Clause BSD license: http://www.spdx.org/licenses/BSD-2-Clause */
+
+/* This CSS2.1_ stylesheet defines rules for Docutils elements without */
+/* HTML equivalent. It is required to make the document semantic visible. */
+/* */
+/* .. _CSS2.1: http://www.w3.org/TR/CSS2 */
+/* .. _validates: http://jigsaw.w3.org/css-validator/validator$link */
+
+/* alignment of text and inline objects inside block objects*/
+.align-left { text-align: left; }
+.align-right { text-align: right; }
+.align-center { clear: both; text-align: center; }
+.align-top { vertical-align: top; }
+.align-middle { vertical-align: middle; }
+.align-bottom { vertical-align: bottom; }
+
+/* titles */
+h1.title, p.subtitle {
+ text-align: center;
+}
+p.admonition-title,
+p.topic-title,
+p.sidebar-title,
+p.rubric,
+p.system-message-title {
+ font-weight: bold;
+}
+h1 + p.subtitle,
+h1 + p.section-subtitle {
+ font-size: 1.6em;
+}
+h2 + p.section-subtitle { font-size: 1.28em; }
+p.subtitle,
+p.section-subtitle,
+p.sidebar-subtitle {
+ font-weight: bold;
+ margin-top: -0.5em;
+}
+p.sidebar-title,
+p.rubric {
+ font-size: larger;
+}
+p.rubric { color: maroon; }
+a.toc-backref {
+ color: black;
+ text-decoration: none; }
+
+/* Warnings, Errors */
+div.caution p.admonition-title,
+div.attention p.admonition-title,
+div.danger p.admonition-title,
+div.error p.admonition-title,
+div.warning p.admonition-title,
+div.system-messages h1,
+div.error,
+span.problematic,
+p.system-message-title {
+ color: red;
+}
+
+/* inline literals */
+span.docutils.literal {
+ font-family: monospace;
+ white-space: pre-wrap;
+}
+/* do not wraph at hyphens and similar: */
+.literal > span.pre { white-space: nowrap; }
+
+/* Lists */
+
+/* compact and simple lists: no margin between items */
+.simple li, .compact li,
+.simple ul, .compact ul,
+.simple ol, .compact ol,
+.simple > li p, .compact > li p,
+dl.simple > dd, dl.compact > dd {
+ margin-top: 0;
+ margin-bottom: 0;
+}
+
+/* Table of Contents */
+div.topic.contents { margin: 0; }
+div.topic.contents ul {
+ list-style-type: none;
+ padding-left: 1.5em;
+}
+
+/* Enumerated Lists */
+ol.arabic { list-style: decimal }
+ol.loweralpha { list-style: lower-alpha }
+ol.upperalpha { list-style: upper-alpha }
+ol.lowerroman { list-style: lower-roman }
+ol.upperroman { list-style: upper-roman }
+
+dt span.classifier { font-style: italic }
+dt span.classifier:before {
+ font-style: normal;
+ margin: 0.5em;
+ content: ":";
+}
+
+/* Field Lists and drivatives */
+/* bold field name, content starts on the same line */
+dl.field-list > dt,
+dl.option-list > dt,
+dl.docinfo > dt,
+dl.footnote > dt,
+dl.citation > dt {
+ font-weight: bold;
+ clear: left;
+ float: left;
+ margin: 0;
+ padding: 0;
+ padding-right: 0.5em;
+}
+/* Offset for field content (corresponds to the --field-name-limit option) */
+dl.field-list > dd,
+dl.option-list > dd,
+dl.docinfo > dd {
+ margin-left: 9em; /* ca. 14 chars in the test examples */
+}
+/* start field-body on a new line after long field names */
+dl.field-list > dd > *:first-child,
+dl.option-list > dd > *:first-child
+{
+ display: inline-block;
+ width: 100%;
+ margin: 0;
+}
+/* field names followed by a colon */
+dl.field-list > dt:after,
+dl.docinfo > dt:after {
+ content: ":";
+}
+
+/* Bibliographic Fields (docinfo) */
+pre.address { font: inherit; }
+dd.authors > p { margin: 0; }
+
+/* Option Lists */
+dl.option-list { margin-left: 40px; }
+dl.option-list > dt { font-weight: normal; }
+span.option { white-space: nowrap; }
+
+/* Footnotes and Citations */
+dl.footnote.superscript > dd {margin-left: 1em; }
+dl.footnote.brackets > dd {margin-left: 2em; }
+dl > dt.label { font-weight: normal; }
+a.footnote-reference.brackets:before,
+dt.label > span.brackets:before { content: "["; }
+a.footnote-reference.brackets:after,
+dt.label > span.brackets:after { content: "]"; }
+a.footnote-reference.superscript,
+dl.footnote.superscript > dt.label {
+ vertical-align: super;
+ font-size: smaller;
+}
+dt.label > span.fn-backref { margin-left: 0.2em; }
+dt.label > span.fn-backref > a { font-style: italic; }
+
+/* Line Blocks */
+div.line-block { display: block; }
+div.line-block div.line-block {
+ margin-top: 0;
+ margin-bottom: 0;
+ margin-left: 40px;
+}
+
+/* Figures, Images, and Tables */
+.figure.align-left,
+img.align-left,
+object.align-left,
+table.align-left {
+ margin-right: auto;
+}
+.figure.align-center,
+img.align-center,
+object.align-center {
+ margin-left: auto;
+ margin-right: auto;
+ display: block;
+}
+table.align-center {
+ margin-left: auto;
+ margin-right: auto;
+}
+.figure.align-right,
+img.align-right,
+object.align-right,
+table.align-right {
+ margin-left: auto;
+}
+/* reset inner alignment in figures and tables */
+/* div.align-left, div.align-center, div.align-right, */
+table.align-left, table.align-center, table.align-right
+{ text-align: inherit }
+
+/* Admonitions and System Messages */
+div.admonition,
+div.system-message,
+div.sidebar{
+ margin: 40px;
+ border: medium outset;
+ padding-right: 1em;
+ padding-left: 1em;
+}
+
+/* Sidebar */
+div.sidebar {
+ width: 30%;
+ max-width: 26em;
+ float: right;
+ clear: right;
+}
+
+/* Text Blocks */
+blockquote,
+div.topic,
+pre.literal-block,
+pre.doctest-block,
+pre.math,
+pre.code {
+ margin-left: 1.5em;
+ margin-right: 1.5em
+}
+pre.code .ln { color: gray; } /* line numbers */
+
+/* Tables */
+table { border-collapse: collapse; }
+td, th {
+ border-style: solid;
+ border-color: silver;
+ padding: 0 1ex;
+ border-width: thin;
+}
+td > p:first-child, th > p:first-child { margin-top: 0; }
+td > p, th > p { margin-bottom: 0; }
+
+table > caption {
+ text-align: left;
+ margin-bottom: 0.25em
+}
+
+table.borderless td, table.borderless th {
+ border: 0;
+ padding: 0;
+ padding-right: 0.5em /* separate table cells */
+}
+
+</style>
+<style type="text/css">
+
+/* CSS31_ style sheet for the output of Docutils HTML writers. */
+/* Rules for easy reading and pre-defined style variants. */
+/* */
+/* :Author: Günter Milde, based on html4css1.css by David Goodger */
+/* :Id: $Id$ */
+/* :Copyright: © 2015 Günter Milde. */
+/* :License: Released under the terms of the `2-Clause BSD license`_, */
+/* in short: */
+/* */
+/* Copying and distribution of this file, with or without modification, */
+/* are permitted in any medium without royalty provided the copyright */
+/* notice and this notice are preserved. */
+/* */
+/* This file is offered as-is, without any warranty. */
+/* */
+/* .. _2-Clause BSD license: http://www.spdx.org/licenses/BSD-2-Clause */
+/* .. _CSS3: http://www.w3.org/TR/CSS3 */
+
+
+/* Document Structure */
+/* ****************** */
+
+/* "page layout" */
+body {
+ margin: 0;
+ background-color: #dbdbdb;
+}
+div.document {
+ line-height:1.3;
+ counter-reset: table;
+ /* counter-reset: figure; */
+ /* avoid long lines --> better reading */
+ /* OTOH: lines should not be too short because of missing hyphenation, */
+ max-width: 50em;
+ padding: 1px 2%; /* 1px on top avoids grey bar above title (mozilla) */
+ margin: auto;
+ background-color: white;
+}
+
+/* Sections */
+
+/* Transitions */
+
+hr.docutils {
+ width: 80%;
+ margin-top: 1em;
+ margin-bottom: 1em;
+ clear: both;
+}
+
+/* Paragraphs */
+/* ========== */
+
+/* vertical space (parskip) */
+p, ol, ul, dl,
+div.line-block,
+table{
+ margin-top: 0.5em;
+ margin-bottom: 0.5em;
+}
+h1, h2, h3, h4, h5, h6,
+dl > dd {
+ margin-bottom: 0.5em;
+}
+
+/* Lists */
+/* ========== */
+
+/* Definition Lists */
+
+dl > dd > p:first-child { margin-top: 0; }
+/* :last-child is not part of CSS 2.1 (introduced in CSS 3) */
+dl > dd > p:last-child { margin-bottom: 0; }
+
+/* lists nested in definition lists */
+/* :only-child is not part of CSS 2.1 (introduced in CSS 3) */
+dd > ul:only-child, dd > ol:only-child { padding-left: 1em; }
+
+/* Description Lists */
+/* styled like in most dictionaries, encyclopedias etc. */
+dl.description > dt {
+ font-weight: bold;
+ clear: left;
+ float: left;
+ margin: 0;
+ padding: 0;
+ padding-right: 0.5em;
+}
+
+/* Field Lists */
+
+/* example for custom field-name width */
+dl.field-list.narrow > dd {
+ margin-left: 5em;
+}
+/* run-in: start field-body on same line after long field names */
+dl.field-list.run-in > dd p {
+ display: block;
+}
+
+/* Bibliographic Fields */
+
+/* generally, bibliographic fields use special definition list dl.docinfo */
+/* but dedication and abstract are placed into "topic" divs */
+div.abstract p.topic-title {
+ text-align: center;
+}
+div.dedication {
+ margin: 2em 5em;
+ text-align: center;
+ font-style: italic;
+}
+div.dedication p.topic-title {
+ font-style: normal;
+}
+
+/* Citations */
+dl.citation dt.label {
+ font-weight: bold;
+}
+span.fn-backref {
+ font-weight: normal;
+}
+
+/* Text Blocks */
+/* ============ */
+
+/* Literal Blocks */
+
+/* Block Quotes */
+
+blockquote > table,
+div.topic > table {
+ margin-top: 0;
+ margin-bottom: 0;
+}
+blockquote p.attribution,
+div.topic p.attribution {
+ text-align: right;
+ margin-left: 20%;
+}
+
+/* Tables */
+/* ====== */
+
+/* th { vertical-align: bottom; } */
+
+table tr { text-align: left; }
+
+/* "booktabs" style (no vertical lines) */
+table.booktabs {
+ border: 0;
+ border-top: 2px solid;
+ border-bottom: 2px solid;
+ border-collapse: collapse;
+}
+table.booktabs * {
+ border: 0;
+}
+table.booktabs th {
+ border-bottom: thin solid;
+}
+
+/* numbered tables (counter defined in div.document) */
+table.numbered > caption:before {
+ counter-increment: table;
+ content: "Table " counter(table) ": ";
+ font-weight: bold;
+}
+
+/* Explicit Markup Blocks */
+/* ====================== */
+
+/* Footnotes and Citations */
+/* ----------------------- */
+
+/* line on the left */
+dl.footnote {
+ padding-left: 1ex;
+ border-left: solid;
+ border-left-width: thin;
+}
+
+/* Directives */
+/* ---------- */
+
+/* Body Elements */
+/* ~~~~~~~~~~~~~ */
+
+/* Images and Figures */
+
+/* let content flow to the side of aligned images and figures */
+.figure.align-left,
+img.align-left,
+object.align-left {
+ display: block;
+ clear: left;
+ float: left;
+ margin-right: 1em
+}
+.figure.align-right,
+img.align-right,
+object.align-right {
+ display: block;
+ clear: right;
+ float: right;
+ margin-left: 1em
+}
+/* Stop floating sidebars, images and figures at section level 1,2,3 */
+h1, h2, h3 { clear: both; }
+
+/* Sidebar */
+
+/* Move into the margin. In a layout with fixed margins, */
+/* it can be moved into the margin completely. */
+div.sidebar {
+ width: 30%;
+ max-width: 26em;
+ margin-left: 1em;
+ margin-right: -5.5%;
+ background-color: #ffffee ;
+}
+
+/* Code */
+
+pre.code { padding: 0.7ex }
+pre.code, code { background-color: #eeeeee }
+pre.code .ln { color: gray; } /* line numbers */
+/* basic highlighting: for a complete scheme, see */
+/* http://docutils.sourceforge.net/sandbox/stylesheets/ */
+pre.code .comment, code .comment { color: #5C6576 }
+pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
+pre.code .literal.string, code .literal.string { color: #0C5404 }
+pre.code .name.builtin, code .name.builtin { color: #352B84 }
+pre.code .deleted, code .deleted { background-color: #DEB0A1}
+pre.code .inserted, code .inserted { background-color: #A3D289}
+
+/* Math */
+/* styled separately (see math.css for math-output=HTML) */
+
+/* Epigraph */
+/* Highlights */
+/* Pull-Quote */
+/* Compound Paragraph */
+/* Container */
+
+/* can be styled in a custom stylesheet */
+
+/* Document Header and Footer */
+
+div.footer, div.header {
+ clear: both;
+ font-size: smaller;
+}
+
+/* Inline Markup */
+/* ============= */
+
+/* Emphasis */
+/* em */
+/* Strong Emphasis */
+/* strong */
+/* Interpreted Text */
+/* span.interpreted */
+/* Title Reference */
+/* cite */
+/* Inline Literals */
+/* possible values: normal, nowrap, pre, pre-wrap, pre-line */
+/* span.docutils.literal { white-space: pre-wrap; } */
+
+/* Hyperlink References */
+a { text-decoration: none; }
+
+/* External Targets */
+/* span.target.external */
+/* Internal Targets */
+/* span.target.internal */
+/* Footnote References */
+/* a.footnote-reference */
+/* Citation References */
+/* a.citation-reference */
+
+</style>
+</head>
+<body>
+<div class="document" id="babel-greek">
+<h1 class="title">babel-greek</h1>
+<p class="subtitle" id="babel-support-for-the-greek-language-and-script">Babel support for the Greek language and script</p>
+<dl class="docinfo simple">
+<dt class="copyright">Copyright</dt>
+<dd class="copyright">© 1997 Apostolos Syropoulos, Claudio Beccari, Johannes Brahms,
+© 2013 Günter Milde</dd>
+<dt class="licence">Licence</dt>
+<dd class="licence"><p>This work may be distributed and/or modified under the
+conditions of the <a class="reference external" href="http://www.latex-project.org/lppl.txt">LaTeX Project Public License</a>, either
+version 1.3 of this license or any later version.</p>
+</dd>
+</dl>
+<div class="abstract topic">
+<p class="topic-title first">Abstract</p>
+<p>Babel-greek is a contributed package providing support for the
+Greek language and script via the <a class="reference external" href="http://www.ctan.org/pkg/babel">Babel</a> system.</p>
+<p>The file <span class="docutils literal">greek.ldf</span> provides options for the monotonic
+(single-diacritic), polytonic (multiple-diacritic) and ancient
+orthography of the Greek language.</p>
+<p>Since 2013-07-19, babel-greek supports also Unicode-aware TeX
+engines (XeTeX/LuaTeX).</p>
+</div>
+<div class="section" id="news">
+<h1>News</h1>
+<table class="borderless">
+<colgroup>
+<col style="width: 6%" />
+<col style="width: 16%" />
+<col style="width: 78%" />
+</colgroup>
+<tbody>
+<tr><td><p>1.4</p></td>
+<td><p>2013-05-17</p></td>
+<td><p>New maintainer.</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>The encoding definition file <span class="docutils literal">lgrenc.def</span> moved to the
+<a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">greek-fontenc</a> package.</p></td>
+</tr>
+<tr><td><p>1.5</p></td>
+<td><p>2013-06-21</p></td>
+<td><p>bugfixes and cleanup,</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>LICR macros in string definitions,</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>LGR font encoding not used with XeTeX/LuaTeX,</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>input “xgreek-fixes.def” from <a class="reference external" href="http://www.ctan.org/pkg/polyglossia">polyglossia</a> with Xe/LuaTeX.</p></td>
+</tr>
+<tr><td><p>1.5a</p></td>
+<td><p>2013-07-02</p></td>
+<td><p>Fix LaTeX bugs babel/3707, <a class="reference external" href="http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4303">babel/4303</a> and <a class="reference external" href="http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4305">babel/4305</a></p></td>
+</tr>
+<tr><td><p>1.6</p></td>
+<td><p>2013-07-19</p></td>
+<td><p>Experimental support for XeTeX/LuaTeX.</p></td>
+</tr>
+<tr><td><p>1.7</p></td>
+<td><p>2013-09-09</p></td>
+<td><p>CB-Fonts font definition files moved to CB-Fonts package.</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>Do not auto-load euenc.def with XeTeX/LuaTeX.</p></td>
+</tr>
+<tr><td><p>1.7a</p></td>
+<td><p>2013-09-13</p></td>
+<td><p>Fix bug <a class="reference external" href="http://www.latex-project.org/cgi-bin/ltxbugs2html?pr=babel/4360">babel/4360</a>: spurious <span class="docutils literal">\fi</span>.</p></td>
+</tr>
+<tr><td><p>1.7b</p></td>
+<td><p>2013-10-01</p></td>
+<td><p>bugfix: correct upcasing of babel strings with Xe/LuaTeX.</p></td>
+</tr>
+<tr><td><p>1.8</p></td>
+<td><p>2013-12-02</p></td>
+<td><p>Rename <span class="docutils literal">greek.dtx</span> to <span class="docutils literal"><span class="pre">babel-greek</span></span> so that <a class="reference external" href="http://www.ctan.org/pkg/texdoc">texdoc</a>
+shows the right documentation.</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>Compatibility with Xe/LuaTeX in Unicode and 8-bit mode.</p></td>
+</tr>
+<tr><td><p>1.8a</p></td>
+<td><p>2013-12-03</p></td>
+<td><p>Set <span class="docutils literal">\encodingdefault</span> in <span class="docutils literal">\greekscript</span> to fix
+Greek in footnotes etc. with document language Greek.</p></td>
+</tr>
+<tr><td><p>1.9</p></td>
+<td><p>2014-07-20</p></td>
+<td><p>Added attribute for ancient Greek, load correct hyphenation
+patterns: Patch by Claudio Beccari. Bugfix for Makeuppercase</p></td>
+</tr>
+<tr><td><p>1.9a</p></td>
+<td><p>2014-09-12</p></td>
+<td><p>Remove duplicate code, documentation review.</p></td>
+</tr>
+<tr><td><p>1.9b</p></td>
+<td><p>2014-09-18</p></td>
+<td><p>Remove spurious whitespace from “extrasgreek” definition.</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>Use named macros instead of non-standard short macros
+for psili and dasia in the string definitions.</p></td>
+</tr>
+<tr><td><p>1.9c</p></td>
+<td><p>2014-10-21</p></td>
+<td><p>Fix dummy hyphenation language names (patch Ulrike Fischer).</p></td>
+</tr>
+<tr><td><p>1.9d</p></td>
+<td><p>2015-09-04</p></td>
+<td><p>Remove <cite>grsymb</cite> (macros for Greek symbols).
+This package is outdated and obsoleted by <a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">greek-fontenc</a>
+(reported by Claudio Beccari).</p></td>
+</tr>
+<tr><td><!-- -->
+</td>
+<td></td>
+<td><p>Unicode uc/lc corrections now in greek-fontenc
+(polyglossia’s <span class="docutils literal"><span class="pre">xgreek-fixes.def</span></span> has bugs).</p></td>
+</tr>
+<tr><td><p>1.9e</p></td>
+<td><p>2015-11-27</p></td>
+<td><p>Fix bug in lccode-setting loop (patch by Enrico Gregorio).</p></td>
+</tr>
+<tr><td><p>1.9f</p></td>
+<td><p>2016-02-04</p></td>
+<td><p>Support for standard Unicode text font encoding “TU”
+(new in fontspec v2.5a).</p></td>
+</tr>
+<tr><td><p>1.9g</p></td>
+<td><p>2016-09-07</p></td>
+<td><p>Babel 3.9i deprecated <span class="docutils literal">\textlatin</span>
+and fixed <span class="docutils literal">\latinencoding</span>.</p></td>
+</tr>
+<tr><td><p>1.9.h</p></td>
+<td><p>2019-07-11</p></td>
+<td><p>Move breathing composite commands to <a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">textalpha</a>.</p></td>
+</tr>
+</tbody>
+</table>
+</div>
+<div class="section" id="files">
+<h1>Files</h1>
+<dl class="simple">
+<dt><a class="reference external" href="babel-greek.ins">babel-greek.ins</a>; <a class="reference external" href="babel-greek.pdf">babel-greek.pdf</a></dt>
+<dd><p>Source of the language definition file <span class="docutils literal">greek.ldf</span> for use with <a class="reference external" href="http://www.ctan.org/pkg/babel">Babel</a>.</p>
+</dd>
+<dt><a class="reference external" href="athnum.dtx">athnum.dtx</a>; <a class="reference external" href="athnum.pdf">athnum.pdf</a></dt>
+<dd><p>Athenian Numerals.</p>
+</dd>
+<dt><a class="reference external" href="grmath.dtx">grmath.dtx</a>; <a class="reference external" href="grmath.pdf">grmath.pdf</a></dt>
+<dd><p>Greek log-like Operators.</p>
+</dd>
+<dt><a class="reference external" href="test-greek.pdf">test-greek.pdf</a>; <a class="reference external" href="test-greek.tex">test-greek.tex</a></dt>
+<dd><p>Tests and Examples for 8-bit TeX.</p>
+</dd>
+<dt><a class="reference external" href="test-unicode-greek.pdf">test-unicode-greek.pdf</a>; <a class="reference external" href="test-unicode-greek.tex">test-unicode-greek.tex</a></dt>
+<dd><p>Tests and Examples for XeTeX/LuaTeX.</p>
+</dd>
+<dt><a class="reference external" href="test-unicode-lgr.pdf">test-unicode-lgr.pdf</a>; <a class="reference external" href="test-unicode-lgr.tex">test-unicode-lgr.tex</a></dt>
+<dd><p>Tests and Examples for XeTeX/LuaTeX with LGR 8-bit fonts.</p>
+</dd>
+<dt><a class="reference external" href="usage.pdf">usage.pdf</a>; <a class="reference external" href="usage.tex">usage.tex</a></dt>
+<dd><p>Description of the <a class="reference internal" href="#lgr-latin-transliteration">LGR Latin transliteration</a>.</p>
+</dd>
+</dl>
+</div>
+<div class="section" id="requirements">
+<h1>Requirements</h1>
+<p>The “babel-greek” package requires the <a class="reference external" href="http://www.ctan.org/pkg/babel">babel</a> base package and font
+definition files from the <a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">greek-fontenc</a> package. The <a class="reference external" href="http://www.ctan.org/pkg/greek-inputenc">greek-inputenc</a>
+package is recommended when using 8-bit TeX engines.</p>
+<p>Typesetting Greek texts requires <a class="reference internal" href="#greek-text-fonts">Greek text fonts</a>.</p>
+<p>Plain TeX is currently not supported. Patches are welcome.</p>
+</div>
+<div class="section" id="installation">
+<h1>Installation</h1>
+<p>If possible, get this package from your distribution using its installation
+manager.</p>
+<p>Otherwise, make sure LaTeX can find the required files:</p>
+<ul>
+<li><p>Download and unpack <cite>babel-greek.zip</cite>.</p></li>
+<li><p>Run <span class="docutils literal">tex</span> or <span class="docutils literal">latex</span> on the batch file <span class="docutils literal"><span class="pre">babel-greek.ins</span></span>.</p>
+<p>This will generate the files <span class="docutils literal">greek.ldf</span>, <span class="docutils literal">athnum.sty</span>, and
+<span class="docutils literal">grmath.sty</span> in the current directory.<a class="footnote-reference superscript" href="#id2" id="id1">1</a></p>
+</li>
+<li><p>Move all files ending in <span class="docutils literal">.ldf</span> or <span class="docutils literal">.sty</span> into a directory searched by
+TeX.</p></li>
+<li><p>To produce the documentation, run the file <span class="docutils literal">usage.tex</span> and all files
+ending in <span class="docutils literal">.dtx</span> through LaTeX.</p></li>
+</ul>
+<dl class="footnote superscript">
+<dt class="label" id="id2"><span class="superscript"><a class="fn-backref" href="#id1">1</a></span></dt>
+<dd><p>If these files already exist somewhere in the TeX-path, you will be
+warned that they might be overwritten. You can ignore this
+warning and answer <cite>y</cite> unless the <em>current directory</em> contains versions
+of these files you want to keep.</p>
+<p>This is done by <a class="reference external" href="http://www.ctan.org/pkg/docstrip">docstrip</a>. Try <span class="docutils literal">texdoc docstrip</span> for details.</p>
+</dd>
+</dl>
+</div>
+<div class="section" id="usage">
+<h1>Usage</h1>
+<p>Use the “greek” document option or pass the “greek” option to babel:</p>
+<pre class="literal-block">\usepackage[greek]{babel}</pre>
+<p>For polytonic Greek, set the language attribute “polutoniko”:</p>
+<pre class="literal-block">\usepackage[greek]{babel}
+\languageattribute{greek}{polutoniko}</pre>
+<p>or</p>
+<pre class="literal-block">\usepackage[greek.polutoniko,english]{babel}</pre>
+<p>Similarly, the attribute “ancient” selects the ancient Greek language
+variant.</p>
+<p>For details see <a class="reference external" href="babel-greek.pdf">babel-greek.pdf</a> and the <a class="reference external" href="http://www.ctan.org/pkg/babel">babel</a> documentation.</p>
+<p>With XeTeX/LuaTeX, load <a class="reference external" href="http://www.ctan.org/pkg/fontspec">fontspec</a> before <a class="reference external" href="http://www.ctan.org/pkg/babel">babel</a>, so that babel-greek can
+set up the Unicode font encoding for use with Greek, e.g.</p>
+<pre class="literal-block">\usepackage{fontspec}
+\setmainfont{Linux Libertine O}
+\setsansfont{Linux Biolinum O}
+\usepackage[greek,english]{babel}</pre>
+<p>Note, that the default font used with XeTeX/LuaTeX (Latin Modern) misses most
+Greek letters. Warnings about missing charcters are only written to the log
+file, not the console output!</p>
+<p>Input of Greek characters is possible as literal characters (with the
+<a class="reference external" href="http://www.ctan.org/pkg/greek-inputenc">greek-inputenc</a> package or with XeTeX or LuaTeX) or the <a class="reference internal" href="#lgr-latin-transliteration">LGR Latin
+transliteration</a>. See <a class="reference external" href="usage.pdf">usage.pdf</a> and the example files provided with
+<a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">greek-fontenc</a>.</p>
+</div>
+<div class="section" id="greek-text-fonts">
+<h1>Greek text fonts</h1>
+<p>A list of Greek text fonts for use with LaTeX is available at the CTAN
+<a class="reference external" href="http://www.ctan.org/topic/font-greek">http://www.ctan.org/topic/font-greek</a></p>
+<p>With the XeTeX or LuaTeX engines, the user should ensure that the chosen
+font contains the required glyphs (the default Latin Modern fonts miss
+them). Examples for suitable fonts are the <a class="reference external" href="http://www.ctan.org/pkg/cm-unicode">CM-unicode</a> or the <a class="reference external" href="http://www.ctan.org/pkg/libertine">Linux
+Libertine</a> OpenType fonts as well as any system-wide installed OTF fonts
+that support Greek (e.g. <a class="reference external" href="http://dejavu-fonts.org">Deja Vu</a>).</p>
+<p>The LGR <a class="reference external" href="http://mirror.ctan.org/macros/latex/doc/encguide.pdf">font encoding</a> is the de-facto standard for typesetting Greek with
+8-bit LaTeX. Fonts in this encoding include the <a class="reference external" href="http://www.ctan.org/pkg/cbgreek-complete">CB fonts</a> (matching CM),
+<a class="reference external" href="http://www.ctan.org/pkg/grtimes">grtimes</a> (Greek Times), <a class="reference external" href="http://www.ctan.org/pkg/kerkis">Kerkis</a> (matching URW Bookman), and the <a class="reference external" href="http://www.ctan.org/pkg/gfs">GFS font
+collection</a>. Setup of these fonts as Greek variant to matching Latin fonts
+is facilitated by the <a class="reference external" href="http://www.ctan.org/pkg/substitutefont">substitutefont</a> package.</p>
+</div>
+<div class="section" id="lgr-latin-transliteration">
+<h1>LGR Latin Transliteration</h1>
+<p>The LGR font encoding allows input of Greek characters via an ASCII
+transliteration. This enables simple input with a Latin keyboard. Characters
+with diacritics may be selected with accent macros (cf. <a class="reference external" href="http://www.ctan.org/pkg/greek-fontenc">greek-fontenc</a>) or
+via the ligature definitions in the font (see <a class="reference external" href="usage.pdf">usage.pdf</a>).</p>
+<p>The following ASCII characters are converted to Greek symbols:</p>
+<table>
+<colgroup>
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+<col style="width: 4%" />
+</colgroup>
+<tbody>
+<tr><td><p>A</p></td>
+<td><p>B</p></td>
+<td><p>G</p></td>
+<td><p>D</p></td>
+<td><p>E</p></td>
+<td><p>Z</p></td>
+<td><p>H</p></td>
+<td><p>J</p></td>
+<td><p>I</p></td>
+<td><p>K</p></td>
+<td><p>L</p></td>
+<td><p>M</p></td>
+<td><p>N</p></td>
+<td><p>X</p></td>
+<td><p>O</p></td>
+<td><p>P</p></td>
+<td><p>R</p></td>
+<td><p>S</p></td>
+<td></td>
+<td><p>T</p></td>
+<td><p>U</p></td>
+<td><p>F</p></td>
+<td><p>Q</p></td>
+<td><p>Y</p></td>
+<td><p>W</p></td>
+</tr>
+<tr><td><p>Α</p></td>
+<td><p>Β</p></td>
+<td><p>Γ</p></td>
+<td><p>Δ</p></td>
+<td><p>Ε</p></td>
+<td><p>Ζ</p></td>
+<td><p>Η</p></td>
+<td><p>Θ</p></td>
+<td><p>Ι</p></td>
+<td><p>Κ</p></td>
+<td><p>Λ</p></td>
+<td><p>Μ</p></td>
+<td><p>Ν</p></td>
+<td><p>Ξ</p></td>
+<td><p>Ο</p></td>
+<td><p>Π</p></td>
+<td><p>Ρ</p></td>
+<td><p>Σ</p></td>
+<td></td>
+<td><p>Τ</p></td>
+<td><p>Υ</p></td>
+<td><p>Φ</p></td>
+<td><p>Χ</p></td>
+<td><p>Ψ</p></td>
+<td><p>Ω</p></td>
+</tr>
+<tr><td><p>a</p></td>
+<td><p>b</p></td>
+<td><p>g</p></td>
+<td><p>d</p></td>
+<td><p>e</p></td>
+<td><p>z</p></td>
+<td><p>h</p></td>
+<td><p>j</p></td>
+<td><p>i</p></td>
+<td><p>k</p></td>
+<td><p>l</p></td>
+<td><p>m</p></td>
+<td><p>n</p></td>
+<td><p>x</p></td>
+<td><p>o</p></td>
+<td><p>p</p></td>
+<td><p>r</p></td>
+<td><p>s</p></td>
+<td><p>c</p></td>
+<td><p>t</p></td>
+<td><p>u</p></td>
+<td><p>f</p></td>
+<td><p>q</p></td>
+<td><p>y</p></td>
+<td><p>w</p></td>
+</tr>
+<tr><td><p>α</p></td>
+<td><p>β</p></td>
+<td><p>γ</p></td>
+<td><p>δ</p></td>
+<td><p>ε</p></td>
+<td><p>ζ</p></td>
+<td><p>η</p></td>
+<td><p>θ</p></td>
+<td><p>ι</p></td>
+<td><p>κ</p></td>
+<td><p>λ</p></td>
+<td><p>μ</p></td>
+<td><p>ν</p></td>
+<td><p>ξ</p></td>
+<td><p>ο</p></td>
+<td><p>π</p></td>
+<td><p>ρ</p></td>
+<td><p>σ</p></td>
+<td><p>ς</p></td>
+<td><p>τ</p></td>
+<td><p>υ</p></td>
+<td><p>φ</p></td>
+<td><p>χ</p></td>
+<td><p>ψ</p></td>
+<td><p>ω</p></td>
+</tr>
+</tbody>
+</table>
+<p>Accent symbols and punctuation:</p>
+<table>
+<colgroup>
+<col style="width: 29%" />
+<col style="width: 9%" />
+<col style="width: 3%" />
+<col style="width: 38%" />
+<col style="width: 14%" />
+<col style="width: 7%" />
+</colgroup>
+<tbody>
+<tr><td><p>tonos</p></td>
+<td><p><span class="docutils literal">'</span></p></td>
+<td><p>ά</p></td>
+<td><p>semicolon</p></td>
+<td><p><span class="docutils literal">;</span></p></td>
+<td><p>·</p></td>
+</tr>
+<tr><td><p>varia</p></td>
+<td><p>`</p></td>
+<td><p>ὰ</p></td>
+<td><p>question mark</p></td>
+<td><p><span class="docutils literal">?</span></p></td>
+<td><p>;</p></td>
+</tr>
+<tr><td><p>perispomeni</p></td>
+<td><p><span class="docutils literal">~</span></p></td>
+<td><p>ᾶ</p></td>
+<td><p>left apostrophe</p></td>
+<td><p>` `</p></td>
+<td><p>‘</p></td>
+</tr>
+<tr><td><p>dasia</p></td>
+<td><p><span class="docutils literal">&lt;</span></p></td>
+<td><p>ἁ</p></td>
+<td><p>right apostrophe</p></td>
+<td><p><span class="docutils literal">''</span></p></td>
+<td><p>’</p></td>
+</tr>
+<tr><td><p>psili</p></td>
+<td><p><span class="docutils literal">&gt;</span></p></td>
+<td><p>ἀ</p></td>
+<td><p>left quotation mark</p></td>
+<td><p><span class="docutils literal">((</span></p></td>
+<td><p>«</p></td>
+</tr>
+<tr><td><p>ypogegrammeni</p></td>
+<td><p><span class="docutils literal">|</span></p></td>
+<td><p>ᾳ</p></td>
+<td><p>right quotation mark</p></td>
+<td><p><span class="docutils literal">))</span></p></td>
+<td><p>»</p></td>
+</tr>
+<tr><td><p>dialytika</p></td>
+<td><p><span class="docutils literal">&quot;</span></p></td>
+<td><p>ϊ</p></td>
+<td><p>zero width non-joiner</p></td>
+<td><p>v</p></td>
+<td></td>
+</tr>
+</tbody>
+</table>
+<p>A major drawback of the LGR transliteration is that you cannot access Latin
+letters and some symbols if LGR is the active font encoding (e.g. in
+documents or parts of documents given the <cite>Babel</cite> language <span class="docutils literal">greek</span>). This
+means that for every Latin-written word or acronym an explicit
+language-switch is required. This problem can only be solved via a
+font-encoding comprising both Latin and Greek like the hypothetical T7 or
+Unicode (with XeTeX or LuaTeX).</p>
+<!-- References
+- - - - - - - - - - -->
+</div>
+</div>
+</body>
+</html>
diff --git a/macros/latex/contrib/babel-contrib/greek/athnum.dtx b/macros/latex/contrib/babel-contrib/greek/athnum.dtx
new file mode 100644
index 0000000000..3ea1f5325a
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/athnum.dtx
@@ -0,0 +1,277 @@
+% \iffalse meta-comment
+%
+% Copyright 1989-2008 Johannes L. Braams and any individual authors
+% listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the Babel system.
+% --------------------------------------
+%
+% It may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2003/12/01 or later.
+%
+% This work has the LPPL maintenance status "maintained".
+%
+% The Current Maintainer of this work is Johannes Braams.
+%
+% The list of all files belonging to the Babel system is
+% given in the file `manifest.bbl. See also `legal.bbl' for additional
+% information.
+%
+% The list of derived (unpacked) files belonging to the distribution
+% and covered by LPPL is defined by the unpacking scripts (with
+% extension .ins) which are part of the distribution.
+% \fi
+%% \CheckSum{125}
+%\iffalse
+%
+%% This is file `athnum.dtx'
+%% (c) 1997-2007 Apostolos Syropoulos.
+%% All rights reserved.
+%
+% Please report errors or suggestions for improvement to
+%
+% Apostolos Syropoulos
+% 366, 28th October Str.
+% GR-671 00 Xanthi, GREECE
+% apostolo at platon.ee.duth.gr or apostolo at obelix.ee.duth.gr
+%
+%\fi
+%
+% \iffalse
+% \begin{macrocode}
+%<*driver>
+\documentclass{ltxdoc}
+\def\PiIt#1{{%
+ \newdimen\boxW \newdimen\boxH
+ \settowidth{\boxW}{#1}%
+ \settoheight{\boxH}{#1}%
+ \addtolength{\boxW}{0.8pt}
+ \vbox{%
+ \hrule width\boxW\hbox{%
+ \vrule height\boxH\mbox{#1}%
+ \vrule height\boxH}}\kern.5pt}}
+\GetFileInfo{athnum.drv}
+\begin{document}
+ \DocInput{athnum.dtx}
+\end{document}
+%</driver>
+% \end{macrocode}
+% \fi
+%
+%\title{Athenian Numerals II\footnote{The documentation of this
+% package is essentially the same as that of the package `grnumalt'.
+% The `II' serves as a means to distinguish the two documents.}}
+% \author{Apostolos Syropoulos\\366, 28th October Str.\\
+% GR-671 00 Xanthi, HELLAS\\ Email:\texttt{apostolo@platon.ee.duth.gr}}
+% \date{2003/08/24}
+%\maketitle
+%
+%\MakeShortVerb{\|}
+%
+%\section{Introduction}
+%
+% This \LaTeX\ package implements the macro
+% \DescribeMacro{\athnum}
+% |\athnum|. The macro transforms an Arabic numeral, i.e., the kind
+% of numerals we all use (e.g., 1, 5, 789 etc), to the corresponding
+% {\itshape Athenian} numeral. Athenian numerals were in use only in
+% ancient Athens. The package can be used only in conjunction with the
+% |greek| option of the |babel| package.
+%
+%\section{The Numbering System}
+%
+% The athenian numbering system, like the roman one, employs
+% letters to denote important numbers. Multiple occurrence of a letter denote
+% a multiple of the ``important'' number, e.g., the letter I denotes 1, so
+% III denotes 3. Here are the basic digits used in the Athenian numbering
+% system:
+% \begin{itemize}
+% \item I denotes the number one (1)
+% \item $\Pi$ denotes the number five (5)
+% \item $\Delta$ denotes the number ten (10)
+% \item H denotes the number one hundred (100)
+% \item X denotes the number one thousand (1000)
+% \item M denotes the number ten thousands (10000)
+%\end{itemize}
+% Moreover, the letters $\Delta$, H, X, and M under the letter $\Pi$,
+% denote five times their original value, e.g., the symbol
+% \PiIt{X}, denotes the number 5000, and the symbol
+% \PiIt{$\Delta$}, denotes the number 50. It must be noted that
+% the numbering system does not provide negative numerals or a symbol for
+% zero.
+%
+% The Athenian numbering system is described, among others, in an article in
+% Encyclopedia $\Delta o\mu\acute{\eta}$, Vol. 2, page 280, 7th edition,
+% Athens, October 2, 1975.
+%
+% \section{The Code}
+% Before we do anything further, we have to identify the package.
+% \StopEventually
+%
+% \begin{macrocode}
+%<*package>
+\NeedsTeXFormat{LaTeX2e}[1996/01/01]
+\ProvidesPackage{athnum}[2003/08/24\space v1.1]
+\typeout{Package: `athnum' v1.1\space <2003/08/24> (A. Syropoulos)}
+% \end{macrocode}
+% Next we check to see if the |babel| package is loaded with at least
+% the |greek| option. In case it isn't, we opt to produce an error message.
+% \begin{macrocode}
+\@ifpackagewith{babel}{greek}{}{%
+ \@ifpackagewith{babel}{polutonikogreek}{}{%
+ \PackageError{athnum}{%
+ `greek' option of the `babel'\MessageBreak
+ package hasn't been loaded}{%
+ The commands provided by this package\MessageBreak
+ are specially designed for greek language\MessageBreak
+ typesetting with the `babel' package. Load\MessageBreak
+ it with at least the `greek' option.}\relax
+ }}
+% \end{macrocode}
+%
+% As it is mentioned in the introduction, the Athenian numerals employ
+% some special digits. These digits are included in the |cb| fonts of
+% Claudio Beccari, and so we must provide access commands.
+% \begin{macrocode}
+\DeclareTextCommand{\PiDelta}{LGR}{\char"02\relax}
+\DeclareTextCommand{\PiEta}{LGR}{\char"03\relax}
+\DeclareTextCommand{\PiChi}{LGR}{\char"04\relax}
+\DeclareTextCommand{\PiMu}{LGR}{\char"05\relax}
+% \end{macrocode}
+%\begin{macro}{\@@athnum}
+% Now, we turn our attention to the definition of the macro
+% |\@@athnum|. This macro uses one integer variable (or counter in
+% \TeX's jargon.)
+% \begin{macrocode}
+\newcount\@ath@num
+% \end{macrocode}
+% The macro |\@@athnum| is also defined as a robust command.
+% \begin{macrocode}
+\DeclareRobustCommand*{\@@athnum}[1]{%
+% \end{macrocode}
+% After assigning to variable |\@ath@num| the value of the macro's argument,
+%we make sure that the argument is in the expected range, i.e., it is greater
+% than zero, and less or equal to $249999$. In case it isn't, we simply
+% produce a |\space|, warn the user about it and quit. Although, the
+% |\athnum| macro is capable to produce an Athenian numeral for even greater
+% intergers, the following argument by Claudio Beccari convised me to place
+% this above upper limit:
+% \begin{quote}
+% According to psychological perception studies (that ancient Athenians
+% and Romans perfectly knew without needing to study Freud and Jung)
+% living beings (which includes at least all vertebrates, not only
+% humans) can perceive up to four randomly set objects of the same kind
+% without the need of counting, the latter activity being a specific
+% acquired ability of human kind; the biquinary numbering notation
+% used by the Athenians and the Romans exploits this natural
+% characteristic of human beings.
+% \end{quote}
+% \begin{macrocode}
+ \@ath@num#1\relax
+ \ifnum\@ath@num<\@ne%
+ \space%
+ \PackageWarning{athnum}{%
+ Illegal value (\the\@ath@num) for athenian numeral}%
+ \else\ifnum\@ath@num>249999%
+ \space%
+ \PackageWarning{athnum}{%
+ Illegal value (\the\@ath@num) for athenian numeral}%
+ \else
+% \end{macrocode}
+% Having done all the necessary checks, we are now ready to do the actual
+% computation. If the number is greater than $49999$, then it certainly
+% has at least one \PiIt{M} ``digit''. We find all such digits by continuously
+% subtracting $50000$ from |\@ath@num|, until |\@ath@num| becomes less than
+% $50000$.
+% \begin{macrocode}
+ \@whilenum\@ath@num>49999\do{%
+ \PiMu\advance\@ath@num-50000}%
+% \end{macrocode}
+% We now check for tens of thousands.
+% \begin{macrocode}
+ \@whilenum\@ath@num>9999\do{%
+ M\advance\@ath@num-\@M}%
+% \end{macrocode}
+% Since a number can have only one \PiIt{X} ``digit'' (equivalent to 5000), it
+% is easy to check it out and produce the corresponding numeral in case it does
+% have one.
+% \begin{macrocode}
+ \ifnum\@ath@num>4999%
+ \PiChi\advance\@ath@num-5000%
+ \fi\relax
+% \end{macrocode}
+% Next, we check for thousands, the same way we checked for tens of thousands.
+% \begin{macrocode}
+ \@whilenum\@ath@num>999\do{%
+ Q\advance\@ath@num-\@m}%
+% \end{macrocode}
+% Like the five thousands, a numeral can have at most one \PiIt{H} ``digit''
+% (equivalent to 500).
+% \begin{macrocode}
+ \ifnum\@ath@num>499%
+ \PiEta\advance\@ath@num-500%
+ \fi\relax
+% \end{macrocode}
+% It is time to check hundreds, which follow the same pattern as thousands
+% \begin{macrocode}
+ \@whilenum\@ath@num>99\do{%
+ H\advance\@ath@num-100}%
+% \end{macrocode}
+% A numeral can have only one \PiIt{$\Delta$} ``digit'' (equivalent to 50).
+% \begin{macrocode}
+ \ifnum\@ath@num>49%
+ \PiDelta\advance\@ath@num-50%
+ \fi\relax
+% \end{macrocode}
+% Let's check now decades.
+% \begin{macrocode}
+ \@whilenum\@ath@num>9\do{%
+ D\advance\@ath@num by-10}%
+% \end{macrocode}
+% We check for five and, finally, for the digits 1, 2, 3, and 4.
+% \begin{macrocode}
+ \@whilenum\@ath@num>4\do{%
+ P\advance\@ath@num-5}%
+ \ifcase\@ath@num\or I\or II\or III\or IIII\fi%
+ \fi\fi}
+% \end{macrocode}
+%\end{macro}
+%
+%\begin{macro}{\@athnum}
+% The command |\@athnum| has one argument, which
+% is a counter. It calls the command |\@@athnum| to process the value of
+% the counter.
+% \begin{macrocode}
+\def\@athnum#1{%
+ \expandafter\@@athnum\expandafter{\the#1}}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\athnum}
+% The command |\athnum| is a wrapper that declares
+% a new counter in a local scope, assigns to it the argument of the command
+% and calls the macro |\@athnum|. This way the command can process correctly
+% either a number or a counter.
+% \begin{macrocode}
+\def\athnum#1{%
+ \@ath@num#1\relax
+ \@athnum{\@ath@num}}
+%</package>
+% \end{macrocode}
+%\end{macro}
+%
+% \section*{Acknowledgment}
+% I would like to thank Claudio Beccari for reading the documentation
+% and for his very helpful suggestions. In addition, Antonis Tsolomitis
+% spotted a bug in the first version, which is corrected in the present
+% version.
+% \section*{Dedication}
+% I would like to dedicate this piece of work to my son
+% \begin{center}Demetrios-Georgios.\end{center}
+% \Finale
+%
+\endinput
diff --git a/macros/latex/contrib/babel-contrib/greek/athnum.pdf b/macros/latex/contrib/babel-contrib/greek/athnum.pdf
new file mode 100644
index 0000000000..6301b00730
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/athnum.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/babel-greek.dtx b/macros/latex/contrib/babel-contrib/greek/babel-greek.dtx
new file mode 100644
index 0000000000..677eb4d480
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/babel-greek.dtx
@@ -0,0 +1,1326 @@
+% \iffalse meta-comment
+% !TEX encoding = UTF-8 Unicode
+%
+% Copyright 1989-2008 Apostolos Syropoulos, Johannes L. Braams
+% and the authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the babel-greek package.
+% ---------------------------------------------
+%
+% It may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2003/12/01 or later.
+%
+% This work has the LPPL maintenance status "maintained".
+%
+% The Current Maintainer of this work is Günter Milde <milde@users.sf.net>.
+%
+% Babel-greek is a contributed package providing support for the Greek
+% language and script via the Babel system (http://www.ctan.org/pkg/babel).
+%
+% The list of derived (unpacked) files belonging to this work
+% and covered by LPPL is defined by the unpacking script (babel-greek.ins)
+% which is part of the package.
+% \fi
+% \CheckSum{1552}
+%
+% \iffalse
+% Tell the \LaTeX\ system who we are and write an entry on the
+% transcript.
+%<*dtx>
+\ProvidesFile{babel-greek.dtx}
+%</dtx>
+%<code>\ProvidesLanguage{greek}
+%\fi
+%\ProvidesFile{babel-greek.dtx}
+ [2016/09/07 v1.9h Greek support for the babel system]
+%\iffalse
+%% File `babel-greek.dtx'
+%% Greek language Definition File
+%% Copyright © 1997, 2005 Apostolos Syropoulos, Johannes Braams
+%% Copyright © 2013, 2019 Günter Milde
+%
+%% Please report errors to: Günter Milde <milde@users.sf.net>
+%
+% This file is part of the babel-greek package, it provides the source
+% code for the greek language definition file. The original
+% version of this file was written by Apostolos Syropoulos.
+% It was then enhanced by adding code from kdgreek.sty from David
+% Kastrup <dak@gnu.org> with his
+% consent.
+%<*filedriver>
+\documentclass{ltxdoc}
+% \usepackage{lmodern}
+\usepackage[utf8]{inputenc}
+\usepackage{hyperref,bookmark}
+\hypersetup{colorlinks=true,linkcolor=blue,urlcolor=blue,citecolor=black}
+\newcommand*{\babel}{\textsf{babel}}
+\newcommand*{\note}[1]{}
+\newcommand*{\Lopt}[1]{\textsf{#1}}
+\newcommand*{\file}[1]{\texttt{#1}}
+\newcommand*{\pkg}[1]{\texttt{#1}}
+\begin{document}
+ \DocInput{babel-greek.dtx}
+\end{document}
+%</filedriver>
+%\fi
+% \GetFileInfo{babel-greek.dtx}
+%
+% \changes{greek-1.0b}{1996/07/10}{Replaced \cs{undefined} with
+% \cs{@undefined} and \cs{empty} with \cs{@empty} for consistency
+% with \LaTeX}
+% \changes{greek-1.0b}{1996/10/10}{Moved the definition of
+% \cs{atcatcode} right to the beginning}
+% \changes{greek-1.2}{1997/10/28}{Classical Greek is now a dialect}
+% \changes{greek-1.2b}{1997/11/01}{Classical Greek is now called
+% ``Polutoniko'' Greek. The previous name was at least misleading}
+% \changes{greek-1.2c}{1998/06/26}{This version conforms to version
+% 2.0 of the CB fonts and consequently we added a few new
+% symbol-producing commands}
+% \changes{greek-1.3a}{1998/07/04}{polutoniko is now an attribute to
+% Greek, no longer a `dialect'}
+% \changes{greek-1.4}{2013/05/17}{new maintainer}
+% \changes{greek-1.5}{2013/06/21}{bugfixes,
+% change some symbol macros to aliases,
+% LGR fixes via DeclareTextCommand instead of
+% extrasgreek/noextrasgreek definitions,
+% LICR macros in string definitions,
+% LGR font encoding not used with XeTeX/LuaTeX.}
+% \changes{greek-1.5a}{2013/06/27}{``extraspolutonikogreek'' definition
+% was missing with Xe/LuaTeX.
+% Replaced non-printable literal character with ^^-notation.}
+% \changes{greek-1.6}{2013/07/18}{fix \cs{@roman} and \cs{@Roman}
+% redefinition (thanks to Enrico Gregorio and Claudio Beccari),
+% load LICR macro definitions for Xe/LuaTeX.}
+% \changes{greek-1.7}{2013/09/09}{Do not load euenc.def with XeTeX/LuaTeX.
+% Prevent re-loading lgrenc.def.}
+% \changes{greek-1.7a}{2013/09/13}{bugfix: remove spurious ``fi''.}
+% \changes{greek-1.7b}{2013/10/01}{bugfix: correct upcasing of babel strings
+% with Xe/LuaTeX.}
+% \changes{babel-greek-1.8}{2013/11/27}{Rename to ``babel-greek.dtx''.
+% Restore compatibility with Xe/LuaTeX in 8-bit and Unicode mode.
+% Load ``euenc.def'' if EU1 or EU2 font encoding is detected.
+% New TextCommands ``greekscript'' and ``ensuregreek''.}
+% \changes{babel-greek-1.8a}{2013/12/03}{Set `encodingdefault' in `greekscript'
+% to fix Greek in footnotes etc. with document language Greek.}
+% \changes{babel-greek-1.9}{2014/07/20}{Added attribute for ancient Greek.
+% Load correct hyphenation patterns. Patch by Claudio Beccari.}
+% \changes{babel-greek-1.9b}{2014/09/18}{Remove spurious whitespace from
+% `extrasgreek' definition (report Eike Schmidt).
+% Use named macros instead of non-standard short accent macros for
+% psili and dasia.}
+% \changes{babel-greek-1.9c}{2014/10/21}{Fix dummy hyphenation language names
+% (report/patch Ulrike Fischer).}
+% \changes{babel-greek-1.9d}{2015/07/06}{uc-/lccode corrections from xgreek are now
+% in greek-euenc.def (the polyglossia version has bugs).}
+% \changes{babel-greek-1.9e}{2015/11/27}{Fix bug in lccode-setting loop
+% (patch by Enrico Gregorio).}
+% \changes{babel-greek-1.9f}{2016/02/04}{Support for standard
+% Unicode text encoding ``TU'' (new in fontspec v2.5a).}
+% \changes{babel-greek-1.9g}{2016/09/07}{Babel 3.9i deprecated textlatin
+% and fixed latinencoding.}
+% \changes{babel-greek-1.9h}{2019/07/11}{Move breathing composite commands
+% to textalpha.}
+%
+% \title{Babel support for the Greek language}
+% \author{Apostolos Syropoulos, Günter Milde}
+% \maketitle
+%
+% Babel-greek is a contributed package providing support for the Greek
+% language and script via the \href{http://www.ctan.org/pkg/babel}{Babel}
+% system. See the \href{README.html}{README} file for an overwiew of the
+% \pkg{babel-greek} package and links to requirements and related packages.
+%
+% The file \file{\filename}%
+% \footnote{
+% The file described in this section has version number \fileversion\
+% and was last revised on \filedate.
+% The original author is Apostolos Syropoulos, code from \file{kdgreek.sty}
+% by David Kastrup was used.}
+% is the literate source for the Babel language definition file
+% \file{greek.ldf}.
+%
+% \section{Requirements}
+%
+% Typesetting Greek with Babel requires (of course) the
+% \href{http://www.ctan.org/pkg/babel}{Babel core}, support for Greek font
+% encodings (\href{http://www.ctan.org/pkg/greek-fontenc}{greek-fontenc})
+% and a \href{README.html#greek-text-fonts}{text font supporting the
+% Greek script}.
+%
+% The \href{http://www.ctan.org/pkg/cbgreek-complete}{CB Greek fonts}
+% created by \textsc{Claudio Beccari}\footnote{Apostolos Syropoulos
+% wishes to thank Claudio Beccari for his
+% patience, collaboration, comments and suggestions.}
+% are a complete set of 8-bit TeX fonts matching \textsc{Knuth}'s
+% Computer Modern.
+% The package \pkg{\href{http://www.ctan.org/pkg/cbfonts-fd}{cbfonts-fd}}
+% sets them up as Greek substitute for the Computer Modern and Latin Modern
+% font families.
+% The \pkg{\href{http://www.ctan.org/pkg/substitutefont}{substitutefont}}
+% package can be used to set up Greek supplements for other
+% font families (like Times or Palatino).
+%
+% The \href{http://ctan.org/pkg/lm}{Latin Modern} OpenType font that is the
+% default font for XeTeX/LuaTeX does not support the Greek script. The user
+% needs to set up an alternative font like Linux Libertine or DejaVu with
+% \pkg{\href{http://www.ctan.org/pkg/fontspec}{fontspec}}.
+%
+% \section{Usage}
+%
+% To activate Greek support with babel, specify the option
+% \Lopt{greek}, either as global option or as option to the
+% \pkg{babel} package. Remember, that the \emph{last} language
+% option determines the document language, e.g.
+% \begin{verbatim}
+% \usepackage[greek,english]{babel}\end{verbatim}
+% activates support for Greek in an English document.
+% The default is modern ``monotonic'' Greek, while
+% \begin{verbatim}
+% \usepackage[english,greek]{babel}
+% \languageattribute{greek}{polutoniko}
+% \end{verbatim}
+% sets the document language to modern Greek with ``polytonic''
+% spelling and
+% \begin{verbatim}
+% \usepackage[english,greek]{babel}
+% \languageattribute{greek}{ancient}
+% \end{verbatim}
+% sets the document language to ancient Greek.
+%
+% Both attributes may also be used as modifiers as in
+% \begin{verbatim}
+% \usepackage[greek.polutoniko,english]{babel}
+% \end{verbatim}
+% and similarly
+% \begin{verbatim}
+% \usepackage[greek.ancient,english]{babel}
+% \end{verbatim}
+%
+% Version 1.9 fixes the activation of hyphenation patterns: By default,
+% \pkg{babel-greek} activates the modern Greek monotonic hyphenation;
+% the attribute/modifier |polutoniko| activates the modern Greek
+% polytonic hyphenation and the attribute/modifier |ancient| activates
+% the ancient Greek hyphenation. 8-bit TeX and XeTeX requires the
+% hyphenation patterns to be pre-loaded in the format file.
+% This is a limitation by TeX, common to all languages.
+% The LuaTeX engine loads hyphenation patterns on demand.
+%
+% \DescribeMacro\selectlanguage
+% \DescribeMacro\foreignlanguage
+% The Babel core provides two commands to switch the active language:
+% The declaration |\selectlanguage{greek}| switches to the Greek language.
+% The macro \verb|\foreignlanguage{greek}{<some text>}| sets its second argument
+% in the Greek language. This is intended for short text parts.
+% For details see the \href{http://www.ctan.org/pkg/babel}{Babel} documentation.
+%
+% For backwards compatibility, ``polytonic'' spelling can also be
+% selected via the dummy language \Lopt{polutonikogreek}. In this
+% case, the language name \Lopt{polutonikogreek} must also be
+% used for language switches with |\selectlanguage| or
+% |\foreignlanguage|. However, it is not possible to use
+% both options, \Lopt{greek} and \Lopt{polutonikogreek} in one document.
+%
+% \subsection{Input of Greek text}
+%
+% There are several alternatives to write Greek text.
+% \begin{itemize}
+% \item With the packages \pkg{inputenc} and
+% \pkg{\href{http://www.ctan.org/pkg/greek-inputenc}{greek-inputenc}},
+% literal Greek characters can be input using the utf-8, iso-8859-7,
+% or macgreek encoding.
+%
+% Literal input using the utf-8 encoding is also the standard input
+% method if compiling with the XeTeX and LuaTeX engines.
+%
+% \item The Latin transliteration defined by the LGR font encoding
+% is explained in the file \file{\href{usage.pdf}{usage.pdf}}.
+%
+% \item The package
+% \pkg{\href{http://www.ctan.org/pkg/greek-fontenc}{greek-fontenc}}
+% defines \emph{LaTeX internal character representation} (LICR) macros
+% for Greek letters and text symbols. It is required by \pkg{babel-greek},
+% so the |\textAlpha| \ldots |\textomega|
+% macros are a safe but cumbersome method to input Greek characters.
+%
+% \item The \pkg{alphabeta} package bundled with
+% \href{http://www.ctan.org/pkg/greek-fontenc}{greek-fontenc} makes the
+% short macro names |\Alpha| \ldots |\omega| available in text mode, too.
+% \end{itemize}
+% The \href{http://www.ctan.org/pkg/greek-fontenc}{greek-fontenc} bundle
+% has details and examples for all these input methods.
+%
+% \subsection{Greek vs. Latin script}
+% When switching the language to Greek, \pkg{babel-greek} ensures that the
+% Greek script is supported.
+% With 8-bit LaTeX, Greek text fonts use a non-standard
+% font encoding\footnote{LaTeX font encodings are described in
+% the \emph{LaTeX font guide} (fntguide.pdf).}
+% (LGR) that misses Latin letters. Latin characters in the source are
+% instead interpreted as a transcription for Greek characters.
+% The following macros allow the use of Greek vs. Latin script without
+% changing the active language.
+% \DescribeMacro\greekscript
+% \DescribeMacro\greektext
+% The \emph{TextCommand}\footnote{For a discussion of TextCommands, see
+% the \emph{LaTeX font guide} (fntguide.pdf), too.}
+% |\greekscript| switches to a font encoding
+% supporting the Greek script.
+% The declaration |\greektext| always switches the font encoding
+% to LGR. Both declarations do not change the active language.
+% \DescribeMacro\latintext
+% |\latintext| (defined by the Babel
+% core) can be used to switch back to an encoding supporting the Latin
+% script (deprecated since Babel 3.9i from March 2014).
+%
+% \DescribeMacro\ensuregreek
+% \DescribeMacro\textgreek
+% The macros |\ensuregreek| and |\textgreek| take one argument
+% which is typeset using a font encoding supporting the Greek
+% script. While |\ensuregreek| only switches the
+% font encoding if required, |\textgreek| always uses the LGR font
+% encoding.
+% \DescribeMacro\textlatin
+% The Babel core defines a corresponding |\textlatin| macro
+% (deprecated in favour of |\ensureascii| in Babel 3.9i from March 2014).
+%
+% \section{Greek numbering}
+%
+% The Greek alphabetical numbering system, like the Roman one, is
+% still used in everyday life for short enumerations. Unfortunately
+% most Greeks don't know how to write Greek numbers bigger than 20 or
+% 30. Nevertheless, in official editions of the last century and
+% beginning of this century this numbering system was also used for
+% dates and numbers in the range of several thousands. Nowadays
+% this numbering system is primary used by the Eastern Orthodox
+% Church and by certain scholars. It is hence necessary to be able
+% to typeset any Greek numeral up to \hbox{999\,999}. Here are the
+% conventions:
+% \begin{itemize}
+% \item There is no Greek numeral for any number less than or equal
+% to $0$.
+% \item Numbers from $1$ to $9$ are denoted by letters alpha, beta,
+% gamma, delta, epsilon, stigma, zeta, eta, theta, followed by a
+% mark similar to the mathematical symbol ``prime''. (Nowadays
+% instead of letter stigma the digraph sigma tau is used for number
+% $6$. Mainly because the letter stigma is not always available, so
+% people opt to write down the first two letters of its name as an
+% alternative. In our implementation we produce the letter stigma,
+% not the digraph sigma tau.)
+% \item Decades from $10$ to $90$ are denoted by letters iota,
+% kappa, lambda, mu, nu, xi, omikron, pi, qoppa, again followed by
+% the numeric mark. The qoppa used for this purpose has a special
+% zig-zag form, which doesn't resemble at all the original
+% `q'-like qoppa.
+% \item Hundreds from $100$ to $900$ are denoted by letters rho,
+% sigma, tau, upsilon, phi, chi, psi, omega, sampi, followed by the
+% numeric mark.
+% \item Any number between $1$ and $999$ is obtained by a group of
+% letters denoting the hundreds decades and units, followed by a
+% numeric mark.
+% \item To denote thousands one uses the same method, but this time
+% the mark is placed in front of the letter, and under the baseline
+% (it is inverted by 180 degrees). When a group of letters denoting
+% thousands is followed by a group of letters denoting a number
+% under $1000$, then both marks are used.
+% \end{itemize}
+%
+% Using these conventions one obtains numbers up to \hbox{999\,999}.
+% \DescribeMacro{\greeknumeral}
+% The command |\greeknumeral| makes it possible to typeset Greek
+% numerals. There is also an
+% \DescribeMacro{\Greeknumeral}
+% ``uppercase'' version of this macro: |\Greeknumeral|.
+%
+% Another system which was in wide use only in Athens, could
+% express any positive number. This system is implemented in
+% package |athnum|.
+%
+% \StopEventually{}
+%
+% \section{Implementation}
+%
+% The macro |\LdfInit| takes care of preventing that this file is
+% loaded more than once, checking the category code of the
+% \texttt{@} sign, etc.
+% \changes{greek-1.0b}{1996/11/02}{Now use \cs{LdfInit} to perform
+% initial checks}
+% \begin{macrocode}
+%<*code>
+\LdfInit\CurrentOption{captions\CurrentOption}
+% \end{macrocode}
+% When the option \Lopt{polutonikogreek} was used, redefine
+% |\CurrentOption| to prevent problems later on.
+% \begin{macrocode}
+\gdef\CurrentOption{greek}
+% \end{macrocode}
+%
+% Hyphenation patterns:
+% When this file is read as an option, i.e. by the |\usepackage|
+% command, \texttt{greek} could be an `unknown' language in
+% which case we have to make it known. So we check for the
+% existence of the three variants of the Greek language
+% |\l@greek|, |\l@monogreek|, and |l@ancientgreek| to see whether
+% we have to do something here.
+% \changes{greek-1.9}{2014/07/20}{Support all 3 language (hyphenation)
+% variants.}
+% \begin{macrocode}
+\ifx\l@greek\@undefined
+ \@nopatterns{greek}
+ \adddialect\l@greek 0\fi
+\ifx\l@monogreek\@undefined
+ \adddialect\l@monogreek 0\fi
+\ifx\l@ancientgreek\@undefined
+ \adddialect\l@ancientgreek 0\fi
+\newcount\bbl@monogreek \bbl@monogreek=\l@monogreek
+\newcount\bbl@polygreek \bbl@polygreek=\l@greek
+\newcount\bbl@ancientgreek \bbl@ancientgreek=\l@ancientgreek
+% \end{macrocode}
+% The |\extrasgreek| macro is called when switching the language to Greek.
+% We collect code for polytonic and ancient greek in the macros
+% |extraspolutonikogreek| and |extrasancientgreek| and add it later to
+% |extrasgreek|.
+% \begin{macrocode}
+\addto\extrasgreek{\let\l@greek\bbl@monogreek\relax}
+\addto\extraspolutonikogreek{\l@greek=\bbl@polygreek}
+\addto\extrasancientgreek{\l@greek=\bbl@ancientgreek}
+% \end{macrocode}
+%
+% Now we declare the |polutoniko| language attribute.
+% \begin{macrocode}
+\bbl@declare@ttribute{greek}{polutoniko}{%
+% \end{macrocode}
+% This code adds the expansion of |\extraspolutonikogreek| to
+% |\extrasgreek| and changes the definition of |\today| for Greek
+% to produce polytonic month names (by re-defining |\gr@month|).
+% \begin{macrocode}
+ \expandafter\addto\expandafter\extrasgreek
+ \expandafter{\extraspolutonikogreek}%
+ \let\captionsgreek\captionspolutonikogreek
+ \let\gr@month\gr@c@month
+% \end{macrocode}
+% We need to take some extra precautions in order not to break
+% older documents which still use the old \Lopt{polutonikogreek}
+% pseuso-language option: language switching commands like
+% |\selectlanguage{polutonikogreek}|, call the
+% |extraspolutonikogreek| macro, set the language to |\l@polutonikogreek|
+% and use |\datepolutonikogreek| for |\today|. We define aliases:
+% \changes{greek-1.3f}{1999/09/29}{Added some code to make older
+% documents work}
+% \changes{greek-1.3g}{2000/02/04}{\cs{noextraspolutonikogreek} was
+% missing}
+% \begin{macrocode}
+ \let\l@polutonikogreek\l@greek
+ \let\datepolutonikogreek\dategreek
+ \let\extraspolutonikogreek\extrasgreek
+ \let\noextraspolutonikogreek\noextrasgreek
+ }
+% \end{macrocode}
+% The |ancient| language attribute is used for classical Greek.
+% \changes{greek-1.9}{2014/07/20}{Add support for ancient Greek.}
+% \begin{macrocode}
+\bbl@declare@ttribute{greek}{ancient}{%
+% \end{macrocode}
+% This attribute adds the expansion of |\extraspolutonikogreek| and
+% |\extrasancientgreek| to |\extrasgreek| to set up support for
+% multi-accented characters and ancient hyphenation patterns.
+% Auto-strings (captions) are specific to ancient Greek while |\today|
+% uses modern polytonic month names (as there existed incompatible
+% sets of month names and no common calendar in ancient Greece.
+% \begin{macrocode}
+ \expandafter\addto\expandafter\extrasgreek
+ \expandafter{\extraspolutonikogreek}% multi-accented letters
+ \expandafter\addto\expandafter\extrasgreek
+ \expandafter{\extrasancientgreek}%
+ \let\captionsgreek\captionsancientgreek
+ \let\gr@month\gr@c@month % (modern) polytonic month names
+ }
+% \end{macrocode}
+%
+% \section{Font setup}
+%
+% Typesetting Greek texts requires a font with Greek characters:
+%
+% For 8-bit LaTeX, this package uses fonts with the
+% \href{http://www.ctan.org/pkg/greek-fontenc}{LGR font encoding}.
+% With the XeTeX or LuaTeX engines and Unicode fonts, the user must ensure
+% that the selected font contains the required glyphs.
+% LGR-encoded fonts can also be used alongside Unicode fonts with XeTeX/LuaTeX
+% to enable the input of Greek letters via the Latin transcription provided by
+% this font encoding.
+%
+% \changes{greek-1.2a}{1997/10/31}{filename \file{lgrenc.def} now
+% lowercase}
+% \changes{greek-1.4}{2013/05/17}{\file{lgrenc.def} moved to the
+% separate package `greek-fontenc'}
+% \changes{greek-1.5}{2013/06/21}{LGR setup skipped with XeTeX/LuaTeX}
+% \changes{greek-1.7}{2013/09/09}{Do not load euenc.def with XeTeX/LuaTeX
+% (too complicated to get it right).}
+% \changes{greek-1.8}{2013/11/30}{Check for EU1/EU2 font encoding
+% instead of engine}
+% \changes{babel-greek-1.9f}{2016/02/04}{Check also for TU font encoding.}
+%
+% \DescribeMacro\greekfontencoding
+% We test for available font encodings and set |\greekfontencoding|
+% and the internal macro |\bbl@greek@fontencdef| with the name of the
+% font definition file with Greek LICR macros. The fallback is LGR.
+% \begin{macrocode}
+\@ifl@aded{def}{tuenc}{
+ \providecommand*{\greekfontencoding}{TU}
+ \providecommand*{\bbl@greek@fontencdef}{greek-euenc}
+ \renewcommand*{\LastDeclaredEncoding}{TU}
+}{}
+\@ifl@aded{def}{eu1enc}{
+ \providecommand*{\greekfontencoding}{EU1}
+ \providecommand*{\bbl@greek@fontencdef}{greek-euenc}
+ \renewcommand*{\LastDeclaredEncoding}{EU1}
+}{}
+\@ifl@aded{def}{eu2enc}{
+ \providecommand*{\greekfontencoding}{EU2}
+ \providecommand*{\bbl@greek@fontencdef}{greek-euenc}
+ \renewcommand{\LastDeclaredEncoding}{EU2}
+}{}
+\providecommand*{\greekfontencoding}{LGR}
+\providecommand*{\bbl@greek@fontencdef}{lgrenc}
+% \end{macrocode}
+% Ensure that the Greek LICR macros are available:
+% \begin{macrocode}
+\@ifl@aded{def}{\bbl@greek@fontencdef}{}{
+ \InputIfFileExists{\bbl@greek@fontencdef .def}{}{
+ \errhelp{I can't find the \bbl@greek@fontencdef .def file
+ for the Greek fonts}%
+ \errmessage{Font support for the Greek script missing.^^J
+ babel-greek can't typeset Greek.^^J
+ Install the "greek-fontenc" package^^J
+ or use XeTeX/LuaTeX with polyglossia.}%
+ \@@end
+ }
+}
+% \end{macrocode}
+% \begin{macro}{\greekscript}
+% The TextCommand |\greekscript| is a declaration that switches the font
+% encoding to |\greekfontencoding| if the current font encoding does not
+% provide a (typically empty) local variant.
+% \changes{greek-1.8.1}{2013/12/03}{Set `encodingdefault' in `greekscript'
+% to fix Greek in footnotes etc. with document language Greek.
+% TODO: This is from `greektext' but are there side effects?}
+% \begin{macrocode}
+\ProvideTextCommandDefault{\greekscript}{%
+ \fontencoding{\greekfontencoding}\selectfont
+ \def\encodingdefault{\greekfontencoding}}
+% \end{macrocode}
+% \end{macro}
+% \begin{macro}{\ensuregreek}
+% The TextCommand |\ensuregreek| sets it argument in |\greekfontencoding|
+% if the current font encoding does not provide a (typically empty) local
+% variant.
+% \begin{macrocode}
+\ProvideTextCommandDefault{\ensuregreek}[1]{%
+ \leavevmode{\greekscript #1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{Fixes for the LGR font encoding}
+%
+% \begin{macrocode}
+\@ifl@aded{def}{lgrenc}{%
+% \end{macrocode}
+%
+% We redefine a few commands in the LGR encoding to work around problems
+% because LGR is no \emph{standard text encoding} but has Greek letters in
+% the places of Latin ones.
+% \changes{greekfdd-2.2c}{1999/04/05}{Fixed typos, \cs{textrademark}
+% misses a `t', \cs{copyright} should be \cs{textcopyright}}
+% \changes{greekfdd-2.2d}{1999/04/25}{removed redefinition of \cs{\&}}
+% \changes{greek-1.4}{2013/05/17}{moved here from \file{lgrenc.def} because
+% the definitions require the \texttt{\textbackslash latintext} macro
+% defined by Babel.}
+% \changes{greek-1.5}{2013/05/27}{enable use of "textcomp" characters
+% for "textcopyright" and "textregistered" macros}
+% \changes{greek-1.5}{2013/06/15}{\textbackslash & made TextCommand}
+%
+% \begin{macrocode}
+ \ProvideTextCommand{\textcopyright}{LGR}{\ensureascii{\textcopyright}}
+ \ProvideTextCommand{\textregistered}{LGR}{\ensureascii{\textregistered}}
+ \ProvideTextCommand{\texttrademark}{LGR}{\ensureascii{\texttrademark}}
+ \let\ltx@amp\&
+ \DeclareTextCommandDefault{\&}{\ltx@amp}
+ \DeclareTextCommand{\&}{LGR}{\ensureascii{\ltx@amp}}
+ \ProvideTextCommand{\SS}{LGR}{\ensureascii{\SS}}
+% \end{macrocode}
+%
+% \begin{macro}{\greek@roman}
+% \begin{macro}{\greek@Roman}
+% \changes{greek-1.2e}{1999/04/16}{Moved redefinition of \cs{@roman}
+% back to the language specific file}
+% \changes{greek-1.3d}{1999/08/27}{\cs{@roman} and \cs{@Roman} need to
+% be added to \cs{extraspolutonikogreek}}
+% \changes{greek-1.3e}{1999/09/24}{\cs{@roman} and \cs{@Roman} need
+% \emph{not} be in \cs{extraspolutonikogreek} when they are already
+% in \cs{extrasgreek}}
+% \changes{greek-1.5}{2013/06/15}{\cs{@roman} and \cs{@Roman} as TextCommands
+% (BUG: this extended the expansion problem to all languages!)}
+% \changes{greek-1.6}{2013/07/19}{apply a patch by Enrico Gregorio.
+% Thanks to Claudio Beccari for testing and reporting.}
+%
+% To prevent roman numerals being typeset in greek letters we need
+% to adopt the internal \LaTeX\ commands |\@roman| and
+% |\@Roman|. \emph{Up to version 1.5, the definition caused errors where
+% |\@roman| ends up in a situation where the argument needs to be expanded
+% (e.g. Roman page numbers in the ToC).}
+% \begin{macrocode}
+ \def\@roman#1{\expandafter\ensureascii\expandafter{\romannumeral#1}}
+ \def\@Roman#1{\expandafter\ensureascii\expandafter{%
+ \expandafter\@slowromancap\romannumeral#1@}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% Now we define two commands that switch
+% to the LGR font encoding. The Babel core defines corresponding commands
+% to switch to a Latin font encoding.
+%
+% \begin{macro}{\greektext}
+% The declaration |\greektext| switches to LGR.
+% For shorter pieces of text the |\textgreek| macro should be
+% used.
+% \begin{macrocode}
+ \DeclareRobustCommand{\greektext}{%
+ \fontencoding{LGR}\selectfont
+ \def\encodingdefault{LGR}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\textgreek}
+% This command takes an argument which is then typeset using the
+% LGR font encoding. In order to avoid many encoding switches
+% it operates in a local scope.
+% \changes{greek-1.0b}{1996/09/23}{Added a level of braces to keep
+% encoding change local}
+% \changes{greek-1.3k}{2003/03/19}{Added \cs{leavevmode} as was done
+% with \cs{latintext}}
+% \begin{macrocode}
+ \DeclareRobustCommand{\textgreek}[1]{\leavevmode{\greektext #1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\textol}
+% The \href{http://www.ctan.org/pkg/cbgreek-complete}{CB Greek fonts}
+% contain an outline family. In order to make it available,
+% we define the command |\textol|. (This font-specific macro does not
+% fit in a language defintion file is and only kept for backwards
+% compatibility.)
+% \begin{macrocode}
+ \def\outlfamily{\usefont{LGR}{cmro}{m}{n}}
+ \DeclareTextFontCommand{\textol}{\outlfamily}
+}{} % End of LGR fixes.
+% \end{macrocode}
+% \end{macro}
+%
+% \section{Definitions for the Greek language}
+%
+% The next step consists in defining commands to switch to (and
+% from) the Greek language.
+%
+% \begin{macro}{\greekhyphenmins}
+% This macro is used to store the correct values of the hyphenation
+% parameters |\lefthyphenmin| and |\righthyphenmin|.
+% \changes{greek-1.3h}{2000/09/22}{Now use \cs{providehyphenmins} to
+% provide a default value}
+% \begin{macrocode}
+% Yannis Haralambous has suggested this value
+\providehyphenmins{\CurrentOption}{\@ne\@ne}
+% \end{macrocode}
+% \end{macro}
+%
+% \changes{greek-1.1e}{1997/10/12}{Added caption name for proof}
+% \changes{greek-1.3d}{1999/08/28}{Fixed typo, \texttt{bl'epe ep'ishc}
+% instead of \texttt{bl'pe ep'ishc}}
+%
+% \begin{macro}{\captionsgreek}
+% The macro |\captionsgreek| defines all strings used in the
+% four standard document classes provided with \LaTeX.
+% \changes{greek-1.3h}{2000/09/20}{Added \cs{glossaryname}}
+% \changes{greek-1.3i}{2000/10/02}{The final sigma in all names appears
+% as `s' instead of `c'.}
+% \begin{macrocode}
+\addto\captionsgreek{%
+ \def\prefacename{\textPi\textrho\acctonos\textomicron\textlambda
+ \textomicron\textgamma\textomicron\textfinalsigma}%
+ \def\refname{\textAlpha\textnu\textalpha
+ \textphi\textomicron\textrho\acctonos\textepsilon\textfinalsigma}%
+ \def\abstractname{\textPi\textepsilon\textrho\acctonos\textiota
+ \textlambda\texteta\textpsi\texteta}%
+ \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota\textomicron
+ \textgamma\textrho\textalpha\textphi\acctonos\textiota\textalpha}%
+ \def\chaptername{\textKappa\textepsilon\textphi\acctonos\textalpha
+ \textlambda\textalpha\textiota\textomicron}%
+ \def\appendixname{\textPi\textalpha\textrho\acctonos\textalpha\textrho
+ \texttau\texteta\textmu\textalpha}%
+ \def\contentsname{\textPi\textepsilon\textrho\textiota
+ \textepsilon\textchi\acctonos\textomicron\textmu\textepsilon
+ \textnu\textalpha}%
+ \def\listfigurename{\textKappa\textalpha\texttau\acctonos\textalpha
+ \textlambda\textomicron\textgamma\textomicron\textfinalsigma{}
+ \textSigma\textchi\texteta\textmu\acctonos\textalpha\texttau
+ \textomega\textnu}%
+ \def\listtablename{\textKappa\textalpha\texttau\acctonos\textalpha
+ \textlambda\textomicron\textgamma\textomicron\textfinalsigma{}
+ \textPi\textiota\textnu\acctonos\textalpha\textkappa\textomega\textnu}%
+ \def\indexname{\textEpsilon\textupsilon\textrho\textepsilon
+ \texttau\acctonos\texteta\textrho\textiota\textomicron}%
+ \def\figurename{\textSigma\textchi\acctonos\texteta\textmu\textalpha}%
+ \def\tablename{\textPi\acctonos\textiota\textnu\textalpha
+ \textkappa\textalpha\textfinalsigma}%
+ \def\partname{\textMu\acctonos\textepsilon\textrho\textomicron
+ \textfinalsigma}%
+ \def\enclname{\textSigma\textupsilon\textnu\texteta\textmu
+ \textmu\acctonos\textepsilon\textnu\textalpha}%
+ \def\ccname{\textKappa\textomicron\textiota\textnu\textomicron
+ \textpi\textomicron\acctonos\textiota\texteta\textsigma\texteta}%
+ \def\headtoname{\textPi\textrho\textomicron\textfinalsigma}%
+ \def\pagename{\textSigma\textepsilon\textlambda\acctonos\textiota
+ \textdelta\textalpha}%
+ \def\seename{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon}%
+ \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon{}
+ \textepsilon\textpi\acctonos\textiota\textsigma\texteta\textfinalsigma}%
+ \def\proofname{\textAlpha\textpi\acctonos\textomicron
+ \textdelta\textepsilon\textiota\textxi\texteta}%
+ \def\glossaryname{\textGamma\textlambda\textomega\textsigma
+ \textsigma\acctonos\textalpha\textrho\textiota}%
+ }
+% \end{macrocode}
+% \end{macro}
+% \changes{greek-1.2}{1997/10/28}{Added caption names for
+% \cs{polutonikogreek}}
+% \changes{greek-1.3d}{1999/08/28}{Fixed typo, \texttt{bl'epe >ep'ishc}
+% instead of \texttt{bl'pe >ep'ishc}}
+%
+% \begin{macro}{\captionspolutonikogreek}
+% For texts written in the $\pi o\lambda\upsilon\tau
+% o\nu\kappa\acute{o}$ (polytonic greek) the translations are
+% the same as above, but some words are spelled differently. For
+% now we just add extra definitions to |\captionsgreek| in order to
+% override the earlier definitions.
+% \begin{macrocode}
+\let\captionspolutonikogreek\captionsgreek
+\addto\captionspolutonikogreek{%
+ \def\refname{\accpsili\textAlpha\textnu\textalpha
+ \textphi\textomicron\textrho\accvaria\textepsilon\textfinalsigma}%
+ \def\indexname{\textEpsilon\accdasia\textupsilon\textrho\textepsilon
+ \texttau\acctonos\texteta\textrho\textiota\textomicron}%
+ \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu\textalpha}%
+ \def\headtoname{\textPi\textrho\accvaria\textomicron\textfinalsigma}%
+ \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon{}
+ \accpsili\textepsilon\textpi\acctonos\textiota\textsigma\texteta\textfinalsigma}%
+ \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron
+ \textdelta\textepsilon\textiota\textxi\texteta}%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \changes{babel-greek-1.9}{2014/07/20}{Added caption names for
+% \cs{ancientgreek}}
+%
+% \begin{macro}{\captionsancientgreek}
+% For texts written in ancient Greek, we took
+% the translations from Apostolos Syropoulos' |xgreek| package. For
+% now we just add extra definitions to |\captionsgreek| in order to
+% override the earlier definitions.
+% \begin{macrocode}
+\let\captionsancientgreek\captionsgreek
+\addto\captionsancientgreek{%
+ \def\prefacename{\textPi\textrho\textomicron\textomicron\acctonos\textiota\textmu
+ \textiota\textomicron\textnu}%
+ \def\refname{\accpsili\textAlpha\textnu\textalpha\textphi\textomicron\textrho
+ \textalpha\accvaria\textiota}%
+ \def\abstractname{\textPi\textepsilon\textrho\acctonos\textiota\textlambda\texteta
+ \textpsi\textiota\textvarsigma}%
+ \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota\textomicron
+ \textgamma\textrho\textalpha\textphi\acctonos\textiota\textalpha}%
+ \def\chaptername{\textKappa\textepsilon\textphi\acctonos\textalpha\textlambda
+ \textalpha\textiota\textomicron\textnu}%
+ \def\appendixname{\textPi\textalpha\textrho\acctonos\textalpha\textrho\texttau
+ \texteta\textmu\textalpha}%
+ \def\contentsname{\textPi\textepsilon\textrho\textiota\textepsilon\textchi
+ \acctonos\textomicron\textmu\textepsilon\textnu\textalpha}%
+ \def\listfigurename{\textKappa\textalpha\texttau\acctonos\textalpha\textlambda
+ \textomicron\textgamma\textomicron\textvarsigma{}
+ \textsigma\textchi\texteta\textmu\acctonos\textalpha\texttau\textomega\textnu}%
+ \def\listtablename{\textKappa\textalpha\texttau\acctonos\textalpha\textlambda
+ \textomicron\textgamma\textomicron\textvarsigma{}
+ \textpi\textiota\textnu\acctonos\textalpha\textkappa\textomega\textnu}%
+ \def\indexname{\textEpsilon\accdasia\textupsilon\textrho\textepsilon\texttau
+ \acctonos\texteta\textrho\textiota\textomicron\textnu}%
+ \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu\textalpha}%
+ \def\tablename{\textPi\acctonos\textiota\textnu\textalpha\textxi}%
+ \def\partname{\textMu\acctonos\textepsilon\textrho\textomicron\textvarsigma}%
+ \def\enclname{\textSigma\textupsilon\textnu\texteta\textmu\textmu
+ \acctonos\textepsilon\textnu\textomega\textvarsigma}%
+ \def\ccname{\textKappa\textomicron\textiota\textnu\textomicron\textpi
+ \textomicron\acctonos\textiota\texteta\textsigma\textiota\textvarsigma}%
+ \def\headtoname{\textPi\textrho\accvaria\textomicron\textvarsigma}%
+ \def\pagename{\textSigma\textepsilon\textlambda\accvaria\textiota\textvarsigma}%
+ \def\seename{\accdasiavaria\textomicron\textrho\textalpha}%
+ \def\alsoname{\accdasiavaria\textomicron\textrho\textalpha{} \accdasia\textomega\textsigma
+ \textalpha\acctonos\textupsilon\texttau\textomega\textvarsigma}%
+ \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron\textdelta\textepsilon
+ \textiota\textxi\textiota\textvarsigma}%
+ \def\glossaryname{\textGamma\textlambda\textomega\textsigma\textsigma
+ \acctonos\textalpha\textrho\textiota\textomicron\textnu}%
+ }
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\gr@month}
+% \changes{greek-1.1e}{1997/10/12}{Macro added}
+% \begin{macro}{\dategreek}
+% The macro |\dategreek| redefines the command |\today| to
+% produce greek dates. The name of the month is now produced
+% by the macro |\gr@month| since it is needed in the definition
+% of the macro |\Grtoday|.
+% \changes{greek-1.1a}{1997/03/03}{Fixed typo, \texttt{Oktwbr'iou}
+% instead of \texttt{Oktobr'iou}}
+% \changes{greek-1.1d}{1997/10/12}{Macro \cs{gr@month} now produces
+% the name of the month}
+% \changes{greek-1.2a}{1997/10/31}{Use \cs{edef} to define \cs{today}}
+% \changes{greek-1.2b}{1998/03/28}{use \cs{def} instead of \cs{edef}}
+% \begin{macrocode}
+\def\gr@month{%
+ \ifcase\month\or
+ \textIota\textalpha\textnu\textomicron\textupsilon\textalpha
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon
+ \textalpha\textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textMu\textalpha\textrho\texttau\acctonos\textiota\textomicron\textupsilon
+ \or \textAlpha\textpi\textrho\textiota\textlambda\acctonos\textiota
+ \textomicron\textupsilon \or
+ \textMu\textalpha\'"\textiota\textomicron\textupsilon \or
+ \textIota\textomicron\textupsilon\textnu\acctonos\textiota
+ \textomicron\textupsilon \or
+ \textIota\textomicron\textupsilon\textlambda\acctonos\textiota
+ \textomicron\textupsilon \or
+ \textAlpha\textupsilon\textgamma\textomicron\acctonos\textupsilon
+ \textsigma\texttau\textomicron\textupsilon \or
+ \textSigma\textepsilon\textpi\texttau\textepsilon\textmu
+ \textbeta\textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textOmicron\textkappa\texttau\textomega\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textNu\textomicron\textepsilon\textmu\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textDelta\textepsilon\textkappa\textepsilon\textmu\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon
+ \fi
+}
+\def\dategreek{%
+ \def\today{\number\day \space \gr@month\space \number\year}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\gr@c@greek}
+% \changes{greek-1.2}{1997/10/28}{Added macro \cs{gr@cl@month}}
+% \changes{greek-1.2}{1997/10/28}{Added macro
+% \cs{datepolutonikogreek}}
+% \changes{greek-1.3a}{1997/10/28}{removed macro
+% \cs{datepolutonikogreek}}
+% \begin{macrocode}
+\def\gr@c@month{%
+ \ifcase\month\or
+ \accpsili\textIota\textalpha\textnu\textomicron\textupsilon\textalpha
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon
+ \textalpha\textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textMu\textalpha\textrho\texttau\acctonos\textiota\textomicron
+ \textupsilon \or
+ \accpsili\textAlpha\textpi\textrho\textiota\textlambda
+ \acctonos\textiota\textomicron\textupsilon \or
+ \textMu\textalpha\"'\textiota\textomicron\textupsilon \or
+ \accpsili\textIota\textomicron\textupsilon\textnu
+ \acctonos\textiota\textomicron\textupsilon \or
+ \accpsili\textIota\textomicron\textupsilon\textlambda
+ \acctonos\textiota\textomicron\textupsilon \or
+ \textAlpha\accpsili\textupsilon\textgamma\textomicron\acctonos
+ \textupsilon\textsigma\texttau\textomicron\textupsilon \or
+ \textSigma\textepsilon\textpi\texttau\textepsilon\textmu\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \accpsili\textOmicron\textkappa\texttau\textomega\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textNu\textomicron\textepsilon\textmu\textbeta
+ \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \textDelta\textepsilon\textkappa\textepsilon\textmu
+ \textbeta\textrho\acctonos\textiota\textomicron\textupsilon
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\Grtoday}
+% \changes{greek-1.1}{1996/10/28}{Added macro \cs{Grtoday}}
+% The macro |\Grtoday| produces the current date, only that the
+% month and the day are shown as greek numerals instead of arabic
+% as it is usually the case.
+% \begin{macrocode}
+\def\Grtoday{%
+ \expandafter\Greeknumeral\expandafter{\the\day}\space
+ \gr@c@month \space
+ \expandafter\Greeknumeral\expandafter{\the\year}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\extrasgreek}
+% \begin{macro}{\noextrasgreek}
+% The macro |\extrasgreek| will perform all the extra definitions
+% needed for the Greek language. The macro |\noextrasgreek| is used
+% to cancel the actions of |\extrasgreek|. For the moment these
+% macros switch the fontencoding (with 8-bit TeX) and the definition of
+% the internal macros |\@alph| and |\@Alph| because in Greek we do use
+% the Greek numerals.
+% \changes{greek-1.5}{2013/06/21}{LGR not used with XeTeX/LuaTeX.}
+% \changes{greek-1.8}{2013/11/27}{use font-encoding specific TextCommands.
+% Use EU1 or EU2 for Latin script if available}
+% \begin{macrocode}
+\addto\extrasgreek{\greekscript}
+\addto\noextrasgreek{\latintext}
+% \addto\noextrasgreek{\RestoreFontEncoding} % TODO define \RestoreFontEncoding
+% \end{macrocode}
+%
+% \begin{macro}{\gr@ill@value}
+% When the argument of |\greeknumeral| has a value outside of the
+% acceptable bounds ($0 < x < 999999$) a warning will be issued
+% (and nothing will be printed).
+% \begin{macrocode}
+\def\gr@ill@value#1{%
+ \PackageWarningNoLine{babel}{Illegal value (#1) for greeknumeral}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\anw@true}
+% \begin{macro}{\anw@false}
+% \begin{macro}{\anw@print}
+% When a a large number with three \emph{trailing} zero's is to be
+% printed those zeros \emph{and} the numeric mark need to be
+% discarded. As each `digit' is processed by a separate macro
+% \emph{and} because the processing needs to be expandable we need
+% some helper macros that help remember to \emph{not} print the
+% numeric mark (|\anwtonos|).
+%
+% The command |\anw@false| switches the printing of the numeric
+% mark off by making |\anw@print| expand to nothing. The command
+% |\anw@true| (re)enables the printing of the numeric marc. These
+% macro's need to be robust in order to prevent improper expansion
+% during writing to files or during |\uppercase|.
+% \begin{macrocode}
+\DeclareRobustCommand\anw@false{%
+ \DeclareRobustCommand\anw@print{}}
+\DeclareRobustCommand\anw@true{%
+ \DeclareRobustCommand\anw@print{\textdexiakeraia}} % \anwtonos
+\anw@true
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\greeknumeral}
+% The command |\greeknumeral| needs to be \emph{fully} expandable
+% in order to get the right information in auxiliary
+% files. Therefore we use a big |\if|-construction to check the
+% value of the argument and start the parsing at the right level.
+% \begin{macrocode}
+\def\greeknumeral#1{%
+% \end{macrocode}
+% If the value is negative or zero nothing is printed and a warning
+% is issued.
+% \changes{greek-1.3b}{1999/04/03}{Added \cs{expandafter} and
+% \cs{number} (PR3000) in order to make a counter an acceptable
+% argument}
+% \begin{macrocode}
+ \ifnum#1<\@ne\space\gr@ill@value{#1}%
+ \else
+ \ifnum#1<10\expandafter\gr@num@i\number#1%
+ \else
+ \ifnum#1<100\expandafter\gr@num@ii\number#1%
+ \else
+% \end{macrocode}
+% We use the available shorthands for 1.000 (|\@m|) and 10.000
+% (|\@M|) to save a few tokens.
+% \begin{macrocode}
+ \ifnum#1<\@m\expandafter\gr@num@iii\number#1%
+ \else
+ \ifnum#1<\@M\expandafter\gr@num@iv\number#1%
+ \else
+ \ifnum#1<100000\expandafter\gr@num@v\number#1%
+ \else
+ \ifnum#1<1000000\expandafter\gr@num@vi\number#1%
+ \else
+% \end{macrocode}
+% If the value is too large, nothing is printed and a warning
+% is issued.
+% \begin{macrocode}
+ \space\gr@ill@value{#1}%
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\Greeknumeral}
+% The command |\Greeknumeral| prints uppercase greek numerals.
+% The parsing is performed by the macro |\greeknumeral|.
+% \begin{macrocode}
+\def\Greeknumeral#1{%
+ \expandafter\MakeUppercase\expandafter{\greeknumeral{#1}}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\greek@alph}
+% \begin{macro}{\greek@Alph}
+% In the previous release of this language definition the
+% commands |\greek@aplh| and |\greek@Alph| were kept just for
+% reasons of compatibility. Here again they become meaningful macros.
+% They are definited in a way that even page numbering with greek
+% numerals is possible. Since the macros |\@alph| and |\@Alph| will
+% lose their original meaning while the Greek option is active, we
+% must save their original value.
+% macros |\@alph|
+% \begin{macrocode}
+\let\latin@alph\@alph
+\let\latin@Alph\@Alph
+% \end{macrocode}
+% Then we define the Greek versions; the additional |\expandafter|s
+% are needed in order to make sure the table of contents will be
+% correct, e.g., when we have appendixes.
+% \begin{macrocode}
+\def\greek@alph#1{\expandafter\greeknumeral\expandafter{\the#1}}
+\def\greek@Alph#1{\expandafter\Greeknumeral\expandafter{\the#1}}
+% \end{macrocode}
+%
+% Now we can set up the switching.
+% \changes{greek-1.1a}{1997/03/03}{removed two superfluous @'s which
+% made \cs{@alph} undefined}
+% \begin{macrocode}
+\addto\extrasgreek{%
+ \let\@alph\greek@alph
+ \let\@Alph\greek@Alph}
+\addto\noextrasgreek{%
+ \let\@alph\latin@alph
+ \let\@Alph\latin@Alph}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% What is left now is the definition of a set of macros to produce
+% the various digits.
+% \begin{macro}{\gr@num@i}
+% \begin{macro}{\gr@num@ii}
+% \begin{macro}{\gr@num@iii}
+% \changes{greek-1.2b}{1997/11/13}{No longer use \cs{\let} in the
+% expansion of the \cs{gr@num@x} macros as they ned to be
+% expandable}
+% As there is no representation for $0$ in this system the zeros
+% are simply discarded. When we have a large number with three
+% \emph{trailing} zero's also the numeric mark is discarded.
+% Therefore these macros need to pass the information to each other
+% about the (non-)translation of a zero.
+% \begin{macrocode}
+\def\gr@num@i#1{%
+ \ifcase#1\or \textalpha\or \textbeta\or \textgamma\or \textdelta\or
+ \textepsilon\or \textstigma\or \textzeta\or \texteta\or \texttheta\fi
+ \ifnum#1=\z@\else\anw@true\fi\anw@print}
+\def\gr@num@ii#1{%
+ \ifcase#1\or \textiota\or \textkappa\or \textlambda\or \textmu\or
+ \textnu\or \textxi\or \textomicron\or \textpi\or \textqoppa\fi
+ \ifnum#1=\z@\else\anw@true\fi\gr@num@i}
+\def\gr@num@iii#1{%
+ \ifcase#1\or \textrho\or \textsigma\or \texttau\or \textupsilon\or
+ \textphi\or \textchi\or \textpsi\or \textomega\or \textsampi\fi
+ \ifnum#1=\z@\anw@false\else\anw@true\fi\gr@num@ii}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\gr@num@iv}
+% \begin{macro}{\gr@num@v}
+% \begin{macro}{\gr@num@vi}
+% The first three `digits' always have the numeric mark, except
+% when one is discarded because it's value is zero.
+% \begin{macrocode}
+\def\gr@num@iv#1{%
+ \ifnum#1=\z@\else\textaristerikeraia\fi
+ \ifcase#1\or \textalpha\or \textbeta\or \textgamma\or \textdelta\or
+ \textepsilon\or \stigma\or \textzeta\or \texteta\or \texttheta\fi
+ \gr@num@iii}
+\def\gr@num@v#1{%
+ \ifnum#1=\z@\else\textaristerikeraia\fi
+ \ifcase#1\or \textiota\or \textkappa\or \textlambda\or \textmu\or
+ \textnu\or \textxi\or \textomicron\or \textpi\or \textqoppa\fi
+ \gr@num@iv}
+\def\gr@num@vi#1{%
+ \textaristerikeraia
+ \ifcase#1\or \textrho\or \textsigma\or \texttau\or \textupsilon\or
+ \textphi\or \textchi\or \textpsi\or \textomega\or \textsampi\fi
+ \gr@num@v}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \section{Character codes}
+%
+% Greek letters drop diacritics (eccept dialytika and sub-iota) in
+% UPPERCASE. This is not cared for by the Unicode standard.
+% The file \file{greek-euenc.def} from \pkg{greek-fontenc}
+% contains the required |\lccode| and |\uccode| corrections from the
+% \pkg{xgreek} package by Apostolos Syropoulos.
+% \changes{greek-1.5}{2013/06/21}{Support XeTeX/LuaTeX.}
+% \changes{greek-1.9d}{2015/07/06}{uclc fixes not included in greek-euenc.def}
+%
+% The LGR encoded fonts that are used to typeset Greek with 8-bit TeX
+% define ligatures for characters with diacritics. In order for this to
+% work, some characters need to be considered as letters. These
+% characters are |<|, |>|, |~|, |`|, |'|, |"| and
+% \verb=|=. Therefore, their |\lccode| is changed when Greek is in
+% effect. In order to let |\uppercase| give correct results, the
+% |\uccode| of these characters is set to a non-existing character
+% to make them disappear. Of course not all characters are needed
+% when typesetting ``modern'' $\mu o\nu o\tau o\nu
+% \iota\kappa\acute{o}$. In that case we only need the |'| and |"|
+% symbols which are treated in the proper way.
+%
+% \begin{macro}{\greek@tilde}
+% \changes{greek-1.0c}{1997/02/19}{Added command}
+% The Greek script uses a number of characters with more
+% than one accent. In LGR encoded fonts combined diacritics can be
+% obtained using Knuth's ligature mechanism (see usage.pdf).
+% Characters we need to have ligatures with are the tilde, the
+% acute and grave accent characters, the rough and smooth breathings,
+% the subscript, and the double quote character.
+% In text input the |~| is normally used to produce an
+% unbreakable space.
+% \changes{greek-1.3k}{2003/04/10}{Make sure the character `!' is not
+% active during the definition of \cs{greek@tilde}}
+% \changes{greek-1.4}{2013/05/17}{do not re-define the tilde accent macro:
+% it works as expected with \file{lgrenc.def} from \pkg{greek-fontenc}.}
+% \begin{macrocode}
+\@ifl@aded{def}{lgrenc}{%
+ \begingroup
+ \@ifundefined{active@char\string!}{}{\catcode`!=12\relax}
+ \catcode`\~=12%
+ \lccode`\!=`\~%
+ \lowercase{\def\x{\endgroup
+ \def\greek@tilde{!}}\x}
+% \end{macrocode}
+% \end{macro}
+% In order to get correct hyphenation we need to set the lower case
+% code of a number of characters. The `v' character has a special
+% usage for the |cb| fonts: in fact this ligature mechanism detects
+% the end of a word and assures that a final sigma is typeset with
+% the proper sign wich is different from that of an initial or
+% medial sigma; the `v 'after an \textit{isolated} sigma fools
+% the ligature mechanism in order to typeset $\sigma$ in place of
+% $\varsigma$. Because of this we make sure its lowercase code is
+% not changed. For ``modern'' greek we have to deal only with |'|
+% and |"| and so things are easy.
+% \changes{greek-1.1c}{1997/04/30}{fixed two typos}
+% \changes{greek-1.1e}{1997/10/12}{Added lowercase code for v}
+% \changes{greek-1.2}{1997/10/28}{Definitions for ``modern'' Greek are
+% now the definitions of ``Polutoniko'' Greek}
+% \changes{greek-1.2}{1997/10/28}{Added lowercase codes for ``modern''
+% greek}
+% \changes{greek-1.3e}{1999/09/24}{\cs{extrasgreek} and
+% \cs{extraspolutonikogreek} should be complementary}
+% \changes{babel-greek-1.9}{2014/07/20}{Added lc codes for chars 128 to 255}
+% In order to process the suitable characters and in such a way that
+% hyphenation patterns work also with precomposed characters, it is
+% necessary to declare the lc code for all characters, that can be part
+% of a word. We do this in |\extrasgreek| because this is a feature of
+% the LGR font encoding (which is the same in all language variants).
+% This means that multi-accented characters are regarded parts of a word
+% (and not non-word characters) also in monotonic spelling.
+% \changes{babel-greek-1.9e}{2015/11/27}{Fix bug in lccode-setting loop
+% (patch by Enrico Gregorio).}
+% \begin{macrocode}
+ \addto\extrasgreek{%
+ \babel@savevariable{\lccode`v}\lccode`v=`v%
+ \babel@savevariable{\lccode`\'}\lccode`\'=`\'%
+ \babel@savevariable{\lccode`\"}\lccode`\"=`\"%
+ % ``high bit characters'': set in a loop and correct exceptions
+ \@tempcnta=128%
+ \@whilenum\@tempcnta<253\do{%
+ \expandafter\babel@savevariable\expandafter{%
+ \expandafter\lccode\the\@tempcnta}%
+ \lccode\@tempcnta=\@tempcnta
+ \advance\@tempcnta\@ne
+ }%
+ % Fix non-word characters:
+ \lccode151=0%
+ \lccode155=0%
+ \lccode159=0%
+ \lccode199=0%
+ % Fix capital letters:
+ \lccode195=147% GREEK LETTER DIGAMMA
+ \lccode219=240% GREEK CAPITAL LETTER IOTA WITH DIALYTIKA
+ \lccode223=244% GREEK CAPITAL LETTER UPSILON WITH DIALYTIKA
+ }
+
+ \addto\extraspolutonikogreek{%
+ % \l@greek=\bbl@polygreek
+ \babel@savevariable{\lccode`\<}\lccode`\<=`\<%
+ \babel@savevariable{\lccode`\>}\lccode`\>=`\>%
+ \babel@savevariable{\lccode`\~}\lccode`\~=`\~%
+ \babel@savevariable{\lccode`\|}\lccode`\|=`\|%
+ \babel@savevariable{\lccode`\`}\lccode`\`=`\`%
+ }
+% \end{macrocode}
+% And in order to get rid of all accents and breathings when a
+% string is |\uppercase|d we also change a number of uppercase
+% codes.
+% \changes{greek-1.1b}{1997/03/06}{Added setting of \cs{uccode}s
+% (after \file{kdgreek.sty})}
+% \changes{greek-1.1e}{1997/10/12}{Added uppercase code for special
+% letter ``v''. Uppercase code for accents is now \texttt{9f},
+% instead of \texttt{ff}}
+% \changes{greek-1.2}{1997/10/28}{Added uppercase codes for ``modern''
+% Greek. The old codes are now for ``Polutoniko'' Greek}
+% \changes{greek-1.3e}{1999/09/24}{\cs{extrasgreek} and
+% \cs{extraspolutonikogreek} should be complementary}
+% {\catcode`|=12\relax\gdef\indexbar{\cs{|}}}
+% \changes{greek-1.3g}{1999/11/17}{uc code of \indexbar{} is now just
+% \indexbar{} to reflect recent changes in the cb fonts}
+% \changes{greek-1.3i}{2000/10/02}{uc code of `v' is switched to V
+% so that mixed text appears correctly in headers.}
+% \changes{greek-1.3j}{2001/02/03}{Because other languages might
+% make the caret active, we can't use the double caret notation
+% here}
+% \begin{macrocode}
+ \addto\extrasgreek{%
+ \babel@savevariable{\uccode`\"}\uccode`\"=`\"%
+ \babel@savevariable{\uccode`\'}\uccode`\'=159% 159 == ^^9f
+ }
+ \addto\extraspolutonikogreek{%
+ \babel@savevariable{\uccode`\~}\uccode`\~=159%
+ \babel@savevariable{\uccode`\>}\uccode`\>=159%
+ \babel@savevariable{\uccode`\<}\uccode`\<=159%
+ \babel@savevariable{\uccode`\|}\uccode`\|=`\|%
+ \babel@savevariable{\uccode`\`}\uccode`\`=159%
+ }
+% \end{macrocode}
+% For this to work we make the character |^^9f| a shorthand that
+% expands to nothing. In order for this to work we need to make a
+% character look like |^^9f| in \TeX's eyes. The trick is to have
+% another character and assign it a different lowercase code. The
+% execute the macros needed in a |\lowercase| environment. Usually
+% the tilde |~| character is used for such purposes. Before we do
+% this we save it's original lowercase code to restore it once
+% we're done.
+% \changes{greek-1.1b}{1997/03/06}{Added shorthand for \cs{char255}}
+% \changes{greek-1.1e}{1997/10/12}{Shorthand is changed. Active
+% character is now \cs{char159}}
+% \changes{greek-1.2a}{1997/10/31}{Need shorthand to exist for
+% ``monotoniko'' Greek, not ``polutoniko'' Greek}
+% \changes{greek-1.3j}{2001/02/03}{Use the tilde as an alias for
+% character 159}
+% \begin{macrocode}
+ \@tempcnta=\lccode`\~
+ \lccode`\~=159
+ \lowercase{%
+ \initiate@active@char{~}%
+ \declare@shorthand{greek}{~}{}}
+ \lccode`\~=\@tempcnta
+% \end{macrocode}
+% Add composite commands, so that the dialytika is kept or put on the
+% following character of a diphthong with |\MakeUppercase|
+% (see lgrdef.enc from the the greek-fontenc package for details).
+% \changes{greek-1.4}{2013/05/17}{Add TextCompositeCommands for
+% ``uppercase diacritics''.}
+% \changes{greek-1.5}{2013/05/27}{Bugfix: @hiatus->LGR@hiatus}
+% \changes{greek-1.5a}{2013/07/02}{Replaced non-printable literal character
+% with ^^-notation (thanks to Heiko Oberdiek for the hint).}
+% \changes{greek-1.9}{2014/07/20}{The |^^|-notation seems to require lower case
+% letters. |^^9F| failed.}
+% \begin{macrocode}
+ \DeclareTextCompositeCommand{\"}{LGR}{^^9f}{\accdialytika}
+ \DeclareTextCompositeCommand{\'}{LGR}{^^9f}{\LGR@hiatus}
+ \DeclareTextCompositeCommand{\`}{LGR}{^^9f}{\LGR@hiatus}
+% \end{macrocode}
+%
+% We can also make the tilde character itself expand to a tilde with
+% category code 12 to make the typing of texts easier.
+% \changes{greek-1.1b}{1997/03/06}{Made tilde expand to a tilde with
+% \cs{catcode 12}.}
+% \changes{greek-1.5a}{2013/06/27}{provide ``extraspolutonikogreek'' also
+% for Xe/LuaTeX.}
+% \begin{macrocode}
+ \addto\extraspolutonikogreek{\languageshorthands{greek}}%
+ \declare@shorthand{greek}{~}{\greek@tilde}
+}{} % End of LGR-specific code.
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \section{symbol name aliases}
+% For backwards compatibility, we keep aliases for a few symbols.
+% \changes{greek-1.1c}{1997/03/10}{Added a couple of symbols, needed
+% for \cs{greeknumeral}}
+% \changes{greek-1.1e}{1997/10/12}{Most symbols are removed and are
+% now defined in package grsymb}
+% \changes{greek-1.2c}{1998/06/26}{Package grsymb has been eliminated
+% because the CB fonts v2.0 do not inlcude certain symbols and so
+% the remaining symbol definitions have been moved here}
+% \changes{greek-1.5}{2013/06/11}{change symbol macros to aliases}
+% \begin{macrocode}
+\providecommand*{\anwtonos}{\textdexiakeraia}
+\providecommand*{\katwtonos}{\textaristerikeraia}
+\providecommand*{\qoppa}{\textqoppa}
+\providecommand*{\stigma}{\textstigma}
+\providecommand*{\sampi}{\textsampi}
+\providecommand*{\Digamma}{\textDigamma}
+\providecommand*{\ddigamma}{\textdigamma}
+\providecommand*{\vardigamma}{\textvardigamma}
+\providecommand*{\euro}{\texteuro}
+\providecommand*{\permill}{\textperthousand}
+% \end{macrocode}
+%
+% \changes{greek-1.3l}{2004/02/19}{Commented these lines out as this
+% change has made it into \LaTeX{} itself.}
+% \changes{greek-1.8}{2013/11/27}{Remove the redefintion of fnum@figure
+% and fnum@table.}
+%
+% The macro |\ldf@finish| takes care of looking for a
+% configuration file, setting the main language to be switched on
+% at |\begin{document}| and resetting the category code of
+% \texttt{@} to its original value.
+% \changes{greek-1.0b}{1996/11/02}{Now use \cs{ldf@finish} to wrap up}
+% \begin{macrocode}
+\ldf@finish{\CurrentOption}
+%</code>
+% \end{macrocode}
+%
+% \Finale
+%\endinput
+%% \CharacterTable
+%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%% Digits \0\1\2\3\4\5\6\7\8\9
+%% Exclamation \! Double quote \" Hash (number) \#
+%% Dollar \$ Percent \% Ampersand \&
+%% Acute accent \' Left paren \( Right paren \)
+%% Asterisk \* Plus \+ Comma \,
+%% Minus \- Point \. Solidus \/
+%% Colon \: Semicolon \; Less than \<
+%% Equals \= Greater than \> Question mark \?
+%% Commercial at \@ Left bracket \[ Backslash \\
+%% Right bracket \] Circumflex \^ Underscore \_
+%% Grave accent \` Left brace \{ Vertical bar \|
+%% Right brace \} Tilde \~}
+%%
diff --git a/macros/latex/contrib/babel-contrib/greek/babel-greek.ins b/macros/latex/contrib/babel-contrib/greek/babel-greek.ins
new file mode 100644
index 0000000000..15e136d3ad
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/babel-greek.ins
@@ -0,0 +1,105 @@
+%%
+%% This file will generate fast loadable files and documentation
+%% driver files from the doc files in this package when run through
+%% LaTeX or TeX.
+%%
+%% Copyright 1989-2008 Johannes L. Braams and any individual authors
+%% listed elsewhere in this file. All rights reserved.
+%%
+%% This file is part of the babel-greek package.
+%% ---------------------------------------------
+%%
+%% Babel-greek is a contributed package providing support for the Greek
+%% language and script via the Babel system (http://www.ctan.org/pkg/babel)
+%%
+%% It may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2003/12/01 or later.
+%%
+%% This work has the LPPL maintenance status "maintained".
+%%
+%% The Current Maintainer of this work is Günter Milde <milde@users.sf.net>.
+%%
+%% The list of derived (unpacked) files belonging to the package
+%% and covered by LPPL is defined by the unpacking script (babel-greek.ins)
+%% which is part of the distribution.
+%%
+%% --------------- start of docstrip commands ------------------
+%%
+\def\filedate{2015/07/06}
+\def\batchfile{babel-greek.ins}
+\input docstrip.tex
+
+{\ifx\generate\undefined
+\Msg{**********************************************}
+\Msg{*}
+\Msg{* This installation requires docstrip}
+\Msg{* version 2.3c or later.}
+\Msg{*}
+\Msg{* An older version of docstrip has been input}
+\Msg{*}
+\Msg{**********************************************}
+\errhelp{Move or rename old docstrip.tex.}
+\errmessage{Old docstrip in input path}
+\batchmode
+\csname @@end\endcsname
+\fi}
+
+\declarepreamble\mainpreamble
+This is a generated file.
+
+Copyright 1989-2008 Apostolos Syropoulos, Johannes L. Braams, Guenter Milde,
+and the authors listed elsewhere in this file. All rights reserved.
+
+This file was generated from file(s) of the babel-greek package.
+----------------------------------------------------------------
+
+It may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3
+of this license or (at your option) any later version.
+The latest version of this license is in
+ http://www.latex-project.org/lppl.txt
+and version 1.3 or later is part of all distributions of LaTeX
+version 2003/12/01 or later.
+
+This work has the LPPL maintenance status "maintained".
+
+The Current Maintainer of this work is Günter Milde <milde@users.sf.net>.
+
+Babel-greek is a contributed package providing support for the Greek
+language and script via the Babel system (http://www.ctan.org/pkg/babel).
+
+The list of derived (unpacked) files belonging to this work
+and covered by LPPL is defined by the unpacking script (babel-greek.ins)
+which is part of the package.
+\endpreamble
+
+
+\keepsilent
+
+\usedir{macros/latex/contrib/babel-contrib/greek}
+
+\usepreamble\mainpreamble
+\generate{\file{greek.ldf}{\from{babel-greek.dtx}{code}}
+ \file{athnum.sty}{\from{athnum.dtx}{package}}
+ \file{grmath.sty}{\from{grmath.dtx}{package}}
+ }
+
+\ifToplevel{
+\Msg{***********************************************************}
+\Msg{*}
+\Msg{* To finish the installation, please move `greek.ldf and all}
+\Msg{* files ending with `.sty' into a directory searched by TeX.}
+\Msg{*}
+\Msg{* To produce the documentation run the files ending with}
+\Msg{* '.dtx' through LaTeX.}
+\Msg{*}
+\Msg{* Happy TeXing}
+\Msg{***********************************************************}
+}
+
+\endinput
diff --git a/macros/latex/contrib/babel-contrib/greek/babel-greek.pdf b/macros/latex/contrib/babel-contrib/greek/babel-greek.pdf
new file mode 100644
index 0000000000..d877d86834
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/babel-greek.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/grmath.dtx b/macros/latex/contrib/babel-contrib/greek/grmath.dtx
new file mode 100644
index 0000000000..000daadcd8
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/grmath.dtx
@@ -0,0 +1,168 @@
+% \iffalse meta-comment
+%
+% Copyright 1989-2008 Johannes L. Braams and any individual authors
+% listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the Babel system.
+% --------------------------------------
+%
+% It may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2003/12/01 or later.
+%
+% This work has the LPPL maintenance status "maintained".
+%
+% The Current Maintainer of this work is Johannes Braams.
+%
+% The list of all files belonging to the Babel system is
+% given in the file `manifest.bbl. See also `legal.bbl' for additional
+% information.
+%
+% The list of derived (unpacked) files belonging to the distribution
+% and covered by LPPL is defined by the unpacking scripts (with
+% extension .ins) which are part of the distribution.
+% \fi
+%% \CheckSum{126}
+%
+%\iffalse
+%
+%% This is file `grmath.sty'
+%% (c) 1997-2005 Apostolos Syropoulos.
+%% All rights reserved.
+% You are allowed to modify this file as long the initial copyright notice
+% appears in the modified file.
+%
+% Please report errors or suggestions for improvement to
+%
+% Apostolos Syropoulos
+% 366, 28th October Str.
+% GR-671 00 Xanthi, GREECE
+%
+% apostolo at platon.ee.duth.gr or apostolo at obelix.ee.duth.gr
+%
+%\fi
+%\iffalse
+% \begin{macrocode}
+%<*driver>
+\documentclass{ltxdoc}
+\GetFileInfo{grmath.drv}
+\begin{document}
+ \DocInput{grmath.dtx}
+\end{document}
+%</driver>
+% \end{macrocode}
+%\fi
+%
+% \changes{grmath-1.2}{2001/02/12}{Package provides options ``grlog''
+% (default) and ``enlog'' that create Greek and Latin names
+% log functions}
+%
+% \title{Greek log-like Operators}
+% \author{Apostolos Syropoulos\\
+% 366, 28th October Str.\\
+% GR-671 00 Xanthi, HELLAS\\
+% E-mail: \texttt{apostolo@platon.ee.duth.gr}}
+% \date{2001/02/12}
+% \maketitle
+%
+% \MakeShortVerb{|}
+% \section{What is this all about?}
+%
+% In Greece, until recently, it was common practice to write down most
+% log-like functions as abbreviations of their Greek names. Consequently,
+% high school students and even university freshmen were not familiar with
+% the Latin names employed in international literature. However, this practice
+% is fading away in universities but it is still in wide use in books for
+% high schools, mainly because the Latin names would produce nothing but
+% confusion. The package |grmath| redefines most log-like definitions
+% so that they produce the Greek name, instead of the Latin one. The package
+% can be used only in conjunction with the |greek| option of the |babel|
+% package. The new option |enlog| allows one to keep the Latin names for
+% the log functions.
+% \StopEventually
+%
+% \section{The Implementation}
+%
+% As usual we must first identify ourselves.
+%
+% \begin{macrocode}
+%<*package>
+\ProvidesPackage{grmath}[2001/02/12\space v1.2]
+\typeout{Package: `grmath' v1.2\space <2001/02/12> (A. Syropoulos)}
+% \end{macrocode}
+%
+% The next thing we do is to process the options. The default option
+% ``grlog'' generates Greek names for log functions and the ``enlog''
+% option generates Latin names for log functions.
+% \begin{macrocode}
+\DeclareOption{grlog}{%
+ \def\log{\mathop{\mathgroup\symgroperators log_{10}}\nolimits}
+ \def\ln{\mathop{\mathgroup\symgroperators log_%
+ {\mathgroup\symoperators e}}\nolimits}
+}
+\DeclareOption{enlog}{%
+ \def\log{\mathop{\operator@font log}\nolimits}
+ \def\ln{\mathop{\operator@font ln}\nolimits}
+}
+\ExecuteOptions{grlog}
+\ProcessOptions
+% \end{macrocode}
+%
+% Now we check to see if the |babel| package is loaded with at least
+% the |greek| option. In case it isn't, we opt to produce an error message.
+% \begin{macrocode}
+\@ifpackagewith{babel}{greek}{}{%
+ \@ifpackagewith{babel}{polutonikogreek}{}{%
+ \PackageError{grmath}{%
+ `greek' option of the `babel'\MessageBreak
+ package hasn't been loaded}{%
+ The commands provided by this package\MessageBreak
+ are specially designed for greek language\MessageBreak
+ typesetting with the `babel' package. Load\MessageBreak
+ it with at least the `greek' option.}\relax
+ }}
+% \end{macrocode}
+%
+% We define the mathematical font which will be used to typeset
+% the log-like functions.
+% \begin{macrocode}
+\DeclareSymbolFont{groperators}{LGR}{cmr}{m}{n}
+\SetSymbolFont{groperators}{bold}{LGR}{cmr}{bx}{n}
+% \end{macrocode}
+%
+% We are now ready to proceed with the redefinitions of the log-like
+% operator names.
+% \begin{macrocode}
+\def\sin{\mathop{\mathgroup\symgroperators hm}\nolimits}
+\def\cos{\mathop{\mathgroup\symgroperators sun}\nolimits}
+\def\tan{\mathop{\mathgroup\symgroperators ef}\nolimits}
+\def\arcsin{\mathop{\mathgroup\symgroperators toxhm}\nolimits}
+\def\arccos{\mathop{\mathgroup\symgroperators toxsun}\nolimits}
+\def\arctan{\mathop{\mathgroup\symgroperators toxef}\nolimits}
+\def\cot{\mathop{\mathgroup\symgroperators sf}\nolimits}
+\def\sec{\mathop{\mathgroup\symgroperators tem}\nolimits}
+\def\csc{\mathop{\mathgroup\symgroperators stem}\nolimits}
+\def\gcd{\mathop{\mathgroup\symgroperators MKD}\nolimits}
+% \end{macrocode}
+% In the standard \LaTeX\ distribution there is no provision for a
+% Least Common Multiple (lcm) log-like operator. Since, this operator
+% appears quite often in greek literature we opt to include it. Moreover,
+% we include three more log-like functions: |\arccot|, |\arcsec| and
+% |\arccsc|.
+% \begin{macrocode}
+\def\lcm{\mathop{\mathgroup\symgroperators EKP}\nolimits}
+\def\arccot{\mathop{\mathgroup\symgroperators toxsf}\nolimits}
+\def\arcsec{\mathop{\mathgroup\symgroperators toxtem}\nolimits}
+\def\arccsc{\mathop{\mathgroup\symgroperators toxstem}\nolimits}
+%</package>
+% \end{macrocode}
+%
+% \section*{Dedication}
+% I would like to dedicate this piece of work to my son
+% \begin{center}Demetrios-Georgios.\end{center}
+% \Finale
+\endinput
diff --git a/macros/latex/contrib/babel-contrib/greek/grmath.pdf b/macros/latex/contrib/babel-contrib/greek/grmath.pdf
new file mode 100644
index 0000000000..b97893d195
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/grmath.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/test-greek.pdf b/macros/latex/contrib/babel-contrib/greek/test-greek.pdf
new file mode 100644
index 0000000000..ac09a44166
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-greek.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/test-greek.tex b/macros/latex/contrib/babel-contrib/greek/test-greek.tex
new file mode 100644
index 0000000000..5498dfc96b
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-greek.tex
@@ -0,0 +1,428 @@
+\documentclass[a4paper]{article}
+\usepackage[LGR,T1]{fontenc}
+
+% Xe/LuaTeX in 8-bit compatibility mode:
+% hyphenation in Greek text parts fails!
+% (would require the 8-bit, LGR-encoded patterns in the XeTeX ini and a
+% loader fix for luatex).
+
+% TODO: why does XeTeXinputencoding "bytes" no longer work with inputenc's
+% utf8 option?
+\ifdefined \XeTeXrevision
+ \XeTeXinputencoding "bytes"
+\fi
+
+\ifdefined\luatexversion
+ \usepackage[utf8]{luainputenc}
+\else
+ \usepackage[utf8]{inputenc}
+\fi
+% \usepackage{textalpha}
+\usepackage{textcomp}
+\usepackage{hyperref,bookmark}
+\usepackage{parskip}
+\usepackage{booktabs}
+
+\usepackage{lmodern}
+% \usepackage{kerkis}
+% \usepackage{gfsdidot}
+
+% Load the Babel package with Greek and English language definitions:
+%
+% Uncomment the desired language variant
+
+% Default: modern monotonic Greek
+\usepackage[greek,english]{babel}
+% Obsolete: used instead of `greek', kept for backwards compatibility:
+% \usepackage[polutonikogreek,english]{babel}
+
+% For backwards compatibility, you can also use
+% \selectlanguage{polutonikogreek} instead of \selectlanguage{greek} etc.
+% if the (modern) polytonic Greek language variant is selected.
+
+% uncomment for modern polytonic Greek
+% \languageattribute{greek}{polutoniko}
+
+% uncomment for ancient Greek
+\languageattribute{greek}{ancient}
+
+% \message{Latin encoding is \latinencoding}
+
+\DeclareTextCommandDefault{\ensuregreek}{\textgreek}
+
+\begin{document}
+
+\title{Test the Greek support for Babel}
+\author{Günter Milde}
+\date{2014/09/02}
+\maketitle
+
+The babel option ``greek'' activates the support for the Greek language
+defined in the file \texttt{greek.ldf} (source \texttt{greek.dtx}).
+
+\section{Language Switch}
+
+The declaration \verb|\selectlanguage| switches between languages.
+
+\begin{quote}
+ \selectlanguage{greek}
+ Τί φήις; Ἱδὼν ἐνθέδε παῖδ’ ἐλευθέραν
+ τὰς πλησίον Νύμφας στεφανοῦσαν, Σώστρατε,
+ ἐρῶν άπῆλθες εὐθύς;
+\end{quote}
+
+The macro \verb|\foreignlanguage| sets its second argument in the specified
+language. This is intended for short text parts or single words like
+\foreignlanguage{greek}{Βιβλιοθήκη}.
+
+There should be no inserted space before or after the language switch (may
+happen if there are unescaped linebreaks in the font or language definitions):
+
+\begin{quote}
+ Change script with \verb|ensuregreek|: |\ensuregreek{do\~ulos}|. Change
+ language with \verb|\foreignlanguage|: |\foreignlanguage{greek}{do\~ulos}|.
+\end{quote}
+
+\section{Font Encoding}
+
+In Greek text parts, the font encoding is automatically set to LGR if an
+8-bit TeX engine is used. (See \url{test-unicode-greek.tex} for usage of
+babel-greek with XeTeX or LuaTeX.)
+
+LGR has Greek characters in the slots reserved in a TeX \emph{standard text
+font encoding}. This means you need an explicit font encoding change for
+every Latin letter and some other symbols if the current font encoding is
+LGR.
+
+The Babel core defines the declaration \verb|\latintext| and the command
+\verb|\textlatin| to switch to the T1 or OT1 font encoding or typeset the
+argument using this encoding.
+
+Switching to a font encoding supporting the Greek script is possible without
+switching the Babel language using the declarations \verb|\greekscript| (no
+switch if the current encoding supports Greek script (e.g. the Unicode font
+encodings EU1, EU2)) or \verb|\greektext| (always switch to LGR) and the
+corresponding macros \verb|\ensuregreek| or \verb|\textgreek|. These
+commands do not start a new paragraph:
+
+\greekscript Φίλων τοῦ \textlatin{TeX} (ΕΦΤ) --
+\latintext Friends (\ensuregreek{F\'ilwn}) of TeX.
+
+\texttt{greek.ldf} has some workarounds, so that macros relying on Latin
+characters in the ``right'' positions keep working. We test, that these
+definitions do not overwrite the selection of pre-composed characters for
+``copyright'' and ``registered trade mark'' by ``textcomp'' (try copy and
+paste from the PDF output):
+
+Greek (LGR): \ensuregreek{Α \& Ω, \textcopyright{} \textregistered{}
+\texttrademark{}, © ® ™ } \\
+Latin: A \& O.
+
+To prevent Roman numerals being typeset in Greek letters we need to adopt
+the internal LaTeX commands. Note that this may cause errors when roman
+numerals are used in a situation where the macros need to be expanded:
+
+\makeatletter
+Greek: \ensuregreek{
+\@roman{1}, \@roman{2}, \@roman{3}, \@roman{4}, \ldots, \@roman{1975}
+\@Roman{1}, \@Roman{2}, \@Roman{3}, \@Roman{4}, \ldots, \@Roman{1975}
+}
+
+Latin:
+\@roman{1}, \@roman{2}, \@roman{3}, \@roman{4}, \ldots, \@roman{1975}
+\@Roman{1}, \@Roman{2}, \@Roman{3}, \@Roman{4}, \ldots, \@Roman{1975}
+\makeatother
+
+\section{MakeUppercase, MakeLowercase}
+
+Capital Greek letters have diacritics (except the dialytika and sub-iota) to
+the left (instead of above) and drop them in uppercase, e.g.
+\ensuregreek{μαΐστρος $\mapsto$ \MakeUppercase{μαΐστρος}}.
+
+Upcased letters with diacritics keep the dialytika. This is implemented for
+all input variants of diacritics with dialytika. (\texttt{greek.ldf} has
+\emph{composite command} definitions to ensure this also works for accent
+characters "upcased" to the charcter No 159.)
+
+\foreignlanguage{greek}{\"i \"'i \"`i \"~i \'"i \`"i \~"i
+ \"u \"\'u \"\`u \"\~u
+ ϊ ΐ ῒ ῗ ΐ ῒ ῗ ϋ ΰ ῢ ῧ
+ $\mapsto$ \MakeUppercase{\"i \"'i \"`i \"~i \'"i \`"i \~"i
+ \"u \"\'u \"\`u \"\~u
+ ϊ ΐ ῒ ῗ ΐ ῒ ῗ ϋ ΰ ῢ ῧ
+ }
+}
+
+
+Tonos and dasia mark a \emph{hiatus} (break-up of a diphtong) if
+placed on the first vowel of a diphtong
+(\ensuregreek{\'ai, \'au, \'ei, \'>ai, \'>au, \'>ei}).
+A dialytika must be placed on the second vowel if they are dropped:
+(\ensuregreek{\MakeUppercase{\'ai, \'au, \'ei, \'>ai, \'>au, \'>ei}}).
+
+\selectlanguage{greek}
+% from teubner: άυλος/ΑΫΛΟΣ
+\'aulos $\mapsto$ \MakeUppercase{\'aulos},
+\'>aulos $\mapsto$ \MakeUppercase{\'>aulos},
+% from http://diacritics.typo.cz/index.php?id=69 μάινα -> ΜΑΪΝΑ
+m\'aina $\mapsto$ \MakeUppercase{m\'aina},
+% from http://de.wikipedia.org/wiki/Neugriechische_Orthographie#Das_Trema
+% κέικ, ἀυπνία/αϋπνία
+k\'eik, $\mapsto$ \MakeUppercase{k\'eik}
+\accpsili{a}upn\'ia $\mapsto$ \MakeUppercase{\accpsili{a}upn\'ia}
+\selectlanguage{english}
+
+There are several alternative styles for the capitalized sub-iota.
+
+In order to let the Up/Downcasing work also with the Latin transcription
+defined by the LGR font encoding, ``babel-greek'' also defines lc/uccodes
+for non-standard assignments:
+
+\selectlanguage{greek}
+', ", `, >, <, | $\mapsto$ \MakeUppercase{', ", `, >, <, |}
+\selectlanguage{english}
+
+The uppercase of the zero-width space at the place of ``v'' is kept to point
+to the glyph at the position of ``V'', the Dasia-Oxia accent
+(\ensuregreek{\MakeUppercase{v}}):
+
+\begin{quotation}
+ greek-1.3i 2000/10/02: uc code of `v' is switched to V
+ so that mixed text appears correctly in headers.
+\end{quotation}
+
+Use \verb+\textcompwordmark+:
+not \foreignlanguage{greek}{avu $\mapsto$ \MakeUppercase{avu}} but
+\foreignlanguage{greek}{a\textcompwordmark u
+$\mapsto$ \MakeUppercase{a\textcompwordmark u}}
+
+The following subsections test MakeUppercase and MakeLowercase with all
+characters defined in lgrenc.dfu:
+
+\subsection{Greek and Coptic}
+
+\newcommand{\GreekAndCoptic}{\ensuregreek{
+ʹ͵ͺ; ΄ ΅Ά·ΈΉΊΌΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΪΫϘϚϜϠ}}
+\newcommand{\greekandcoptic}{\ensuregreek{
+άέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώϙϛϝϟϡ}}
+
+Characters of the Greek and Coptic Unicode Block:
+
+\begin{quote}
+ \GreekAndCoptic\\
+ \greekandcoptic
+\end{quote}
+
+MakeUppercase:
+
+\begin{quote}
+ \MakeUppercase{\GreekAndCoptic}\\
+ \MakeUppercase{\greekandcoptic}
+\end{quote}
+
+Letters and sub-iota upcased, other diacritics except dialytika dropped.
+
+There is no capital Koppa in LGR, therefore \ensuregreek{ϟ} is left
+unchanged with MakeUppercase.
+
+
+MakeLowercase:
+
+\begin{quote}
+ \MakeLowercase{\GreekAndCoptic}\\
+ \MakeLowercase{\greekandcoptic}
+\end{quote}
+
+The lowercase of \ensuregreek{Σ} is the «auto-sigma» (\verb+\textautosigma+):
+\ensuregreek{ΣΣ $\mapsto$ \MakeLowercase{ΣΣ}}. Add a ZWNJ or use the
+\verb+\noboundary+ macro to prevent conversion to final sigma:
+\ensuregreek{\MakeLowercase{ΣΣ‌}}. The lowercase of GREEK LETTER STIGMA
+\ensuregreek{Ϛ} is \ensuregreek{\MakeLowercase{Ϛ}} not \verb|\textvarstigma|
+(\ensuregreek\textvarstigma).
+
+% \newpage
+
+\subsection{Greek extended}
+
+Characters of the Greek extended Unicode block:
+
+\selectlanguage{greek}
+ἀ ἁ ἂ ἃ ἄ ἅ ἆ ἇ Ἀ Ἁ Ἂ Ἃ Ἄ Ἅ Ἆ Ἇ \\
+ἐ ἑ ἒ ἓ ἔ ἕ Ἐ Ἑ Ἒ Ἓ Ἔ Ἕ \\
+ἠ ἡ ἢ ἣ ἤ ἥ ἦ ἧ Ἠ Ἡ Ἢ Ἣ Ἤ Ἥ Ἦ Ἧ \\
+ἰ ἱ ἲ ἳ ἴ ἵ ἶ ἷ Ἰ Ἱ Ἲ Ἳ Ἴ Ἵ Ἶ Ἷ \\
+ὀ ὁ ὂ ὃ ὄ ὅ Ὀ Ὁ Ὂ Ὃ Ὄ Ὅ \\
+ὐ ὑ ὒ ὓ ὔ ὕ ὖ ὗ Ὑ Ὓ Ὕ Ὗ \\
+ὠ ὡ ὢ ὣ ὤ ὥ ὦ ὧ Ὠ Ὡ Ὢ Ὣ Ὤ Ὥ Ὦ Ὧ \\
+ὰ ά ὲ έ ὴ ή ὶ ί ὸ ό ὺ ύ ὼ ώ \\
+ᾀ ᾁ ᾂ ᾃ ᾄ ᾅ ᾆ ᾇ ᾈ ᾉ ᾊ ᾋ ᾌ ᾍ ᾎ ᾏ \\
+ᾐ ᾑ ᾒ ᾓ ᾔ ᾕ ᾖ ᾗ ᾘ ᾙ ᾚ ᾛ ᾜ ᾝ ᾞ ᾟ \\
+ᾠ ᾡ ᾢ ᾣ ᾤ ᾥ ᾦ ᾧ ᾨ ᾩ ᾪ ᾫ ᾬ ᾭ ᾮ ᾯ \\
+ᾰ ᾱ ᾲ ᾳ ᾴ ᾶ ᾷ Ᾰ Ᾱ Ὰ Ά ᾼ ᾽ ι ᾿ \\
+῀ ῁ ῂ ῃ ῄ ῆ ῇ Ὲ Έ Ὴ Ή ῌ ῍ ῎ ῏ \\
+ῐ ῑ ῒ ΐ ῖ ῗ Ῐ Ῑ Ὶ Ί ῝ ῞ ῟ \\
+ῠ ῡ ῢ ΰ ῤ ῥ ῦ ῧ Ῠ Ῡ Ὺ Ύ Ῥ ῭ ΅ ` \\
+ ῲ ῳ ῴ ῶ ῷ Ὸ Ό Ὼ Ώ ῼ ´ ῾
+\selectlanguage{english}
+
+MakeUppercase:
+
+\selectlanguage{greek}
+
+\MakeUppercase{ ἀ ἁ ἂ ἃ ἄ ἅ ἆ ἇ Ἀ Ἁ Ἂ Ἃ Ἄ Ἅ Ἆ Ἇ }\\
+\MakeUppercase{ ἐ ἑ ἒ ἓ ἔ ἕ Ἐ Ἑ Ἒ Ἓ Ἔ Ἕ }\\
+\MakeUppercase{ ἠ ἡ ἢ ἣ ἤ ἥ ἦ ἧ Ἠ Ἡ Ἢ Ἣ Ἤ Ἥ Ἦ Ἧ }\\
+\MakeUppercase{ ἰ ἱ ἲ ἳ ἴ ἵ ἶ ἷ Ἰ Ἱ Ἲ Ἳ Ἴ Ἵ Ἶ Ἷ }\\
+\MakeUppercase{ ὀ ὁ ὂ ὃ ὄ ὅ Ὀ Ὁ Ὂ Ὃ Ὄ Ὅ }\\
+\MakeUppercase{ ὐ ὑ ὒ ὓ ὔ ὕ ὖ ὗ Ὑ Ὓ Ὕ Ὗ }\\
+\MakeUppercase{ ὠ ὡ ὢ ὣ ὤ ὥ ὦ ὧ Ὠ Ὡ Ὢ Ὣ Ὤ Ὥ Ὦ Ὧ }\\
+\MakeUppercase{ ὰ ά ὲ έ ὴ ή ὶ ί ὸ ό ὺ ύ ὼ ώ }\\
+\MakeUppercase{ ᾀ ᾁ ᾂ ᾃ ᾄ ᾅ ᾆ ᾇ ᾈ ᾉ ᾊ ᾋ ᾌ ᾍ ᾎ ᾏ }\\
+\MakeUppercase{ ᾐ ᾑ ᾒ ᾓ ᾔ ᾕ ᾖ ᾗ ᾘ ᾙ ᾚ ᾛ ᾜ ᾝ ᾞ ᾟ }\\
+\MakeUppercase{ ᾠ ᾡ ᾢ ᾣ ᾤ ᾥ ᾦ ᾧ ᾨ ᾩ ᾪ ᾫ ᾬ ᾭ ᾮ ᾯ }\\
+\MakeUppercase{ ᾰ ᾱ ᾲ ᾳ ᾴ ᾶ ᾷ Ᾰ Ᾱ Ὰ Ά ᾼ ᾽ ι ᾿ }\\
+\MakeUppercase{ ῀ ῁ ῂ ῃ ῄ ῆ ῇ Ὲ Έ Ὴ Ή ῌ ῍ ῎ ῏ }\\
+\MakeUppercase{ ῐ ῑ ῒ ΐ ῖ ῗ Ῐ Ῑ Ὶ Ί ῝ ῞ ῟ }\\
+\MakeUppercase{ ῠ ῡ ῢ ΰ ῤ ῥ ῦ ῧ Ῠ Ῡ Ὺ Ύ Ῥ ῭ ΅ ` }\\
+\MakeUppercase{ ῲ ῳ ῴ ῶ ῷ Ὸ Ό Ὼ Ώ ῼ ´ ῾ }
+\selectlanguage{english}
+
+MakeLowercase:
+
+\selectlanguage{greek}
+\MakeLowercase{ ἀ ἁ ἂ ἃ ἄ ἅ ἆ ἇ Ἀ Ἁ Ἂ Ἃ Ἄ Ἅ Ἆ Ἇ }\\
+\MakeLowercase{ ἐ ἑ ἒ ἓ ἔ ἕ Ἐ Ἑ Ἒ Ἓ Ἔ Ἕ }\\
+\MakeLowercase{ ἠ ἡ ἢ ἣ ἤ ἥ ἦ ἧ Ἠ Ἡ Ἢ Ἣ Ἤ Ἥ Ἦ Ἧ }\\
+\MakeLowercase{ ἰ ἱ ἲ ἳ ἴ ἵ ἶ ἷ Ἰ Ἱ Ἲ Ἳ Ἴ Ἵ Ἶ Ἷ }\\
+\MakeLowercase{ ὀ ὁ ὂ ὃ ὄ ὅ Ὀ Ὁ Ὂ Ὃ Ὄ Ὅ }\\
+\MakeLowercase{ ὐ ὑ ὒ ὓ ὔ ὕ ὖ ὗ Ὑ Ὓ Ὕ Ὗ }\\
+\MakeLowercase{ ὠ ὡ ὢ ὣ ὤ ὥ ὦ ὧ Ὠ Ὡ Ὢ Ὣ Ὤ Ὥ Ὦ Ὧ }\\
+\MakeLowercase{ ὰ ά ὲ έ ὴ ή ὶ ί ὸ ό ὺ ύ ὼ ώ }\\
+\MakeLowercase{ ᾀ ᾁ ᾂ ᾃ ᾄ ᾅ ᾆ ᾇ ᾈ ᾉ ᾊ ᾋ ᾌ ᾍ ᾎ ᾏ }\\
+\MakeLowercase{ ᾐ ᾑ ᾒ ᾓ ᾔ ᾕ ᾖ ᾗ ᾘ ᾙ ᾚ ᾛ ᾜ ᾝ ᾞ ᾟ }\\
+\MakeLowercase{ ᾠ ᾡ ᾢ ᾣ ᾤ ᾥ ᾦ ᾧ ᾨ ᾩ ᾪ ᾫ ᾬ ᾭ ᾮ ᾯ }\\
+\MakeLowercase{ ᾰ ᾱ ᾲ ᾳ ᾴ ᾶ ᾷ Ᾰ Ᾱ Ὰ Ά ᾼ ᾽ ι ᾿ }\\
+\MakeLowercase{ ῀ ῁ ῂ ῃ ῄ ῆ ῇ Ὲ Έ Ὴ Ή ῌ ῍ ῎ ῏ }\\
+\MakeLowercase{ ῐ ῑ ῒ ΐ ῖ ῗ Ῐ Ῑ Ὶ Ί ῝ ῞ ῟ }\\
+\MakeLowercase{ ῠ ῡ ῢ ΰ ῤ ῥ ῦ ῧ Ῠ Ῡ Ὺ Ύ Ῥ ῭ ΅ ` }\\
+\MakeLowercase{ ῲ ῳ ῴ ῶ ῷ Ὸ Ό Ὼ Ώ ῼ ´ ῾ }
+\selectlanguage{english}
+
+\section{Babel Strings}
+
+Babel defines macros for several autogenerated strings so that they may
+appear in the choosen language. babel-greek uses LICRs in order to let the
+string macros work independent of the font encoding, in both 8-bit and
+Unicode-aware TeX.
+
+\subsection{Captions}
+
+\selectlanguage{greek}
+\prefacename,
+\refname,
+\abstractname,
+\bibname,
+\chaptername,
+\appendixname,
+\contentsname,
+\listfigurename ,
+\listtablename,
+\indexname,
+\figurename,
+\tablename,
+\partname,
+\enclname,
+\ccname,
+\headtoname,
+\pagename,
+\seename,
+\alsoname,
+\proofname,
+\glossaryname,
+\selectlanguage{english}
+
+
+\subsection{Months}
+
+\selectlanguage{greek}
+\newcounter{foo}
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\selectlanguage{english}
+
+\section{Greek Numerals}
+
+See greek.pdf for the formation rules of Greek numerals.
+Some examples:
+
+\selectlanguage{greek}
+
+\greeknumeral{1},
+\greeknumeral{2},
+\greeknumeral{3},
+\greeknumeral{4},
+\greeknumeral{5},
+\greeknumeral{6},
+\greeknumeral{7},
+\greeknumeral{8},
+\greeknumeral{9},
+\greeknumeral{10},
+\greeknumeral{11},
+\greeknumeral{12},
+\greeknumeral{20},
+\greeknumeral{345},
+\greeknumeral{500},
+\greeknumeral{1997},
+\greeknumeral{2013},
+
+\Greeknumeral{1},
+\Greeknumeral{2},
+\Greeknumeral{3},
+\Greeknumeral{4},
+\Greeknumeral{5},
+\Greeknumeral{6},
+\Greeknumeral{7},
+\Greeknumeral{8},
+\Greeknumeral{9},
+\Greeknumeral{10},
+\Greeknumeral{11},
+\Greeknumeral{12},
+\Greeknumeral{20},
+\Greeknumeral{345},
+\Greeknumeral{500},
+\Greeknumeral{1997},
+\Greeknumeral{2013},
+
+\selectlanguage{english}
+
+Enumerated lists use Greek numerals in the second and fourth level:
+
+\selectlanguage{greek}
+\begin{enumerate}
+ \item \textlatin{Item} 1
+ \begin{enumerate}
+ \item \textlatin{Item} 1.1
+ \begin{enumerate}
+ \item \textlatin{Item} 1.1.1
+ \begin{enumerate}
+ \item \textlatin{Item} 1.1.1.1
+ \item \textlatin{Item} 1.1.1.2
+ \end{enumerate}
+ \item \textlatin{Item} 1.1.2
+ \end{enumerate}
+ \end{enumerate}
+\end{enumerate}
+\selectlanguage{english}
+
+
+\end{document}
diff --git a/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.pdf b/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.pdf
new file mode 100644
index 0000000000..b243fcc3ed
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.tex b/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.tex
new file mode 100644
index 0000000000..b794be139b
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-unicode-greek.tex
@@ -0,0 +1,258 @@
+\documentclass[a4paper]{article}
+% \usepackage{textcomp}
+\usepackage[colorlinks=true,linkcolor=blue]{hyperref}
+\usepackage{bookmark}
+\usepackage{parskip}
+
+\usepackage[tuenc]{fontspec}
+\setmainfont{Linux Libertine O}
+\setsansfont{Linux Biolinum O}
+% \setmainfont{DejaVu Serif}
+% \setmainfont{Droid Serif} % only monotonic Greek (subset of Greek and Coptic)
+
+\usepackage[greek,english]{babel}
+% \languageattribute{greek}{polutoniko}
+\languageattribute{greek}{ancient}
+
+\message{greek-euenc ist}
+\makeatletter
+\@ifl@aded{def}{greek-fontenc}{\message{geladen}}{\message{nicht geladen}}
+\makeatother
+
+
+\begin{document}
+
+\title{Greek support for Babel with XeTeX/LuaTeX}
+\author{Günter Milde}
+\date{2016/09/07}
+\maketitle
+
+The babel option «greek» activates the support for the Greek language
+defined in the file «greek.ldf» (source «greek.dtx»).
+
+Typesetting Greek texts requires a font containing Greek letters. With the
+XeTeX or LuaTeX engines, the user must ensure that the selected font
+contains the required glyphs (the default Latin Modern fonts miss them).
+Examples for suitable fonts are the «Deja Vu», «Linux Libertine», or
+«Free Serif» OpenType fonts.
+
+\section{Language Switch}
+
+The declaration \verb|\selectlanguage| switches between languages.
+
+\begin{quote}
+ \selectlanguage{greek}
+ Τί φήις; Ἱδὼν ἐνθέδε παῖδ’ ἐλευθέραν
+ τὰς πλησίον Νύμφας στεφανοῦσαν, Σώστρατε,
+ ἐρῶν άπῆλθες εὐθύς;
+\end{quote}
+
+The command \verb|\foreignlanguage| sets its second argument in the language
+specified as first argument. This is intended for short text parts like
+\foreignlanguage{greek}{Βιβλιοθήκη}.
+
+\section{Font Encoding}
+
+Every language switch to \texttt{greek} calls the \verb|\extrasgreek|
+command which in turn calls \verb|\greekscript| to ensure a Greek-supporting
+font encoding (LGR, TU, EU1, or EU2). Under XeTeX/LuaTeX the font encoding
+normally just remains Unicode (TU, EU1, or EU2). For customization, you can
+add to or redefine the \verb|\extrasgreek| command.
+
+The LGR font encoding does not support Latin characters. Therefore, the
+Babel core defines the declaration \verb|\latintext| and the command
+\verb|\textlatin| to switch to the TU, EU1, EU2, T1 or OT1 font encoding or
+typeset the argument using this encoding. At this point, the «latinencoding»
+is \latinencoding.
+
+Every language switch from \texttt{greek} calls the \verb|\noextrasgreek|
+command which in turn calls \verb|\latintext|.\\
+For customization, you can
+add to or redefine the \verb|\noextrasgreek| command.
+
+With the Unicode font encodings TU, EU1 (XeTeX), or EU2 (LuaTeX),
+Latin characters can be used in Greek text parts and
+input via the «LGR Latin transcription» is not possible.%
+\footnote{%
+ The \emph{xunicode} package provides with the \texttt{tipa} emulation an
+ example how this could be achieved also for Unicode fonts. Alternatively,
+ LGR encoded fonts can be used (see test-unicode-lgr.tex).
+}
+
+\begin{quote}
+ \greekscript Φίλων τοῦ \textlatin{TeX} (ΕΦΤ) --
+ \latintext Friends (\ensuregreek{F\'ilwn}) of TeX.%
+ \footnote{Compare the printout to the similar example in test-greek.pdf.}
+\end{quote}
+
+\section{LICR Macros}
+
+Babel defines macros for several autogenerated strings so that they may
+appear in the choosen language. \emph{babel-greek} uses LICR macros in
+order to let the string macros work independent of the font encoding.
+
+If \emph{fontspec} is loaded, \emph{babel-greek} loads Greek LICR
+definitions for the Unicode font encoding (TU, EU1 or EU2) from the file
+\texttt{greek-euenc.def} provided with
+\href{http://www.ctan.org/pkg/greek-fontenc}{greek-fontenc} since
+version~0.10.
+
+With this setup, it is also possible to use accent macros instead of
+pre-composed Unicode characters for letters with diacritics:
+«Τ\'ι φ\'ηις;», «\`<ορα = \accdasiavaria{ο}ρα».
+
+
+\subsection{Captions}
+
+\selectlanguage{greek}
+\prefacename,
+\refname,
+\abstractname,
+\bibname,
+\chaptername,
+\appendixname,
+\contentsname,
+\listfigurename ,
+\listtablename,
+\indexname,
+\figurename,
+\tablename,
+\partname,
+\enclname,
+\ccname,
+\headtoname,
+\pagename,
+\seename,
+\alsoname,
+\proofname,
+\glossaryname
+\selectlanguage{english}
+
+Test correct upcasing (dropping of accents):
+
+\selectlanguage{greek}
+\MakeUppercase{
+\prefacename,
+\refname,
+\abstractname,
+\bibname,
+\chaptername,
+\appendixname,
+\contentsname,
+\listfigurename,
+\listtablename,
+\indexname,
+\figurename,
+\tablename,
+\partname,
+\enclname,
+\ccname,
+\headtoname,
+\pagename,
+\seename,
+\alsoname,
+\proofname,
+\glossaryname
+}
+\selectlanguage{english}
+
+
+\subsection{Months}
+
+\selectlanguage{greek}
+\newcounter{foo}
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\selectlanguage{english}
+
+\section{Greek Numerals}
+
+See greek.pdf for the formation rules of Greek numerals.
+Some examples:
+
+\selectlanguage{greek}
+
+\greeknumeral{1},
+\greeknumeral{2},
+\greeknumeral{3},
+\greeknumeral{4},
+\greeknumeral{5},
+\greeknumeral{6},
+\greeknumeral{7},
+\greeknumeral{8},
+\greeknumeral{9},
+\greeknumeral{10},
+\greeknumeral{11},
+\greeknumeral{12},
+\greeknumeral{20},
+\greeknumeral{345},
+\greeknumeral{500},
+\greeknumeral{1997},
+\greeknumeral{2013},
+
+\Greeknumeral{1},
+\Greeknumeral{2},
+\Greeknumeral{3},
+\Greeknumeral{4},
+\Greeknumeral{5},
+\Greeknumeral{6},
+\Greeknumeral{7},
+\Greeknumeral{8},
+\Greeknumeral{9},
+\Greeknumeral{10},
+\Greeknumeral{11},
+\Greeknumeral{12},
+\Greeknumeral{20},
+\Greeknumeral{345},
+\Greeknumeral{500},
+\Greeknumeral{1997},
+\Greeknumeral{2013},
+
+
+Enumerated lists use Greek characters/numerals in the second and fourth level:
+
+\selectlanguage{greek}
+\begin{enumerate}
+ \item item 1
+ \begin{enumerate}
+ \item item 1.1
+ \begin{enumerate}
+ \item item 1.1.1
+ \begin{enumerate}
+ \item item 1.1.1.1
+ \item item 1.1.1.2
+ \end{enumerate}
+ \item item 1.1.2
+ \end{enumerate}
+ \end{enumerate}
+\end{enumerate}
+\selectlanguage{english}
+
+
+This may be problematic with fonts that only partially support Greek and
+miss the numeral signs (dexiakeraia and aristerikeraia).
+
+You may redefine the commands \verb+\textdexiakeraia+ and
+\verb+\textaristerikeraia+ to some substitute characters.
+Or, if you prefer the ``normal'' enumeration, write in the preamble after
+loading babel:
+
+\begin{verbatim}
+ \makeatletter
+ \addto\extrasgreek{\let\@alph\latin@alph
+ \let\@Alph\latin@Alph}
+ \makeatother
+\end{verbatim}
+
+
+\end{document}
diff --git a/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.pdf b/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.pdf
new file mode 100644
index 0000000000..fb7ebe0ecc
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.tex b/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.tex
new file mode 100644
index 0000000000..af3502c071
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/test-unicode-lgr.tex
@@ -0,0 +1,264 @@
+\documentclass[a4paper]{article}
+% \usepackage{textcomp}
+\usepackage{hyperref,bookmark}
+\usepackage{parskip}
+
+% Declare the font encoding and Greek LICR definitions:
+\usepackage[LGR]{fontenc}
+
+% Set up Latin Modern OpenType unicode font
+\usepackage[tuenc]{fontspec}
+
+\usepackage[greek,english]{babel}
+% \languageattribute{greek}{polutoniko}
+% \languageattribute{greek}{ancient}
+
+% use LGR (8-bit CB-fonts) instead of Unicode fonts for Greek:
+% Alternatives:
+% \renewcommand*{\greekscript}{\fontencoding{LGR}\selectfont}
+\addto{\extrasgreek}{\greektext}
+
+\begin{document}
+
+\title{XeTeX/LuaTeX with LGR fonts}
+\author{Günter Milde}
+\date{2014/09/02}
+\maketitle
+
+The babel option «greek» activates the support for the Greek language
+defined in the file «greek.ldf» (source «greek.dtx»).
+
+Typesetting Greek texts requires a font containing Greek letters. With the
+XeTeX or LuaTeX engines, the user must ensure that the selected font
+contains the required glyphs (the default Latin Modern fonts miss them).
+
+Latin Modern can be combined with the matching CB-Greek 8-bit font. For the
+setup, see the preamble of this document \texttt{test-unicode-lgr.tex}
+
+Caveat: Currently, hyphenation does not work with this setup. Use it only
+for short Greek quotes or as a last ressort.
+
+\section{Language Switch}
+
+The declaration \verb|\selectlanguage| switches between languages. With
+XeTeX or LuaTeX and LGR, Unicode input is not possible. Instead, use the
+Latin transliteration or LICR macros:
+
+\begin{quote}
+ \selectlanguage{greek}
+ T'i f'hic? <Id`wn >enj'ede pa~id'' >eleuj'eran\\
+ t`ac plhs'ion N'umfac stefano~usan, S'wstrate,\\
+ >er~wn 'ap~hljec e>uj'uc?
+\end{quote}
+
+The macro \verb|\foreignlanguage| sets its second argument in the specified
+language. This is intended for short text parts like
+\foreignlanguage{greek}{Biblioj'hkh}.
+
+\section{Font Encoding}
+
+Switching to a font encoding supporting the Greek script is possible without
+switching the text language using the declarations \verb|\greekscript| or
+\verb|\greektext| (always LGR) and the macros \verb|\ensuregreek| or
+\verb|\textgreek|. These commands do not start a new paragraph.
+
+The Babel core defines the declaration \verb|\latintext| and the command
+\verb|\textlatin| to switch to the T1 or OT1 font encoding or typeset the
+argument using this encoding. \texttt{greek.ldf} adds a test for the Unicode
+font encodings TU, EU1, and EU2. Here, \verb|\latinencoding| is
+\latinencoding.
+
+With Unicode fonts, the macros \verb|\greektext| and \verb|\textgreek| are
+only defined, if the LGR font encoding is loaded via the \texttt{fontenc}
+package (see test-unicode-lgr.tex).
+
+% don't change the font encoding.
+With LGR, Latin characters in Greek text parts are typeset as Greek characters
+according to the Latin transcription defined in LGR.%
+
+\begin{quote}
+ \greektext F\'ilwn to\~u \textlatin{TeX} (EFT) --
+ \latintext{Friends (\textgreek{F\'ilwn}) of TeX.}%
+\end{quote}
+
+\section{MakeUppercase, MakeLowercase}
+
+Capital Greek letters have diacritics (except the dialytika and sub-iota) to
+the left (instead of above) and drop them in uppercase.
+
+Tonos and dasia mark a \emph{hiatus} (break-up of a diphthong) if placed on
+the first vowel of a diphtong (\textgreek{\'ai, \'au, \'ei, \'>ai, \'>au,
+\'>ei}). A dialytika must be placed on the second vowel if they are dropped.
+(\foreignlanguage{greek}{\MakeUppercase{\'ai, \'au, \'ei, \'>ai, \'>au,
+\'>ei}}).
+
+\section{LICR Macros}
+
+Babel defines macros for several autogenerated strings so that they may
+appear in the choosen language. \emph{babel-greek} uses LICR macros in
+order to let the string macros work independent of the font encoding.
+
+If \texttt{fontspec} is loaded before babel, babel-greek loads Greek LICR
+for EU1 or EU2 from the file \texttt{greek-euenc.def}
+provided with \emph{greek-fontenc} since version~0.10.
+
+\subsection{Hiatus}
+
+The «hiatus» feature works with macro input:
+
+\selectlanguage{greek}
+% from teubner: άυλος/ΑΫΛΟΣ
+\acctonos\textalpha\textupsilon\textlambda\textomicron\textfinalsigma{}
+$\mapsto$
+\MakeUppercase{\acctonos\textalpha\textupsilon\textlambda\textomicron\textfinalsigma},
+\'>\textalpha\textupsilon\textlambda\textomicron\textfinalsigma{} $\mapsto$
+\MakeUppercase{\'>\textalpha\textupsilon\textlambda\textomicron\textfinalsigma},
+% from http://diacritics.typo.cz/index.php?id=69 μάινα -> ΜΑΪΝΑ
+\textmu\acctonos\textalpha\textiota\textnu\textalpha{} $\mapsto$
+\MakeUppercase{\textmu\acctonos\textalpha\textiota\textnu\textalpha},
+% from http://de.wikipedia.org/wiki/Neugriechische_Orthographie#Das_Trema
+% κέικ, ἀυπνία/αϋπνία
+\textkappa\acctonos\textepsilon\textiota\textkappa $\mapsto$
+\MakeUppercase{\textkappa\acctonos\textepsilon\textiota\textkappa},
+\accpsili\textalpha\textupsilon\textpi\textnu\'\textiota\textalpha{} $\mapsto$
+\MakeUppercase{\accpsili\textalpha\textupsilon\textpi\textnu\'\textiota\textalpha}.
+\selectlanguage{english}
+
+\subsection{Captions}
+
+\selectlanguage{greek}
+\prefacename,
+\refname,
+\abstractname,
+\bibname,
+\chaptername,
+\appendixname,
+\contentsname,
+\listfigurename ,
+\listtablename,
+\indexname,
+\figurename,
+\tablename,
+\partname,
+\enclname,
+\ccname,
+\headtoname,
+\pagename,
+\seename,
+\alsoname,
+\proofname,
+\glossaryname
+\selectlanguage{english}
+
+Test correct upcasing (dropping of accents):
+
+\selectlanguage{greek}
+\MakeUppercase{
+\prefacename,
+\refname,
+\abstractname,
+\bibname,
+\chaptername,
+\appendixname,
+\contentsname,
+\listfigurename,
+\listtablename,
+\indexname,
+\figurename,
+\tablename,
+\partname,
+\enclname,
+\ccname,
+\headtoname,
+\pagename,
+\seename,
+\alsoname,
+\proofname,
+\glossaryname
+}
+\selectlanguage{english}
+
+
+\subsection{Months}
+
+\selectlanguage{greek}
+\newcounter{foo}
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\stepcounter{foo} \month=\value{foo} \today \\
+\selectlanguage{english}
+
+\section{Greek Numerals}
+
+See greek.pdf for the formation rules of Greek numerals.
+Some examples:
+
+\selectlanguage{greek}
+
+\greeknumeral{1},
+\greeknumeral{2},
+\greeknumeral{3},
+\greeknumeral{4},
+\greeknumeral{5},
+\greeknumeral{6},
+\greeknumeral{7},
+\greeknumeral{8},
+\greeknumeral{9},
+\greeknumeral{10},
+\greeknumeral{11},
+\greeknumeral{12},
+\greeknumeral{20},
+\greeknumeral{345},
+\greeknumeral{500},
+\greeknumeral{1997},
+\greeknumeral{2013},
+
+\Greeknumeral{1},
+\Greeknumeral{2},
+\Greeknumeral{3},
+\Greeknumeral{4},
+\Greeknumeral{5},
+\Greeknumeral{6},
+\Greeknumeral{7},
+\Greeknumeral{8},
+\Greeknumeral{9},
+\Greeknumeral{10},
+\Greeknumeral{11},
+\Greeknumeral{12},
+\Greeknumeral{20},
+\Greeknumeral{345},
+\Greeknumeral{500},
+\Greeknumeral{1997},
+\Greeknumeral{2013},
+
+
+\selectlanguage{english}
+Enumerated lists use Greek characters/numerals in the second and fourth level:
+
+\selectlanguage{greek}
+\begin{enumerate}
+ \item \textlatin{item} 1
+ \begin{enumerate}
+ \item \textlatin{item} 1.1
+ \begin{enumerate}
+ \item \textlatin{item} 1.1.1
+ \begin{enumerate}
+ \item \textlatin{item} 1.1.1.1
+ \item \textlatin{item} 1.1.1.2
+ \end{enumerate}
+ \item \textlatin{item} 1.1.2
+ \end{enumerate}
+ \end{enumerate}
+\end{enumerate}
+\selectlanguage{english}
+
+\end{document}
diff --git a/macros/latex/contrib/babel-contrib/greek/usage.pdf b/macros/latex/contrib/babel-contrib/greek/usage.pdf
new file mode 100644
index 0000000000..946f41514c
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/usage.pdf
Binary files differ
diff --git a/macros/latex/contrib/babel-contrib/greek/usage.tex b/macros/latex/contrib/babel-contrib/greek/usage.tex
new file mode 100644
index 0000000000..50d76aae02
--- /dev/null
+++ b/macros/latex/contrib/babel-contrib/greek/usage.tex
@@ -0,0 +1,257 @@
+% \iffalse meta-comment
+%
+% Copyright 1989-2008 Johannes L. Braams and any individual authors
+% listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the Babel system.
+% --------------------------------------
+%
+% It may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2003/12/01 or later.
+%
+% This work has the LPPL maintenance status "maintained".
+%
+% The Current Maintainer of this work is Günter Milde.
+%
+% The list of all files belonging to the Babel system is
+% given in the file `manifest.bbl. See also `legal.bbl' for additional
+% information.
+%
+% The list of derived (unpacked) files belonging to the distribution
+% and covered by LPPL is defined by the unpacking scripts (with
+% extension .ins) which are part of the distribution.
+% \fi
+\documentclass[11pt]{article}
+\usepackage[american,greek]{babel}
+\languageattribute{greek}{polutoniko}
+\usepackage{athnum,grmath}
+\newcommand{\sg}{\selectlanguage{greek}}
+\newcommand{\sa}{\selectlanguage{american}}
+\begin{document}
+% \show\extrasgreek
+%\show\extraspolutonikogreek
+\selectlanguage{american}
+
+\title{Writing Greek with the \ttfamily greek\rmfamily\ option of the
+\ttfamily babel\rmfamily\ package}
+\author{Apostolos Syropoulos\\
+ 366, 28th October Str.\\
+ GR-671 00 Xanthi, GREECE\\
+ e-mail: \texttt{apostolo@platon.ee.duth.gr}}
+\date{October 15, 1997}
+\maketitle
+
+\abstract{\noindent
+This document describes the use of the Latin transliteration for Greek that
+is defined by the LGR font encoding. Today, all modern LaTeX distributions
+support literal input of Greek, which is the preferred method for new
+documents. [G. Milde 2013/12/02]}
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\section{Overview}
+
+The \texttt{greek} option of the \texttt{babel} package is an attempt to
+make it possible for someone to write Greek text with \LaTeX. The current
+version of the \texttt{greek} option supports the
+\textgreek{monotonik'o} and \textgreek{polutonik'o}
+accentual systems of the Greek language.
+Moreover, there is now support for Greek numerals. One can produce easily
+valid Greek numerals both in uppercase and lowercase forms, e.g,
+\textgreek{\greeknumeral{1997}}\ and \textgreek{\Greeknumeral{1997}}. The
+labels in second and fourth level enumerations are lowercase
+and uppercase Greek numerals correspondingly.
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\section{Typing Greek Text}
+By default, \TeX\ understands only 7-bit ASCII characters, so it is not
+possible to enter directly Greek letters.%
+\footnote{Literal input of Greek characters
+is possible with XeTeX, LuaTeX, or the greek-inputenc LaTeX package.
+G. Milde, 2013/07/19}
+Instead, someone enters Latin letters
+which are mapped to their Greek ``counterparts'' by \TeX. The following
+table shows the transliteration employed:
+\begin{center}
+\begin{tabular}{|lllllllllllll|}\hline
+\textgreek{a}&
+\textgreek{b}&
+\textgreek{g}&
+\textgreek{d}&
+\textgreek{e}&
+\textgreek{z}&
+\textgreek{h}&
+\textgreek{j}&
+\textgreek{i}&
+\textgreek{k}&
+\textgreek{l}&
+\textgreek{m}&
+\textgreek{n}\\
+a& b& g& d& e& z& h& j& i& k& l& m& n\\
+\hline
+\textgreek{x}&
+\textgreek{o}&
+\textgreek{p}&
+\textgreek{r}&
+\textgreek{sv}&
+\textgreek{t}&
+\textgreek{u}&
+\textgreek{f}&
+\textgreek{q}&
+\textgreek{y}&
+\textgreek{w}&
+\textgreek{c}& \hbox{ } \\
+x& o& p& r& s&
+t& u& f& q& y& w& c& \hbox{ }\\ \hline
+\end{tabular}
+\end{center}
+Please, note that in order to produce the letter \textgreek{sv} in isolation
+on has to type \texttt{sv}. This feature is due to the strong ligature
+that \TeX\ employs.
+In the ``modern'' \textgreek{monotonik'o} accentual system only one accent is
+used---\textgreek{oxe'ia} (acute). In the traditional \textgreek{polutonik'o}
+accentual system we
+need more accents and breathing signs. We can produce an accented letter by
+prefixing the letter with he symbol that denotes the accent, e.g.,
+\texttt{>a'erac} produces the word \sg >a'erac.\sa\footnote{For the
+technically inclined reader, we must say that \TeX\ uses the ligature table of
+the font in order to determine the character that corresponds to the
+input character sequence.} Here are the symbols that are recognized:
+
+\begin{center}
+\begin{tabular}{cccc}\hline
+Accent & Symbol & Example & Output\\ \hline
+acute & \texttt{'} & \texttt{g'ata} & \textgreek{g'ata}\\
+grave & \texttt{`} & \texttt{dad`i} & \textgreek{dad`i}\\
+circumflex & \verb+~+ & \verb+ful~hc+ & \sg\textgreek{ful~hc}\sa\\
+rough breathing & \verb+<+ & \verb+<'otan+ & \sg\textgreek{<'otan}\sa\\
+smooth breathing & \verb+>+ & \verb+>'aneu+ & \sg\textgreek{>'aneu}\sa\\
+subscript & \texttt{|} & \verb+>anate'ilh|+ & \sg\textgreek{>anate'ilh|}\\
+dieresis & \texttt{"}& \texttt{qa"ide'uh|c} & \sg\textgreek{qa"ide'uh|c}\\
+\hline
+\end{tabular}
+\end{center}
+Note that the subscript symbol is placed \textbf{after} the letter.
+The last thing someone must know in order to be able to write normal Greek
+text is the punctuation marks used in the language:
+\begin{center}
+\begin{tabular}{ccc}\hline
+Punctuation Sign & Symbol & Output\\ \hline
+period & \texttt{.} & \sg\textgreek{.}\sa\\
+semicolon & \texttt{;} & \sg\textgreek{;}\sa\\
+exclamation mark & \texttt{!} & \sg\textgreek{!}\sa\\
+comma & \texttt{,} & \sg\textgreek{,}\sa\\
+colon & \texttt{:} & \sg\textgreek{:}\sa\\
+question mark & \texttt{?} & \sg\textgreek{?}\sa\\
+left apostrophe & \texttt{``} & \sg\textgreek{``}\sa\\
+right apostrophe & \texttt{''} & \sg\textgreek{''}\sa\\
+left quotation mark & \texttt{((} & \sg\textgreek{))}\sa\\
+right quotation mark & \texttt{))} & \sg\textgreek{))}\sa\\ \hline
+\end{tabular}
+\end{center}
+Using these conventions it is a straightforward exercise to write Greek
+\textgreek{polutoniko} text. For example the following excerpt from
+\textgreek{D'uskoloc} of \textgreek{M'enandroc}
+\sg
+\begin{quote}
+T'i f'hic? <Id`wn >enj'ede pa~id'' >eleuj'eran\\
+t`ac plhs'ion N'umfac stefano~usan, S'wstrate,\\
+>er~wn 'ap~hljec e>uj'uc?
+\end{quote}
+\sa can be produced by the following \LaTeX\ code:
+\begin{center}
+\begin{tabular}{l}
+\verb+T'i f'hic? <Id`wn >enj'ede pa~id'' >eleuj'eran+\\
+\verb+t`ac plhs'ion N'umfac stefano~usan, S'wstrate,+\\
+\verb+>er~wn 'ap~hljec e>uj'uc?+
+\end{tabular}
+\end{center}
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\section{Producing Greek Text}
+Once the Greek language is selected with the command
+\begin{center}
+\verb+\selectlanguage{greek}+
+\end{center}
+whatever we type will be typeset with the Greek fonts. The command
+\verb+\textlatin+ can be used for short passages in some language that
+uses the Latin alphabet, while the the command \verb+\latintext+ changes
+the base fonts to the ones used by languages that use the Latin alphabet.
+However, all words will be hyphenated by following the Greek hyphenation
+rules! Similar commands are available once someone has selected some
+other language. The commands \verb+\textgreek+ and \verb+\greektext+
+behave exactly like their ``latin'' counterparts. For example, the
+word \textgreek{M'imhc} has been produced with the command
+\verb+\textgreek{M'imhc}+. Please note that certain symbols cannot have
+their expected result for Greek text, unless someone has selected the Greek
+language, e.g., \verb+~+ is such a symbol.
+
+As we have mentioned above this version of the \texttt{greek} option of the
+\texttt{babel} package supports the use of Greek numerals. The commands
+\verb+\greeknumeral+ and \verb+\Greeknumeral+ produce the lowercase and
+the uppercase Greek numeral, e.g.,
+\begin{center}
+\begin{tabular}{cc}\hline
+Command & Output\\ \hline
+\verb+\Greeknumeral{9999}+ & \sg\textgreek{\Greeknumeral{9999}}\\
+\verb+\greeknumeral{9999}+ & \sg\textgreek{\greeknumeral{9999}}\\
+\hline
+\end{tabular}
+\end{center}
+In order to correctly typeset the greek numerals the greek option file
+provides the following commands:
+\begin{center}
+\begin{tabular}{cc}\hline
+Command & Output\\ \hline
+\verb+\qoppa+ & \textgreek{\qoppa}\\
+\verb+\sampi+ & \textgreek{\sampi}\\
+\verb+\stigma+ & \textgreek{\stigma}\\
+\hline
+\end{tabular}
+\end{center}
+
+In traditional Greek typography the first paragraph after a header is
+always indented, contrary to the habit of, say, American typography. This
+effect can be achieved by using the package \verb+indentfirst+.
+
+Additional greek symbols are available:
+\begin{center}
+\begin{tabular}{cc}\hline
+Command & Output\\ \hline
+\verb+\Digamma+ & \sg\textgreek{\Digamma}\\
+\verb+\ddigamma+ & \sg\textgreek{\ddigamma}\\
+%\verb+\tao+ & \sg\textgreek{\tao}\\
+%\verb+\Qoppa+ & \sg\textgreek{\Qoppa}\\
+%\verb|\VarQoppa| & \sg\textgreek{\VarQoppa}\\
+%\verb+\varqoppa+ & \sg\textgreek{\varqoppa}\\
+%\verb+\Sampi+ & \sg\textgreek{\Sampi}\\
+%\verb|\Stigma| & \sg\textgreek{\Stigma}\\
+\verb|\euro| & \sg\textgreek{\euro}\\
+\verb|\permill| & \sg\textgreek{\permill}\\
+\hline
+\end{tabular}
+\end{center}
+
+The package \verb|athnum| provides the command \verb|\athnum|, with which
+one can produce the so called \textit{Athenian numerals}:
+\begin{center}
+\begin{tabular}{cc}\hline
+Command & Output\\ \hline
+\verb|\athnum{1997}| & \sg\textgreek{\athnum{1997}}\\
+\hline
+\end{tabular}
+\end{center}
+
+The package \verb|grmath| renames the basic log-like functions with their
+greek counterparts:
+\begin{center}
+\begin{tabular}{cc}\hline
+Command & Output\\ \hline
+\verb|$\sin^{2}x+\cos^{2}x=1$| & $\sin^{2}x+\cos^{2}x=1$\\
+\hline
+\end{tabular}
+\end{center}
+\end{document}