summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/generic/babel-greek/test-greek.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/generic/babel-greek/test-greek.tex')
-rw-r--r--Master/texmf-dist/doc/generic/babel-greek/test-greek.tex32
1 files changed, 22 insertions, 10 deletions
diff --git a/Master/texmf-dist/doc/generic/babel-greek/test-greek.tex b/Master/texmf-dist/doc/generic/babel-greek/test-greek.tex
index 7d0d3c2b22c..75db933b4f0 100644
--- a/Master/texmf-dist/doc/generic/babel-greek/test-greek.tex
+++ b/Master/texmf-dist/doc/generic/babel-greek/test-greek.tex
@@ -1,7 +1,16 @@
\documentclass[a4paper]{article}
-\usepackage{cmap} % fix search and cut-and-paste in Acrobat Reader
\usepackage[LGR,T1]{fontenc}
-\usepackage[utf8]{inputenc}
+
+% Xe/LuaTeX in 8-bit compatibility mode:
+% TODO: hyphenation in Greek text parts fails!
+\ifdefined \XeTeXrevision
+ \XeTeXinputencoding "bytes"
+\fi
+\ifdefined\luatexversion
+ \usepackage[utf8]{luainputenc}
+\else
+ \usepackage[utf8]{inputenc}
+\fi
% \usepackage{textalpha}
\usepackage{textcomp}
\usepackage{hyperref,bookmark}
@@ -14,13 +23,12 @@
\usepackage[greek,english]{babel}
% \languageattribute{greek}{polutoniko}
+\message{Latin encoding is \latinencoding}
\DeclareTextCommandDefault{\ensuregreek}{\textgreek}
\begin{document}
-% \message{Latin encoding is \latinencoding}
-
\section*{Test the Greek support for Babel}
The babel option ``greek'' activates the support for the Greek language
@@ -52,13 +60,17 @@ 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.
-Switching between Latin and Greek script/font encoding is possible without
-switching the Babel language using the declarations \verb|\latintext|,
-\verb|\greektext| and the macros \verb|\textlatin|, \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.
+
+Switching to a font encoding supporting the Greek script is possible without
+switching the Babel 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:
-\greektext Φίλων τοῦ \textlatin{TeX} (ΕΦΤ) --
-\latintext Friends (\textgreek{F\'ilwn}) of TeX.
+\greekscript Φίλων τοῦ \textlatin{TeX} (ΕΦΤ) --
+\latintext Friends (\ensuregreek{F\'ilwn}) of TeX.
``greek.ldf'' has some workarounds, so that macros relying on Latin
characters in the ``right'' positions keep working. We test, that these