[XeTeX] Localized XeLaTeX / greek XeLaTeX
Alexandros Gotsis
gotsis at science.tuc.gr
Fri Oct 15 14:51:02 CEST 2010
Dear friends,
1.
It was not my intention to generate all this discussion on the subject, a discussion that reached out even to religious arguments and polemics on linguistic imperialism. My point was rather simple: I think it will be easier to persuade Electra, my nine year old daughter, to use XeLaTeX rather than MSWord to type her school reports if she can understand what she types (including the typesetting commands). So far I have been successful in writing a few .cls files that translate all the commands that she might need, and I used the translations etc. of xgreek.sty. Now I am able to open Texshop and write some text using the UTF-8 encoding, all in greek, without having to go back and forth from greek to latin keyboards or having to type some obscure (for her) english words (she is just beginning to learn english as a foreιgn language).
Well, almost successful! Because, in reality, in order to run the XeLaTex engine, the first line of the text flle has to be: \documentclass[...]{GreekArticle} or something like this (by the way greek names, such as άρθρο instead of "article", for the cls files seem to be acceptable in this command, at least for the Macintosh/XeLaTeX system). And then, even though I have changed the command \tabular into \πίνακας I have to go to the latin keyboard to specify the format of the columns "{c c l r}". I agree this is not a big deal, but without it I do not have a pretty solution.
2.
The \documentclass command is special among the commands in LaTeX. One can change all the others but this one cannot be changed, and without it the file will not be processed. It has been argued that it does not make sense to change it into a different language. But I remember until a few years ago we used some symbols (%!) in the very first line to indicate to Texshop which engine to use. An idea, then, could be to replace the word "\documentclass" with a group of symbols that are available in all keyboards, e.g. !@#$. That is, instead of "\documentclass[options]{GreekArticle}", we would use "!@#$[options]{GreekArticle}". Or to have a number of alternatives for this command (besides the original), all of which would be understood by the system; alternatives in latin script, greek script, cyrilic script, and, perhaps all the scripts that are written from left to right. Is this possible to be done without too much work? Where is the name of the command \documentclass defined. Could we define also these equivalent names there? How could we change the format file without destroying what there is already in it?
3.
Things like [htbclr] used to position minipages, boxes etc. are also annoying when writing in a non-latin script. Where are these defined in the XeLaTeX system? Is it possible to define other symbols (unicode characters) in addition to these? For the greek script I would suggest: h -> ε (epsilon), t -> ψ (psi), b -> χ (chi), c -> κ (kappa), l -> α (alpha), r -> δ (delta)
4.
When I mentioned "length units" I meant those used to position things in LaTeX and did not mean the physical (iso or english) units that are used in engineering or physics texts. Even in Greece, scientific or professional publications and texts use the standard (latin) symbols for these, such as m for meter, cm, mm, μm, V, N, MPa etc. When, however, length units are used internally by the typesetting system, such as in "\vskip 1 cm", then it would be much more elegant if the change of the keyboard could be avoided. For this useage, a nice solution would be to replace "cm" with e.g. "εκ" (small greek letter epsilon + small greek letter kappa; which are the first letters for the greek word "ekatosto" for centimeter). Similarly the relative length units "em" and "ex" can be replaced by ω (small omega), which is the widdest small letter in most greek fonts, and ο (small omikron), which has the standard height of the small greek letters without extending upwards or downwards. Since all units can take decimal values, then just one absolute and one relative unit might be sufficient (in each language!).
5.
The class files that I have written are all made in "english" and standard LaTeX using UTF-8 encoding and will "run" in any XeLaTeX system. What I tried to change was not the underlying system but only the interface that the greek user will see and use. Programming commands are not worth translating. Further, the users' commands in these files were added to the english commands, so that both can be used in the same document. A text file written using the greek commands would be difficult to be read by a non-greek, unless he/she has a look at the corresponding cls file.
Thanks again for your comments and support
Alexandros D. Gotsis
Technical University of Crete
I include a greek_localisation.tex file and the file GreekArticle.cls to give an idea of what I am talking about.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: greek_commands.tex
Type: application/octet-stream
Size: 7855 bytes
Desc: not available
URL: <http://tug.org/pipermail/xetex/attachments/20101015/46d7ec25/attachment.obj>
-------------- next part --------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: GreekArticle.cls
Type: application/octet-stream
Size: 1108 bytes
Desc: not available
URL: <http://tug.org/pipermail/xetex/attachments/20101015/46d7ec25/attachment-0001.obj>
-------------- next part --------------
More information about the XeTeX
mailing list