Difference between revisions of "Greek"

From Wiki
Jump to navigation Jump to search
(new rewrite with fonts missing)
(finish monotonic v acute and add character normalization)
(7 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
{{todo|Please add fonts that contain polytonic Greek to the last section!}}
 
{{todo|Please add fonts that contain polytonic Greek to the last section!}}
  
== Introduction ==
+
= Introduction =
  
 
Historically, the development of Greek language can be divided in:
 
Historically, the development of Greek language can be divided in:
Line 13: Line 13:
 
* Polytonic (or multiple–accented): diacritical marks are three accents (acute, grave and circumflex) and two breathings (rough and smooth).
 
* Polytonic (or multiple–accented): diacritical marks are three accents (acute, grave and circumflex) and two breathings (rough and smooth).
  
Monotonic ortography became law in 1982.<ref>See Law 1228/1982 and Decree 297/1982. Both legatl texts were written with polytonic ortography, but they contain the provisions for the monotonic system.</ref> Greek was polytonic before and ancient Greek is polytonic because it was before 1982.<ref>Just in case you may wonder, this is independent from the popular (δημοτική) v. purified (καθαρέυουσα) dispute for Greek language. See Law 309/1976. The legal text was written in the purified Greek, but it ordered the popular Greek to be the official language.</ref> This means that polytonic Greek is not only ancient Greek, since the main part of modern Greek was polytonic.
+
After a long development,<ref>For historical background, see https://en.wikipedia.org/wiki/Greek_language_question. This reference contains the recommendation for the [https://de.wikipedia.org/wiki/Griechische_Sprachfrage article from the German ''Wikipedia''].</ref> monotonic orthography became law in 1982.<ref>See Law 1228/1982 and Decree 297/1982. Both legatl texts were written with polytonic orthography, but they contain the provisions for the monotonic system.</ref> Greek was polytonic before and ancient Greek is polytonic because it was before 1982.<ref>Just in case you may wonder, this is independent from the popular (δημοτική) v. purified (καθαρέυουσα) dispute for Greek language. See Law 309/1976. The legal text was written in the purified Greek, but it ordered the popular Greek to be the official language.</ref> This means that polytonic Greek is not only ancient Greek, since the main part of modern Greek was polytonic.
  
==Unicode==
+
=Unicode=
  
 
Monotonic Greek needs the characters from the [https://en.wikipedia.org/wiki/Greek_and_Coptic “Greek and Coptic” Unicode block] (only the Greek part of it, not the Coptic part).
 
Monotonic Greek needs the characters from the [https://en.wikipedia.org/wiki/Greek_and_Coptic “Greek and Coptic” Unicode block] (only the Greek part of it, not the Coptic part).
Line 25: Line 25:
 
Just in case you wonder, there are much more fonts that contain glyphs for monotonic Greek that for polytonic Greek.
 
Just in case you wonder, there are much more fonts that contain glyphs for monotonic Greek that for polytonic Greek.
  
==Ancient Greek==
+
==Monotonic and Acute Accent==
 +
 
 +
Although the monotonic accent was acute, Unicode defines a pair of characters for monotonic accented vowels and polytonic acute accented vowels (both uppercase and lowercase and with diairesis).
 +
 
 +
These are the different characters in lowercase:
 +
 
 +
<pre>
 +
ά έ ή ί ΐ ό ύ ΰ ώ
 +
ά έ ή ί ΐ ό ύ ΰ ώ
 +
</pre>
 +
 
 +
In theory, both characters should have the same glyphs (they should be exactly the same strokes). In practice, this is not always the case, since the monotonic accent has been drawn as (almost) a vertical stroke.
 +
 
 +
The acute accent should mirror the grave accent (it is mainly its horizontal flip). Although acute accented vowels in polytonic Greek could be taken from the Greek and Coptic Unicode block, acute–accented vowels from the polytonic block may be required (because of the mismatch between the monotonic accent and the grave accent).
 +
 
 +
The following source displays the differences for each character with both accents (uppercase and lowercase characters):<ref>Of course, you should replace <code>Minion Pro</code> with the name of the font you want to test.</ref>
 +
 
 +
<texcode>
 +
\definefontfamily[mainface][rm][Minion Pro]
 +
\setupbodyfont[mainface]
 +
\definecolor [tred]  [r=1,t=.5,a=1]
 +
\definecolor [tblue] [b=1,t=.25,a=1]
 +
\unexpanded\def\tonosoxia[#1][#2]
 +
  {\startTEXpage[pagestate=start, offset=1ex]
 +
    \startoverlay
 +
      {\color[tred]{#1}}
 +
      {\color[tblue]{#2}}
 +
    \stopoverlay
 +
  \stopTEXpage}
 +
\starttext
 +
\tonosoxia[Ά][Ά]
 +
\tonosoxia[Έ][Έ]
 +
\tonosoxia[Ή][Ή]
 +
\tonosoxia[Ί][Ί]
 +
\tonosoxia[Ό][Ό]
 +
\tonosoxia[Ύ][Ύ]
 +
\tonosoxia[Ώ][Ώ]
 +
\tonosoxia[ά][ά]
 +
\tonosoxia[έ][έ]
 +
\tonosoxia[ή][ή]
 +
\tonosoxia[ί][ί]
 +
\tonosoxia[ΐ][ΐ]
 +
\tonosoxia[ό][ό]
 +
\tonosoxia[ύ][ύ]
 +
\tonosoxia[ΰ][ΰ]
 +
\tonosoxia[ώ][ώ]
 +
\stoptext
 +
</texcode>
 +
 
 +
Depending on your operative system and your keyboard layout for polytonic Greek, it might be that it composes the acute with the monotonic accent (as it seems to happen in ''Linux'').
 +
 
 +
A workaround to avoid this would be the following:<ref>Although the ConTeXt distribution seems to include the ''EB Garamond'' font family, it is probably not included in the wiki.</ref>
 +
 
 +
<context source="yes">\startluacode
 +
fonts.handlers.otf.addfeature {
 +
    name = "tonosoxia",
 +
    type = "substitution",
 +
    data = {
 +
        Alphatonos = "Ά",
 +
        Epsilontonos = "Έ",
 +
        Etatonos = "Ή",
 +
        Iotatonos = "Ί",
 +
        Omicrontonos = "Ό",
 +
        Omegatonos = "Ώ",
 +
        Upsilontonos = "Ύ",
 +
        alphatonos = "ά",
 +
        epsilontonos = "έ",
 +
        etatonos = "ή",
 +
        iotatonos = "ί",
 +
        iotadieresistonos = "ΐ",
 +
        omicrontonos = "ό",
 +
        omegatonos = "ώ",
 +
        upsilontonos = "ύ",
 +
        upsilondieresistonos = "ΰ"
 +
        },
 +
    }
 +
\stopluacode
 +
 
 +
\definefontfeature[tonosoxia][tonosoxia=yes]
 +
 
 +
\definefontfamily
 +
    [mainface]
 +
    [rm]
 +
    [EB Garamond]
 +
    [features={default, tonosoxia}]
 +
 
 +
\setupbodyfont[mainface, 24pt]
 +
 
 +
\startTEXpage[offset=1em]
 +
χαλεπὰ τὰ καλά\\
 +
\feature[-][tonosoxia]
 +
χαλεπὰ τὰ καλά\\
 +
\stopTEXpage
 +
</context>
 +
 
 +
The sample above should display the difference between the more straight monotonic accent on the second line, and the proper acute accent.
 +
 
 +
==On “Character Normalization”==
 +
 
 +
Depending on your search, it might be that searching for <code>u</code>, results might include <code>ú</code> <code>ů</code>, <code>ü</code> or any character composed from <code>u</code> and any diacritical mark. Depending on the language, these “normalizations” may belong to the same letter or not (for example, <code>u</code> and <code>ü</code> are the same letter in Spanish, but two different ones in German).
 +
 
 +
This doesn’t only affects to letters: <code>,</code> and <code>‚</code> are the characters for the comma and the opening single–quotation mark (used in some languages, such as German), respectively. At least, ''Firefox'' only displays the occurrences for each character when the option to match diacritics is selected (otherwise, each character displays both occurrences for commas and these opening single–quotation marks).
 +
 
 +
At least in ''Linux'' (using ''Firefox''), the option to match diacritics doesn’t distinguish between monotonic and acute accented vowels. In other operative systems and using other programs, results might differ.
 +
 +
=Ancient Greek=
  
 
{{cmd|agr}} or {{cmd|ancientgreek}} are the values for ancient Greek hyphenation patterns.
 
{{cmd|agr}} or {{cmd|ancientgreek}} are the values for ancient Greek hyphenation patterns.
Line 39: Line 144:
 
</context>
 
</context>
  
==Monotonic Greek==
+
=Monotonic Greek=
  
 
Either as {{cmd|mainlanguage}} or {{cmd|language}}, right values are <code>gr</code> or <code>greek</code>.
 
Either as {{cmd|mainlanguage}} or {{cmd|language}}, right values are <code>gr</code> or <code>greek</code>.
Line 55: Line 160:
 
</context>
 
</context>
  
==Modern Polytonic Greek?==
+
=Modern Polytonic Greek?=
 +
 
 +
Before 1982, Greek orthography was mainly polytonic. In fact, modern<ref>As historical term, modern refers to the period that begins after the Middle Ages.</ref> Greek orthography was mainly polytonic.
  
Before 1982, Greek ortography was polytonic. It seems that hyphenation rules for polytonic Greek differ from both ancient or monotonic Greek.
+
Hyphenation rules for polytonic Greek differ from both ancient or monotonic Greek.
  
 
TeX has hyphenation patterns for [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-grc.tex ancient Greek], [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-el-monoton.tex monotonic Greek] and [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-el-polyton.tex modern polytonic Greek].
 
TeX has hyphenation patterns for [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-grc.tex ancient Greek], [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-el-monoton.tex monotonic Greek] and [http://mirror.ctan.org/language/hyph-utf8/tex/generic/hyph-utf8/patterns/tex/hyph-el-polyton.tex modern polytonic Greek].
Line 63: Line 170:
 
ConTeXt has patterns for ancient and monotonic Greek only.
 
ConTeXt has patterns for ancient and monotonic Greek only.
  
==Language–Dependent Commands==
+
=Language–Dependent Commands=
  
 
As of current latest (2023.01.15 14:04), language–dependent commands—such as {{cmd|currentdate}}—don’t work. Nobody seemed to need them—especially for current Greek. If you need them, please send a message to the mailing list to extend this.
 
As of current latest (2023.01.15 14:04), language–dependent commands—such as {{cmd|currentdate}}—don’t work. Nobody seemed to need them—especially for current Greek. If you need them, please send a message to the mailing list to extend this.
  
==Fonts==
+
=Fonts=
  
 
Since fonts with polytonic Greek also contain monotonic glyphs and fonts with polytonich glyphs are much more scarce, here are some fonts that contain polytonic Greek:
 
Since fonts with polytonic Greek also contain monotonic glyphs and fonts with polytonich glyphs are much more scarce, here are some fonts that contain polytonic Greek:
  
 
* [https://greekfontsociety-gfs.gr/typefaces The Greek Font Society] publishes many high–quality Greek typefaces.
 
* [https://greekfontsociety-gfs.gr/typefaces The Greek Font Society] publishes many high–quality Greek typefaces.
 +
* [https://github.com/notofonts/noto-fonts Noto Fonts] include extended Greek for Noto Serif, Noto Serif Display, Noto Sans and Noto Sans Mono.
 +
* [https://github.com/adobe-fonts/source-sans/releases/latest Source Sans 3] includes polytonic Greek.
  
==Footnotes==
+
=Footnotes=
  
 
[[Category:Old_Content]]
 
[[Category:Old_Content]]
 
[[Category:Languages]]
 
[[Category:Languages]]

Revision as of 16:39, 22 January 2023


TODO: Please add fonts that contain polytonic Greek to the last section! (See: To-Do List)


Introduction

Historically, the development of Greek language can be divided in:

  • Ancient and Medieval Greek (–1453): language identifier is grc.
  • Modern Greek (1453–): language identifiers are ell, ell or gre

This is different from the main two ways of writing Greek:

  • Monotonic (or single–accented): diacritical marks are only the acute accent (or simply the accent) and the diairesis.
  • Polytonic (or multiple–accented): diacritical marks are three accents (acute, grave and circumflex) and two breathings (rough and smooth).

After a long development,[1] monotonic orthography became law in 1982.[2] Greek was polytonic before and ancient Greek is polytonic because it was before 1982.[3] This means that polytonic Greek is not only ancient Greek, since the main part of modern Greek was polytonic.

Unicode

Monotonic Greek needs the characters from the “Greek and Coptic” Unicode block (only the Greek part of it, not the Coptic part).

Polytonic Greek also needs the characters from the “Greek Extended” Unicode block.

All you need is to choose the proper font that contains the characters you require.

Just in case you wonder, there are much more fonts that contain glyphs for monotonic Greek that for polytonic Greek.

Monotonic and Acute Accent

Although the monotonic accent was acute, Unicode defines a pair of characters for monotonic accented vowels and polytonic acute accented vowels (both uppercase and lowercase and with diairesis).

These are the different characters in lowercase:

ά έ ή ί ΐ ό ύ ΰ ώ
ά έ ή ί ΐ ό ύ ΰ ώ

In theory, both characters should have the same glyphs (they should be exactly the same strokes). In practice, this is not always the case, since the monotonic accent has been drawn as (almost) a vertical stroke.

The acute accent should mirror the grave accent (it is mainly its horizontal flip). Although acute accented vowels in polytonic Greek could be taken from the Greek and Coptic Unicode block, acute–accented vowels from the polytonic block may be required (because of the mismatch between the monotonic accent and the grave accent).

The following source displays the differences for each character with both accents (uppercase and lowercase characters):[4]

\definefontfamily[mainface][rm][Minion Pro]
\setupbodyfont[mainface]
\definecolor [tred]  [r=1,t=.5,a=1]
\definecolor [tblue] [b=1,t=.25,a=1]
\unexpanded\def\tonosoxia[#1][#2]
  {\startTEXpage[pagestate=start, offset=1ex]
    \startoverlay
      {\color[tred]{#1}}
      {\color[tblue]{#2}}
    \stopoverlay
   \stopTEXpage}
\starttext
\tonosoxia[Ά][Ά]
\tonosoxia[Έ][Έ]
\tonosoxia[Ή][Ή]
\tonosoxia[Ί][Ί]
\tonosoxia[Ό][Ό]
\tonosoxia[Ύ][Ύ]
\tonosoxia[Ώ][Ώ]
\tonosoxia[ά][ά]
\tonosoxia[έ][έ]
\tonosoxia[ή][ή]
\tonosoxia[ί][ί]
\tonosoxia[ΐ][ΐ]
\tonosoxia[ό][ό]
\tonosoxia[ύ][ύ]
\tonosoxia[ΰ][ΰ]
\tonosoxia[ώ][ώ]
\stoptext

Depending on your operative system and your keyboard layout for polytonic Greek, it might be that it composes the acute with the monotonic accent (as it seems to happen in Linux).

A workaround to avoid this would be the following:[5]

\startluacode
fonts.handlers.otf.addfeature {
    name = "tonosoxia",
    type = "substitution",
    data = {
        Alphatonos = "Ά",
        Epsilontonos = "Έ",
        Etatonos = "Ή",
        Iotatonos = "Ί",
        Omicrontonos = "Ό",
        Omegatonos = "Ώ",
        Upsilontonos = "Ύ",
        alphatonos = "ά",
        epsilontonos = "έ",
        etatonos = "ή",
        iotatonos = "ί",
        iotadieresistonos = "ΐ",
        omicrontonos = "ό",
        omegatonos = "ώ",
        upsilontonos = "ύ",
        upsilondieresistonos = "ΰ"
        },
    }
\stopluacode

\definefontfeature[tonosoxia][tonosoxia=yes]

\definefontfamily
    [mainface]
    [rm]
    [EB Garamond]
    [features={default, tonosoxia}]

\setupbodyfont[mainface, 24pt]

\startTEXpage[offset=1em]
χαλεπὰ τὰ καλά\\
\feature[-][tonosoxia]
χαλεπὰ τὰ καλά\\
\stopTEXpage

The sample above should display the difference between the more straight monotonic accent on the second line, and the proper acute accent.

On “Character Normalization”

Depending on your search, it might be that searching for u, results might include ú ů, ü or any character composed from u and any diacritical mark. Depending on the language, these “normalizations” may belong to the same letter or not (for example, u and ü are the same letter in Spanish, but two different ones in German).

This doesn’t only affects to letters: , and are the characters for the comma and the opening single–quotation mark (used in some languages, such as German), respectively. At least, Firefox only displays the occurrences for each character when the option to match diacritics is selected (otherwise, each character displays both occurrences for commas and these opening single–quotation marks).

At least in Linux (using Firefox), the option to match diacritics doesn’t distinguish between monotonic and acute accented vowels. In other operative systems and using other programs, results might differ.

Ancient Greek

\agr or \ancientgreek are the values for ancient Greek hyphenation patterns.

A minimal sample would read:

\mainlanguage[agr]
\setupbodyfont[dejavu]
\startTEXpage[offset=3em]
\input aristotle-grc
\stopTEXpage

Monotonic Greek

Either as \mainlanguage or \language, right values are gr or greek.

A minimal sample would read:

\mainlanguage[gr]
\setupbodyfont[dejavu]
\startTEXpage[offset=3em]
Κάθε άνθρωπος δικαιούται να επικαλείται όλα τα δικαιώματα και όλες τις ελευθερίες που προκηρύσσει η παρούσα Διακήρυξη, χωρίς καμία απολύτως διάκριση, ειδικότερα ως προς τη φυλή, το χρώμα, το φύλο, τη γλώσσα, τις θρησκείες, τις πολιτικές ή οποιεσδήποτε άλλες πεποιθήσεις, την εθνική ή κοινωνική καταγωγή, την περιουσία, τη γέννηση ή οποιαδήποτε άλλη κατάσταση.

Δεν θα μπορεί ακόμα να γίνεται καμία διάκριση εξαιτίας του πολιτικού, νομικού ή διεθνούς καθεστώτος της χώρας από την οποία προέρχεται κανείς, είτε πρόκειται για χώρα ή εδαφική περιοχή ανεξάρτητη, υπό κηδεμονία ή υπεξουσία, ή που βρίσκεται υπό οποιονδήποτε άλλον περιορισμό κυριαρχίας.
\stopTEXpage

Modern Polytonic Greek?

Before 1982, Greek orthography was mainly polytonic. In fact, modern[6] Greek orthography was mainly polytonic.

Hyphenation rules for polytonic Greek differ from both ancient or monotonic Greek.

TeX has hyphenation patterns for ancient Greek, monotonic Greek and modern polytonic Greek.

ConTeXt has patterns for ancient and monotonic Greek only.

Language–Dependent Commands

As of current latest (2023.01.15 14:04), language–dependent commands—such as \currentdate—don’t work. Nobody seemed to need them—especially for current Greek. If you need them, please send a message to the mailing list to extend this.

Fonts

Since fonts with polytonic Greek also contain monotonic glyphs and fonts with polytonich glyphs are much more scarce, here are some fonts that contain polytonic Greek:

Footnotes

  1. For historical background, see https://en.wikipedia.org/wiki/Greek_language_question. This reference contains the recommendation for the article from the German Wikipedia.
  2. See Law 1228/1982 and Decree 297/1982. Both legatl texts were written with polytonic orthography, but they contain the provisions for the monotonic system.
  3. Just in case you may wonder, this is independent from the popular (δημοτική) v. purified (καθαρέυουσα) dispute for Greek language. See Law 309/1976. The legal text was written in the purified Greek, but it ordered the popular Greek to be the official language.
  4. Of course, you should replace Minion Pro with the name of the font you want to test.
  5. Although the ConTeXt distribution seems to include the EB Garamond font family, it is probably not included in the wiki.
  6. As historical term, modern refers to the period that begins after the Middle Ages.