Comprehensive TeX Archive Network
Home Upload Browse

Direc­tory tex-archive/language/greek/greek-fontenc

Greek font encoding definition files

:Author:    Günter Milde
:Date:      2013-10-01
:Copyright: © 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:  This package provides Greek LICR macro definitions and encoding
            definition files for `Greek text font encodings`_ for use with

.. note::   The LICR macro names for Greek symbols are chosen pending
            endorsement by the TeX community and related packages.

            Names for archaic characters, accents/diacritics, and
            punctuation may change in future versions.


.. class:: borderless

==========  ====== ==========================================================
2013-07-03  0.9    greek-fontenc.def_ "outsourced" from lgrxenc.def
..                 experimental files xunicode-greek.sty and
                   greek-euenc.def_: LICRs for XeTeX/LuaTeX.
2013-07-18  0.9.1  bugfix: wrong breathings psilioxia -> dasiaoxia.
2013-07-19  0.9.2  bugfix: Disable composite defs starting with char macro,
..                 fix "hiatus" handling.
2013-07-24  0.9.3  fix "input" path in xunicode-greek and greek-euenc.def.
2013-09-10  0.9.4  greek-fontenc.sty: Greek text font encoding setup package,
..                 remove xunicode-greek.sty.
2013-09-13  0.10   textalpha.sty_ and alphabeta.sty_ moved here from lgrx and
                   updated to work with XeTeX/LuaTeX.
..                 greek-fontenc.sty removed (obsoleted by textalpha.sty).
2013-10-01  0.10.1 bugfix in greek-euenc.def_ and alphabeta-euenc.def_.
2013-11-28  0.11   compatibility with Xe/LuaTeX in 8-bit mode,
..                 ``\greekscript`` TextCommand.
2013/12/01  0.11.1 fix identification of ``greek-euenc.def``.
==========  ====== ==========================================================

LaTeX files

  `Common Greek font encoding definitions <greek-fontenc.def.html>`_.

  `LGR Greek font encoding definitions <lgrenc.def.html>`_.

  This file is the successor of the basic LGR encoding definition file which
  comes with babel_'s Greek support and ``lgrxenc.def`` from the lgrx_

  `Greek symbols in text <textalpha.sty.html>`_
  independent of font encoding and TeX engine.

  Generic macros for `Greek symbols in text and math <alphabeta.sty.html>`_.

  `Composite defintions for alphabeta.sty_ with XeTeX/LuaTeX.

  `Greek LICR definitions for XeTeX and LuaTeX <greek-euenc.def.html>`_.
  Requires euenc_.

Literate source files were converted with PyLit_ to reStructuredText_ and
with Docutils_ to the HTML documentation.

Documentation and test documents

`<textalpha-test.tex>`__, `<textalpha-test.pdf>`_
  `The textalpha package`.

`<alphabeta-test.tex>`__ `<alphabeta-test.pdf>`_
  `The alphabeta package`.

`<lgrenc-test.tex>`_, `<lgrenc-test.pdf>`_
  Test and usage example.

`<euenc-test.tex>`_, `<euenc-test.pdf>`_
  Example for use of the experimental Greek LICR definitions with XeTeX or

`<greekhyperref.tex>`_, `<greekhyperref.pdf>`_
  `Greek script in PDF metadata`.

  The package hyperref_ defines the PU font encoding which also supports
  (monotonic) Greek.

Experimental files

These files are still in development and will eventually be moved to/merged
with other packages or removed in future versions:

  `LGR Transcription to Greek LICR transformation <lgr2licr.lua.html>`_


If possible, get this package from your distribution using its installation

Otherwise, make sure LaTeX can find the package and definition files:

* Download and unpack ````.

* Copy/Move/Link files ending in ``.def`` or ``.sty`` to a suitable place in
  the TDS_ and run ``texhash``, or place them in the current working
  directory (e.g. for testing).


There are many alternatives to use the Greek font encoding setup
provided by this package/bundle, e.g.:

* Ensure Greek support in text mode with `textalpha`::


  For details see `<textalpha-test.tex>`_ and `<textalpha-test.pdf>`_ (8-bit
  TeX) as well as `<euenc-test.tex>`_ and `<euenc-test.pdf>`_

* To use the short macro names (``\alpha`` ... ``\Omega``) known from math
  mode in both, text and math mode, write ::


  For details see `<alphabeta-test.tex>`_ and `<alphabeta-test.pdf>`_.

* Use the ``greek`` option with Babel_ (requires babel-greek_)::


* Declare LGR via fontenc_. For example, specify T1 (8-bit
  Latin) as default font encoding and LGR for Greek with ::


  Note that without ``textalpha`` or ``alphabeta``, Greek text macros work
  only if the current font encoding supports Greek. See [fntguide]_ for
  details and `<lgrenc-test.tex>`_ for an example.

* 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.
  See `<euenc-test.tex>`_ -> `<euenc-test.pdf>`_ and
  `<lgrenc-test.tex>`_ -> `<lgrenc-test.pdf>`_.

Greek text font encodings

Greek TeX font encodings are the envisaged T7_, LGR_, and LGI_.
Greek letters and symbols are also defined in the Unicode-based font
encodings EU1 (XeTeX), EU2 (LuaTeX) and PU (hyperref_).


The [encguide]_ reserves the name T7 for a Greek `standard font encoding`.
However, up to now, there is no agreement on an implementation because the
restrictions for general text encodings are too severe for typesetting
polytonic Greek.


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.

The LGR font encoding allows to access Greek characters via an ASCII
transliteration. This enables simple input with a Latin keyboard.
Characters with diacritics can be selected by ligature definitions in the
font (see [greek-usage]_, [teubner-doc]_, [cbfonts]_).

A major drawback of the transliteration is, that you cannot access Latin
letters if LGR is the active font encoding (e.g. in documents or parts of
documents given the `Babel` language ``greek`` or ``polutionikogreek``).
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 Latin and Greek like the envisaged T7_ or
Unicode (with XeTeX or LuaTeX).


The ‘Ibycus’ fonts from the package ibygrk_ implement an alternative
transliteration scheme (also explained in [babel-patch]_).
It is currently not supported by `greek-fontenc`.

The font encoding file ``lgienc.def`` from ibycus-babel_ provides a basic
setup (without any LICR macros or composite definitions).

Greek LICR macro names

This package provides LaTeX internal character representations (LICR macros)
for Greek letters and diacritics. Macro names were selected based on the
following considerations:

The fntguide_ (section 6.4 Naming conventions) recommends:

  Where possible, text symbols should be named as ``\text`` followed
  by the Adobe glyph name: for example ``\textonequarter`` or
  ``\textsterling``. Similarly, math symbols should be named as
  ``\math`` followed by the glyph name, for example
  ``\mathonequarter`` or ``\mathsterling``.

The `Adobe Glyph List For New Fonts`_ has names for many glyphs in the
`Greek and Coptic` Unicode block, but not for `Greek extended`. The `Adobe
Glyph List`_ (for existing fonts) lists additional glyph names used in older
fonts. As these are not intened for further active use, the latter are not
considered in the name choice.


* If there exists a math-mode macro for a symbol, form the corresponding text
  macro by prepending ``text``?

    The glyph name for the GREEK SMALL LETTER FINAL SIGMA is ``sigma1``,
    the corresponding math-macro is ``\varsigma``. The text symbol could be
    made available as ``\textvarsigma``.

    ``\varepsilon`` and ``\varphi`` math macros map to characters named
    "GREEK SMALL **LETTER** ...", while ``\\vartheta``, ``\\varkappa``,
    ``\\varrho``, and ``\\varpi`` math macros map to "GREEK ... **SYMBOL**"
    Unicode characters.

    In Greek text, these variants are interchangeable. The LGR font encoding
    does not contain slots for "symbol" glyph variants. In some Greek fonts,
    GREEK SMALL LETTERS use glyph variants resembling the corresponding
    GREEK SYMBOL Unicode character's reference glyph.

* Derive macro names from Unicode names?

  The `Unicode names list`_ provides standardized descriptive names for all
  Unicode characters that use only capital letters of the Latin alphabet.
  While not suited for direct use in a LICR macros, they can be either

  a) used as inspiration for new LICR macro names or

  b) converted to LICR macro names via a defined set of transformation rules.

    ``\textfinalsigma`` or just ``\finalsigma`` as a more descriptive name
    for GREEK SMALL LETTER FINAL SIGMA derived via the rules:

    * drop "LETTER" if the name remains unique,
    * drop "GREEK" if the name remains unique,
    * use capitalized name for capital letters, lowercase for "SMALL" letters
      and drop "SMALL",
    * concatenate

* Omit the "text" prefix for macros that do not have a math counterpart?

    + Simpler,

    + ease of use (less typing, better readability of source text),

    + many established text macro names without "text",

    + there are examples of encoding-specific macros
      without the ``text``-prefix, especially for letters,

      :T1:  ``\AE \DH \DJ \L \NG \OE \O \SS \TH \ae \dh \dj \guillemotleft``
            ``\guillemotright \guilsinglleft \guilsinglright \i \j \l \ng``
            ``\oe \o \quotedblbase \quotesinglbase \ss \th`` (also in OT1)
      :T2*: ``\CYR*`` and ``\cyr*``
      :HE8: ``\heb*`` or no prefix
      :PU:  short descriptive names in the arabic part (``puarenc.def``)

    + ``text`` prefix does **not** mark a macro as encoding-specific or
      "inserting a glyph". There are e.g. font-changing macros (``\textbf``,
      ``\textit``) and encoding-changing macros (``\textgreek``,

    - Less consistent.

    - ``text`` prefix marks a macro as confined to text mode.

      To avoid name clashes, this package uses the ``text`` prefix
      for symbols. Aliases (short forms, compatibility defs, etc.) can be
      defined in packages.

How to name *accent macros*?

* standard accent macros (``\DeclareTextAccent`` definitions in
  ``latex/base/...``) are one-symbol macros (``\' \" ... \u \v ...``) .

* ``tipa.sty``, xunicode_, and ucs_ use the "text" prefix also for accents.

  However, the `Adobe Glyph List For New Fonts`_ maps, e.g., "tonos" and
  "dieresistonos" to 0384 GREEK TONOS and 0385 GREEK DIALYTIKA TONOS, hence
  `\texttonos` and `\textdiaresistonos` should be spacing characters.

* textcomp (ts1enc.def) defines ``\capital...`` accents (i.e. without
  ``text`` prefix).

* Use a common prefix ``\textaccent...``, ``\accent...``,
  or just ``\acc...`` (cf ``\@tabacckludge``)?

Currently, `greek-fontenc` uses for diacritics:

- Greek names like in Unicode, and ucsencs.def

- The prefix "acc" to distinguish the macros as `TextAaccent` and reduce the
  risc of name clashes.

- For the end-user "symbol macros" (``\~ \' \` \" \< \>``) are provided.


An alternative, more complete set of short mnemonic character names is
the `XML Entity Definitions for Characters`_ W3C Recommendation from
01 April 2010.

For glyph names of the LGR encoding see e.g. ``CB.enc`` by Apostolos
Syropoulos and ``xl-lgr.enc`` from the libertine_ (legacy) package.
``lgr.cmap`` provides a mapping to Unicode characters.

A full set of ``\text*`` symbol macros is defined in ``ucsencs.def``
from the ucs_ package.

Aliases from ``puenc.def`` ensure that the hyperref_ package can convert
Greek text in "LICR encoding" to a PDF-string (utf-8 encoded input is used

.. [fntguide] LaTeX3 Project Team, `LaTeX2ε font selection`, 2005.
.. [encguide] Frank Mittelbach, Robin Fairbairns, Werner Lemberg,
   LaTeX3 Project Team, `LaTeX font encodings`, 2006.
.. [greek-usage] Apostolos Syropoulos, `Writing Greek with the greek option
   of the babel package`, 1997.
.. [cbfonts] Claudio Beccari, `The CB Greek fonts`, Εὔτυπον, τεῦχος № 21, 2008.
.. [teubner-doc] Claudio Beccari, ``teubner.sty``
   `An extension to the greek option of the babel package`, 2011.

.. [babel-patch] Werner Lemberg, `Unicode support for the Greek LGR
   encoding` Εὔτυπον, τεῦχος  № 20, 2008.

.. _LaTeX Project Public License:
.. _PyLit:
.. _reStructuredText:
.. _Docutils:
.. _TDS:

.. _Adobe Glyph List For New Fonts:
.. _Adobe Glyph List:
.. _Unicode names list:
.. _XML Entity Definitions for Characters:

.. _CB Fonts:
.. _GFS font collection:
.. _Kerkis:
.. _babel:
.. _babel-greek:
.. _euenc:
.. _fontenc:
.. _grtimes:
.. _hyperref:
.. _ibycus-babel:
.. _ibygrk:
.. _lgrx:
.. _libertine:
.. _substitutefont:
.. _ucs:
.. _xunicode:


Name Size Date Notes
README 15254 2013-12-02 12:51:54
README.html 26136 2013-12-02 12:49:14
alphabeta-euenc.def 21000 2013-11-04 08:56:49
alphabeta-euenc.def.html 22311 2013-10-01 03:19:57
alphabeta-euenc.def.txt 21442 2013-10-01 03:03:28
alphabeta-test.pdf 56226 2013-11-29 11:49:52
alphabeta-test.tex 8273 2013-11-29 11:50:55
alphabeta.sty 19796 2013-11-04 10:31:06
alphabeta.sty.html 22812 2013-09-13 12:04:02
diacritics.pdf 97764 2013-11-29 12:09:25
diacritics.tex 5618 2013-11-29 12:22:33
euenc-test.pdf 67373 2013-11-29 01:05:52
euenc-test.tex 21929 2013-11-29 09:40:13
greek-euenc.def 33351 2013-12-02 12:47:24
greek-euenc.def.html 35924 2013-12-02 12:47:30
greek-fontenc.def 17335 2013-11-28 03:14:27
greek-fontenc.def.html 21407 2013-11-28 03:14:32
greekhyperref.pdf 221203 2013-11-28 06:19:52
greekhyperref.tex 5187 2013-11-29 01:02:13
lgr2licr.lua 4601 2013-07-18 11:57:32
lgr2licr.lua.html 6914 2013-07-18 12:57:52
lgrenc-test.pdf 126797 2013-11-29 12:46:18
lgrenc-test.tex 15067 2013-11-29 12:47:22
lgrenc.def 36493 2013-07-18 01:00:44
lgrenc.def.html 49236 2013-07-18 01:01:06
textalpha-test.pdf 59863 2013-11-28 10:52:21
textalpha-test.tex 10363 2013-11-28 10:53:12
textalpha.sty 15090 2013-11-29 09:32:31
textalpha.sty.html 19660 2013-11-29 09:29:27

Down­load the con­tents of this pack­age in one zip archive (710.5k).

greek-fontenc – LICR macros and en­cod­ing def­i­ni­tion files for Greek

The pack­age pro­vides Greek LICR macro def­i­ni­tions and en­cod­ing def­i­ni­tion files for Greek text font en­cod­ings for use with fontenc.

Ver­sion0.11.1 2013-12-01
Li­censeThe LaTeX Project Public Li­cense 1.3
Copy­right2013 Gün­ter Milde
Main­tainerGün­ter Milde
Con­tained inTeXlive as greek-fontenc
MikTeX as greek-fontenc
Topics sup­port for type­set­ting Greek
in­put en­cod­ing sup­port for TeX en­gines
See also lgrx
Guest Book Sitemap Contact 2014-04-24 15:53 CEST