Cannot write Greek Polytonic in Linux

For up to date instructions for Greek and Greek Polytonic see How to type Greek, Greek Polytonic in Linux.

The following text is kept for historical purposes. Greek and Greek Polytonic now works in Linux, using the default Greek layout.

General Update: If you have Ubuntu 8.10, Fedora 10 or a similarly new distribution, then Greek Polytonic works out-of-the-box. Simply select the Greek Polytonic layout. For more information, see the recent Greek Polytonic post.

Update 3rd May 2008: If you have Ubuntu 8.04 (probably applies to other recent Linux distributions as well), you simply need to add GTK_IM_MODULE=xim to /etc/environment. Start a Terminal (Applications/Accessories/Terminal) and type the commands (the first command makes a backup copy of the configuration file, and the second opens the configuration file with administrative priviliges, so that you can edit and save):

$ gksudo cp /etc/environment /etc/environment.ORIGINAL
$ gksudo gedit /etc/environment

then append

GTK_IM_MODULE=xim

save, and restart your computer. It should work now. Try to test with the standard Text editor, found in Accessories.

In Ubuntu 8.10 (autumn 2008), it should work out of the box, just by enabling the Greek Polytonic layout.

Update 20th June 2008: If still some accents/breathings/aspirations do not work, then this is probably related to your system locale (whether it is Greek or not). It works better when it is Greek. If you are affected and you do not use the Greek locale, there is one more thing to do.

$ gksudo cp /usr/share/X11/locale/en_US.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose.ORIGINAL
$ gksudo cp /usr/share/X11/locale/el_GR.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose

The first command makes a backup copy of your original en_US Compose file (assuming you run an English locale; if in doubt, read /usr/share/X11/locale/locale.dir). The second command copies the Greek compose file over the English one. You then logout and login again.

End of updates

To write Greek Polytonic in Linux, a special file is used, which is called the compose file. There is a bit of complication here in the sense that the compose file depends on the current system locale.

To find out which compose file is active on your system, have a look at

/usr/share/X11/locale/compose.dir

Let’s assume your system locale is en_US.UTF-8 (Start Applications/Accessories/Terminal and type locale).

In the compose.dir file it says

en_US.UTF-8/Compose: en_US.UTF-8

Note that the locale is the second field. If you have a different system locale, match on the second field. Many people make a mistake here. Actually, I think be faster for the system to locate the entry if the compose.dir file was sorted by locale.

Therefore, the compose file is

/usr/share/X11/locale/en_US.UTF-8/Compose

So, what’s the problem then?

Well, for the Greek locale (el_GR.UTF-8) we have a different compose file, a compose file in which Greek Polytonic actually works ;-).

Therefore, there are numerous workarounds here to get Greek Polytonic working.

For example,

  • If you speak modern Greek, you can install the Greek locale.
  • You can edit /usr/share/X11/locale/compose.dir so that for your locale, the compose file is the Greek one, /usr/share/X11/locale/el_GR.UTF-8/Compose.
  • You can edit the Greek compose file, take the Greek Polytonic section and update the Greek Polytonic section of en_US.UTF-8/Compose.
  • You can copy the Greek compose file in your home directory under the name .XCompose. I did not try this one, and also you may be affected by this bug. (not tested)

Of course the proper solution is to update en_US.UTF-8/Compose with the updated Greek Polytonic compose sequences. There is a tendency to add the compose sequences of all languages to en_US.UTF-8/Compose, and this actually is happening now. In this respect, it would make sense to rename en_US.UTF-8/Compose into something like general/Compose.

Permanent link to this article: https://blog.simos.info/cannot-write-greek-polytonic-in-linux/

60 comments

Skip to comment form

    • George J. Georganas on September 15, 2007 at 09:07
    • Reply

    “the proper solution is to update en_US.UTF-8/Compose with the updated Greek Polytonic compose sequences”
    Well, maybe, but how is one to do it ?
    You seem to suggest that one had better wait since “this actually is happening now (8th August 2007)”. How do we know that it has happened (19th September 2007)? Can I somehow help with it ?
    Thanks.

  1. The part “and this actually is happening now” refers to the general tendency of not keeping individual compose files for each locale, but rather adding the compose sequences in the en_US.UTF-8 one.

    To help on this, you would need to file a bug report on
    https://bugs.freedesktop.org/
    with the information to change.

    For a background on what is needed, see
    http://www.nabble.com/%CE%A7%CF%81%CE%AE%CF%83%CE%B7-en_US.UTF-8-%CE%B1%CE%BD%CF%84%CE%AF-el_GR.UTF-8-%28Compose%29-tf3707226.html

    • George J. Georganas on November 17, 2007 at 07:06
    • Reply

    While waiting for the “proper solution”, I tried the workarounds.
    1. Changing the locale to Greek is not an option. Despite very courageous efforts by the Greek-speaking-and-writing computer scientists the result of this efforts reads like English, only with Greek words ! Thinking about computers is done in English and this cannot change.
    2.Editing “/usr/share/X11/locale/compose.dir so that for your locale, the compose file is the Greek one, /usr/share/X11/locale/el_GR.UTF-8/Compose” does not work, at least on its own (perhaps it works in combination with some other unknown changes to the system. Reading the post one substitutes the line “el_GR.UTF-8/Compose en_US.UTF-8” for the pre-existing line “en_US.UTF-8/Compose en_US.UTF-8″ in the /usr/share/X11/locale/compose.dir file in the twon instance in which this file occurs. This change produces no effect on a recent Debian installation. Great confusion results, if one tries to write in polytonic Greek. Trying aspiration marks, for example, produces a combining diacritical (perhaps the term is not right, I am not an expert) but no letter with aspiration mark.
    3.”edit the Greek compose file, take the Greek Polytonic section and update the Greek Polytonic section of en_US.UTF-8/Compose” is presented as the “proper solution” but is slow in coming. And it is no easy matter to combine a 5600-line long file with another that is 2000 lines long. Besides, who can guarantee that doing all this work will have any results ?
    4. “copy the Greek compose file in your home directory under the name .XCompose” is not recommended.
    The conclusion seems to be that open-source support for polytonic Greek is simply not available. Perhaps it is fairer to state this openly. It is interesting that most Google results regarding the matter state quite confidently that the problem of polytonic Greek has been solved in Linux. This does not seem to be the case.

  2. The proper solution should come early next year. It’s a bit of a technical issue and it will probably be uninteresting to lay out as a comment reply (rather than a new post).

    Re: 1.
    We are more than happy to receive suggestions/corrections. Open-source software is a development model that supports open participation. Your positive contribution can actually count in open-source software. You can’t beat that with other software!

    Re: 2.
    You hit on a bug that resulted from an attempt to fix a generic problem for all languages.

    Re: 3.
    That’s the thing we will be doing and sending upstream. The change is rather simple; from en_US.UTF-8 you replace a big chunk of text that is about Greek Polytonic with a big amount of text for Greek Polytonic from el_GR.UTF-8. By reading the documents you can figure out the portions for the Polytonic codepoints. Or just dump el_GR.UTF-8 onto en_US.UTF-8 (keep backup as always).

    Re: 4.
    Well, doesn’t hurt to try anyway.

    Understanding how these things work can help you with finding a workaround to make it work for now. The ultimate goal is get all these to work out of the box. For those literally unable to provide any technical help, we gladly accept friendly encouragement and feedback.

    The current state of Greek Polytonic writing support is summarised in the following links
    http://bugs.freedesktop.org/show_bug.cgi?id=13275
    http://bugs.freedesktop.org/show_bug.cgi?id=11930
    http://bugzilla.gnome.org/show_bug.cgi?id=321896

    • George J. Georganas on November 17, 2007 at 19:34
    • Reply

    Thank you for your prompt response. Also, for agitating eagerly to get this issue resolved.
    I am more than happy to wait for the proper solution.
    The alternative offered by self-proclaimed commercial software in the particular area of polytonic Greek support cannot offset the overall quality-control problem of that software. In particular, the language problems in that software are much more acute than in open-source software.
    My only worry is that we might be barking up the wrong tree, that is, correcting the Compose file for en_US_UTF-8 (possibly changing the name, too) and discovering that the change produces no effect. Can you confirm that correcting the Compose file actually solves the problem. Is an experimental corrected file available for testing anywhere ?

  3. The main problem with polytonic greek is that we need to have in sync two separate files which are managed by different projects. Those are the Compose file (part of Xorg) and the keyboard layout file (part of the xkeyboard-config project).

    Although there is a compose file named en_US.UTF-8, there is an effort to get that file used by most languages. Thus, compose sequences are being added in there. For Greek, it is sort of an exception to have our own el_GR.UTF-8. What this means is that if those two files are not the same, then a user without the Greek locale enabled will not be able to use any additional compose sequences in el_GR.UTF-8.
    That is the reason we need a common compose file (let’s call it CommonCompose.UTF-8), so that it does not matter what is your session locale; it should work all the same.

    I am not sure what is the state of your installation, where you have back-ups of different files. It should be quite easy to put a pair of the compose file and the keyboard layout file so that it works for now.

    Sadly, Greek Polytonic is a bit exotic, and very few people chip in to make it work by default.

    • George J. Georganas on November 18, 2007 at 09:17
    • Reply

    So one needs to intervene in two files : “the Compose file” and “the keyboard layout file”. Is it safe to assume that the second is set by setting the keyboerd to Greek Polytonic ?
    I am tempted to try a new Compose file, along the lines you suggest, keeping, of course a backup of the present Compose file. I will post on the outcome.

  4. The controlling file (second) on my system is located at
    /usr/share/X11/xkb/symbols/gr

    The relevant section for Greek Polytonic is

    partial alphanumeric_keys alternate_group
    xkb_symbols “polytonic” {

    include “gr(extended)”

    name[Group1] = “Greece – Polytonic”;

    key.type[Group1] = “THREE_LEVEL”;

    key { [ dead_tilde, dead_diaeresis, dead_macron ] }; // 34 or [
    key { [ dead_iota, VoidSymbol, dead_breve ] }; // 35 or ]

    key { [ dead_acute, U0313 ] }; // 47 or ;
    key { [ dead_grave, U0314 ] }; // 48 or ‘

    };

    In the Compose file, when you see a line such as
    : “ἄ” U1f04

    this means that you press in sequence
    1. Shift+; (U0313 is at the second column, so it’s Shift+key)
    2. ;
    3. α

    and the compose sequence matches, and you get ἄ.

    Thus, you can copy the Greek compose file on top the Generic(English)

    sudo cp /usr/share/X11/locale/en_US.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose.ORIGINAL
    sudo cp /usr/share/X11/locale/el_GR.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose

    and make sure that the keyboard layout section in file “gr” matches and looks like the part shown above.

    • George J. Georganas on November 19, 2007 at 06:11
    • Reply

    I noticed some seemingly trivial differences in my /usr/share/X11/xkb/symbols/gr file. The relevant section reads thus :

    partial alphanumeric_keys alternate_group
    xkb_symbols “polytonic” {

    include “gr(extended)”

    name[Group1] = “Greece – Polytonic”;

    key.type[Group1] = “THREE_LEVEL”;

    key { [ dead_tilde, dead_diaeresis, dead_macron ] };
    key { [ dead_iota, VoidSymbol, dead_breve ] };

    key { [ dead_acute, U0313 ] };
    key { [ dead_grave, U0314 ] };

    };

    But I went ahead and copied the /usr/share/X11/locale/el_GR.UTF-8/Compose file onto the /usr/share/X11/locale/en_US.UTF-8/Compose file.

    It made no difference. Same symptoms upon attempting to write polytonic in OpenOffice Writer.

    • George J. Georganas on November 19, 2007 at 06:24
    • Reply

    Including the seemingly trivial changes in the /usr/share/X11/xkb/symbols/gr file produces an error upon login as follows :
    QUOTE
    Error activating XKB configuration.
    It can happen under various circumstances:
    – a bug in libxklavier library
    – a bug in X server (xkbcomp, xmodmap utilities)
    – X server with incompatible libxkbfile implementation

    X server version data:
    The X.Org Foundation
    70101000

    If you report this situation as a bug, please include:
    – The result of xprop -root | grep XKB
    – The result of gconftool-2 -R /desktop/gnome/peripherals/keyboard/kbd
    UNQUOTE
    and disables the Greek keyboards. They are probably not loaded at all.

    • George J. Georganas on November 19, 2007 at 06:52
    • Reply

    More bad news !
    Even changing the locale to Unicode Greek does not allow one to write in polytonic Greek.
    I stronly suspect that the problem is as yet undiagnosed and, therefore, that one should not expect it to be resolved any time soon. Please remember that I have been testing those workarounds on a fairly recent Debian Etch installation.

    • George J. Georganas on November 19, 2007 at 09:51
    • Reply

    I am not the only one to have noticed :
    http://mail.nl.linux.org/linux-utf8/2006-01/msg00005.html
    The issue has been raised almost two years ago, if not earlier !
    Perhaps it would be a good idea to edit the proposals for the workarounds, to reflect the fact that they do not always work.
    I actually tend to conjecture that there does not exist even one person who regularly types polytonic Greek in Linux.

  5. Thanks for testing all these out.

    1. You mention there is a difference between mine and your “gr” file. Could you pinpoint the difference? It is not apparent to me.
    In my version of the “gr” file I put a few short comments at the end of the layout lines that say which keyboard key they affect. It is the part that starts with //. I am not sure if comments are not supposed to appear at the end of lines; you may remove them.
    You need to logout/login for the system to get updated.
    When the system asks you whether to use the “Xorg” or “GNOME settings”, choose the latter.
    2. GTK+ applications using the so-called GTK+ IM (default) do not support polytonic yet. What this means is that you need to change this system-wide from GTK+ IM to XIM. This is a temporary change that will not get fixed soon. I am working on this but it is quite a complicated task. To test this part, open a Terminal (Applications/Accessories/Terminal) and type

    $ export GTK_IM_MODULE=xim
    $ oowriter

    and test Polytonic support.

    • George J. Georganas on November 19, 2007 at 21:53
    • Reply

    Thank you for your patience and persistence.

    The differences in the gr files are in the comments, so there is no need to dwell on the matter any more. Of course logout/login is necessary to get the system updated.
    Here is what I did in response to your latest post :
    a. I copied the /usr/share/X11/locale/el_GR.UTF-8/Compose file onto the /usr/share/X11/locale/en_US.UTF-8/Compose file.
    b. I logged out and back in
    c. I opened a Terminal and typed
    $ export GTK_IM_MODULE=xim
    $ oowriter
    Wow ! It worked. It even worked in other openoffice applications opened after the oowriter got going.
    Not for long though ! the setting must be repeated for another application, say gedit. For Iceweasel, it does not work at all.
    Still, the fact that polytonic can be written in Linux, even after considerable hassle is a sign of progress. We are not, is seems, barking up the wrong tree, after all. Let us hope we see the remaining problems addressed soon.

  6. I am glad it worked on your system.
    To make the GTK_IM_MODULE setting permanent, you need to add the following line into /etc/environment

    GTK_IM_MODULE=xim

    and restart.

    There are specific issues regarding Greek Polytonic that some input would be beneficial.
    For example,
    a. Between the keyboard layouts for Greek Polytonic and Modern Greek, the key for dialytika is different. I feel that this is not a good thing. Should this be fixed or stay as is?
    b. Are there any suggestions regarding the choice of the “dead” keys for Greek Polytonic; Currently, a “three level” mechanism is used to input the dead keys. You can press the dead key as is, with Shift, with Alt. Is it ok as is?

    • George J. Georganas on November 20, 2007 at 06:25
    • Reply

    Yes ! The module setting is permanent and works even for the browser.
    How do I get permission to post the consolidated instructions on the net ? I believe they can be very helpful to many people who, like me, search in vain for a long time

    The overall philosophy of effectively integrating the polytonic and monotonic keyboards, as illustrated by the two examples of issues is, I believe, a very sound one, both from the practical and the ideological point of view. After all, Greek is the only language that has come to us from antiquity in a form that can be recognised, if imperfectly, by its current-day native speakers.

    So, diairesis (the standard name all over the world, except in Greek schools, where it would be confused with “division” and thus led teachers to use the misleading term “dialytika”) must, if at all possible, be on the same key as “dialytika”.

    As far as I can see, Alt duplicates the action of the dead key. Unless, it meets a specific purpose, duplication is not a good thing.

  7. There is some documentation at
    http://planet.ellak.gr/misc/polytonic/ (requires OpenOffice.org).
    If you are interested, feel free to take the document and update it with the information you deem useful for a person working on Greek Polytonic. If you would like to maintain a Greek Polytonic-Linux page, you are free to take over the hosting of the document.

    “Alt” is used to provide more dead key options. According to

    key { [ dead_tilde, dead_diaeresis, dead_macron ] };

    When you press “;”, you get “dead_tilde”.
    When you press Shift+; you get “dead_diaeresis”.
    when you press Alt+; you get “dead_macron”.
    This requires one physical key for three dead_xxxxx, so it is good (saves physical keys).
    For the current Greek polytonic we need to map 9 dead_xxxxx
    Without Alt, we would need to sacrifice 5 keys (2×5=10 >= 9).
    Ideally, it is possible to also possible to use Shift+Alt+dead_xxxx as well, though it might be cruel to users.

    The names “dead_diaeresis”, “dead_tilde”, etc, are sort of reused from other layouts. Their name should not be taken face value. Just recently the proposal to get a “dead_psili” has been approved, which would make the configuration files a bit easier to understand. The dead_xxxx keys are like variables for matching in compose sequences in the Compose file.

    • George J. Georganas on November 20, 2007 at 18:17
    • Reply

    So Alt is there for a specific purpose. Why change, then ? For the bulk of one’s writing the frequently occuring key combinations are intuitively obvious as they stand. The more esoteric combinations cannot hope to be as prominent on the keyboard.
    I can see that the documentation needs updating. However, my knowledge in this field is at a very amateur level, as you will have already guessed. I was thinking of posting in some forums that have some readership and in which I have seen the matter raised.

    • Guido C. on November 21, 2007 at 22:34
    • Reply

    Your post seems really clear to me, nonetheless I tried to fix the issue on my ubuntu gutsy box to no avail. I hope you can give me some more help. This is what I did in short:

    sudo cp /usr/share/X11/locale/el_GR.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose
    restarted x
    $ export GTK_IM_MODULE=xim
    tried (using Dejavu sans) both in ooffice and in gedit, but did not work.

    • George J. Georganas on November 22, 2007 at 08:46
    • Reply

    Well, here are my consolidated instructions :

    START

    Polytonic Greek under LINUX (Debian Etch)
    monotonic, too !

    1. Install Greek polytonic keyboard :

    2. Open a root terminal and copy the file :
    /usr/share/X11/locale/en_US.UTF-8/Compose
    into a backup file :
    usr/share/X11/locale/en_US.UTF-8/Compose.ORIGINAL.
    using the command :

    sudo cp /usr/share/X11/locale/en_US.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose.ORIGINAL

    3. Continue in root terminal and copy the file :
    /usr/share/X11/locale/el_GR.UTF-8/Compose
    containing the correct polytonic settings onto the file :
    /usr/share/X11/locale/en_US.UTF-8/Compose
    containing the incorrect ones using the command :

    sudo cp /usr/share/X11/locale/el_GR.UTF-8/Compose /usr/share/X11/locale/en_US.UTF-8/Compose

    4. Add the line :

    GTK_IM_MODULE=xim
    to the file /etc/environment and save it.

    5. logout/login

    END

    Two things that may be different. First, there may be a difference between Ubuntu and Debian, a small but significant difference. Second, the restarting of X must be done after one edits the /etc/environment file and puts the line “GTK_IM_MODULE=xim” (without the quotation marks, of course) in it.
    How about testing it ?

    • fipm on November 23, 2007 at 11:46
    • Reply

    For future reference, at least on my ubuntu 7.10 exporting GTK_IM_MODULE=xim from the terminal was not enough, but adding it to /etc/environment did the trick.

    Thanks

    • sjoerd222 on February 25, 2008 at 12:27
    • Reply

    Thanks for your solution. I am about to test it on Fedora 7.
    You said you want to maintain a site about this issue and work for a better integration of polytonic greek into Linux.
    Does this page exist now?

  8. @sjoerd222: I do not have a page setup yet; I provide updates in my blog at the moment. If you add these RSS feeds in your RSS Reader, then you should be able to have a good overview of the status.

    The instructions above will be useful for Fedora7. New distributions that will come in the next few months will have a small fix, with the addition of dead_dasia/dead_psili. Hopefully, things will continue to work well.

    Regarding GTK+ and Greek Polytonic, this fix will go in in the next version of GNOME (new distributions coming in Autumn). What this means is that after this fix, Greek Polytonic will work out of the box for any GNOME-based distributions.

    • rizitis on March 16, 2008 at 17:43
    • Reply

    “For future reference, at least on my ubuntu 7.10 exporting GTK_IM_MODULE=xim from the terminal was not enough, but adding it to /etc/environment did the trick.”

    how can i also add it to my “/etc/environment”, becouse from the terminal its not enough on my ubuntu 7.10 too…

  9. You add GTK_IM_MODULE=xim to /etc/environment with the command

    $ gksudo cp /etc/environment /etc/environment.ORIGINAL
    $ gksudo gedit /etc/environment

    then add

    GTK_IM_MODULE=xim

    save, and restart your computer. It should work now.

    If you are adventurous, you can “fix” your distribution for now by following the instructions at
    http://simos.info/blog/archives/661

    Distributions that will appear in autumn 2008 should have the support for Greek Polytonic available by default.

    • rizitis on March 17, 2008 at 21:17
    • Reply

    well I am only for a week Linux user so I still thinking as Bill learn me for 8 years…

    I command $ gksudo cp /etc/environment /etc/environment.ORIGINAL
    $ gksudo gedit /etc/environment

    then I add

    GTK_IM_MODULE=xim

    I saved, and restart but the first time it didn’t work.
    the I thought that I have to accept the rename of the language as a window asked me, but when I did it all the programmes change language from Greeks to English. any way it still didn’t work.
    so I command the same things again but went I was in the /etc/environment
    I clean up the line “GTK_IM_MODULE=xim” , save and restart again , accepted the change of the new language so my ubuntu return to Greek language again.

    dont loose any time for me again, maybe i need few months for practice first and then i will come back for questions…
    THANK YOU.

  10. @rizitis: If you know about IRC, you can install “xchat” (from Add/Remove Packages). Then, you can connect to the Freenode IRC network, and join the friendly #ubuntu-gr channel.

    Over there, you can ask for a walk-through for the commands I describe in the comment above.

    The command

    gksudo cp /etc/environment /etc/environment.ORIGINAL

    will make a backup copy of the file /etc/environment. If you already have a backup file, then it will ask you whether to overwrite.

    The next command opens the file in an editor so that you can make the change.

    The default contents of /etc/environment are

    PATH=”/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games”
    LANG=”el_GR.UTF-8″
    LANGUAGE=”el:en”

    By adding the special line I mentioned above, the file becomes

    PATH=”/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games”
    LANG=”el_GR.UTF-8″
    LANGUAGE=”el:en”
    GTK_IM_MODULE=xim

    You save and restart (not logout, but restart the whole system).

    • rizitis on March 18, 2008 at 00:02
    • Reply

    ok! thanks again!

    • John Vliouras on April 9, 2008 at 19:01
    • Reply

    Hi,

    Having read your article and comments about Greek polytonic in Linux and bearing in mind that I am a newbie in computers or rather illeterate as I call myself,you might be interested in the following:

    I have a amd64 machine with various Linux distros, the only OS system that I know about. I tried to install Kerkis polytonic fonts and using their instructions I was successfull with the following three distros:

    64Studio (Debian etch )
    Ubuntu 7.10 Studio
    Jacklab 1.0 ( based on suse10.1 )

    I have polytonic fonts in all three, using OOo on the first two ( I installed OOo in 64Studio as extra ) and abiword as the default word processor of the third. I white beautifully and easily, better than with the Greek typewriter.

    I installed same but could not use tones properly in:

    Ubunt 7.10
    Blag 70000 ( based on Fedora core 7 )
    Debian etch
    Mandriva 2008.0
    Fedora 8
    Centos 5

    So it is interesting to note that Ubuntu 7.10 does not support Kerkis polytonic but Ubuntu 7.10 Studio does.

    Blag and Sidux have locale-us and reading your comments/instructions I will try to substitute it with
    the locale-el as soon as possible. Presently I cannot enter in Sidux as root for some reason to apply the changes, Did not try with Blag yet.

    I hope this is of some inerest to you.

    Regards

    borgibo super newbie.

  11. @John:

    First of all, Kerkis is a Unicode font, therefore there is no issue of having or not support in Linux for Greek Polytonic. Any Unicode Greek Polytonic font works in Ubuntu Linux.

    There is an issue specific to OpenOffice.org; currently, OpenType fonts are not (well?)-supported. Therefore, if you want to use the Kerkis fonts, please use the TTF version instead of the OTF ones.

    Ubuntu comes by default with Unicode Greek Polytonic fonts, in particular with DejaVu Sans (default font, also shown as “Sans”), and MgOpen Canonica (http://www.ellak.gr/fonts/mgopen/).

    To type those accents in Greek Polytonic, you need to configure the Greek Polytonic keyboard. I suppose you have done this already.

    GTK+ applications (all Ubuntu applications, including Firefox, OpenOffice.org) have currently a deficiency with regards to typing. You cannot type accents by default, and this is something that has been fixed for Ubuntu 8.10 (any distribution coming in autumn 2008).

    For now, there are several workarounds. The easiest is to edit your “/etc/environment” configuration file, as described above, in previous comments. I believe you should be able to accomplish that, since you have so many distros on your system ;-). Good luck!

    • papa-Tychon on May 3, 2008 at 09:16
    • Reply

    Hi,

    Maybe anybody nows how to activate and configure the Greek Polytonic in Freespire Linux OS? I tried to configure that like in Ubuntu, but some things looks in Freespire different and I’m beginner in Linux. I want to change for many reasons my WinOS to Linux and a Freespire seems a little bit more user-friendly and compatible than other distros of Linux (I have used a Windows OS for 10 years), but without Greek Polytonic support is every OS useless for me.

    Can anybody guid me?

  12. @papa-Tychon: According to http://www.freespire.org/, Freespire 2.0 is based on Ubuntu 7.04, so it should be similar to what is said here. There is a chance however that the system enabled “SCIM”, which would mess up what we describe here.

    If you could try out Ubuntu 8.04, then is should work with minimal changes. See the update at the post above.

    • papa-Tychon on May 3, 2008 at 13:27
    • Reply

    Thank You, Simos! I now, that the Freespire 2.0 is based on Ubuntu 7.04. The problem is, that it is quite modified (probably the enabled SCIM one)and I do not find the “/etc/environment” at all. Also it don’t recognize terminal commands said here. I prefered the Freespire beceause the better driver support (I have a laptop and I’m travelling often). What about Ubuntu 8.04?

    To Simos:
    Xristos Anesth! Mhpws eiste xrhsths tou Skype h yparxei kanena analogo ellhniko forum?

  13. @papa-Tychon: Alithos Anesti!

    If there is no /etc/environment, you can either put the special line in a different file, and it will have the same effect.

    a. Click on Applications/Accessories/Terminal
    b. Type gedit ~/.bashrc and press Enter.
    c. Add at the end of the file the command

    export GTK_IM_MODULE=xim

    d. Save and close the program
    e. Logout and login.

    The above commands will work and enable full Greek Polytonic in Ubuntu 8.04. With Ubuntu 7.04 you might not be able to put daseia, but try it anyway and tell me.

    There is a Greek Ubuntu mailing list, at
    http://www.ubuntu-gr.org/ (see the tab which says Λίστα to subscribe).
    If you have any questions, it is usually easier to help from the mailing list.
    An alternative communication of our Ubuntu-gr community is with IRC (like chatting).
    For details, see
    http://wiki.ubuntu-gr.org/Wiki/Community/IRC

    • John Vliouras on May 3, 2008 at 19:06
    • Reply

    @Simos Xenitellis

    Further to my post of April 9 above, I am glad to inform you that I applied sucessfully yours and George J Georgantas’s instructions (23 Noovember 2007) and I have the following, which might as well answer today’s papa-Tychon “and I do not find the “/etc/environment” at all”, comment.

    First some information about my P/Cs: P/C nr one, I will call it “box a”, is a amd64 3800+ 2GH dual core 2x1GB ram dual channel.

    p/C nr two or “box b”, is a Celeron dual core 1.6 GH 2×500 MB ram dual channel.

    Both boxes support 32bit software and 64 bit.

    This information “to whom it may concern” as the results are quite whimsical ! The fonts I experimented with are only a small portion of the ones available.

    Debian etch 64 bit in box-a: will type perfectly in Open Office writer: Kerkis, Thryomanes, DejaVu Sans, FreeSerif,MgOpen Canonica and Nimbus Roman No9 L, but will print only the first. My printer is a LexmarkE250d used as Generic PCL5e with hpijs driver.

    Debian etch but 32 bit in box-b: will type perfectly in OOw:Kerkis, Gentium, FreeSerif, MgOpen Canonica,Thryomanes,DejaVu Sans,MgOpen Cosmetica and Nimbus Roman No9 L, but will print only the first 5 ones.

    64Studio (based on Debian etch)64bit in box-a: which was one of the 3 that whould function with Kerkis although I had not entered in any the magic “GTK_IM_MODULE=xim”, (my post April 4), now writes and prints in OOw Kerkis and Thryomanes ( my favourite font ).

    The above had locale el by default.( To find out just print in terminal as user or root “locale” hit enter. )

    The last OS that I played with up to now, Sidux, had/has locale US, so I followed Georgantas’s instructions, except the placement of the magic GTK_IM_MODULE=xim line, which went as “export GTK_IM_MODULE=xim” in /etc/profile as I could not find in Sidux the /etc/environment file, using Kerkis instructions here:
    http://iris.math.aegean.gr/%7Eatsol/linux-tips/index.html#how-to-write-polytonic

    Sidux 64bit in box-b: will type in OOw Kerkis, Alexander (another of my favaurite fonts ), Bitstream Vera Sans, DejaVu Serif, FreeSerif ( a nice font also ) MgOpen Cosmetica, Nimbus Roman No9 L,and Aegyptus: will print all but the last one.

    So this is my story, will come back with more in the next days, and as a newbie in computers I find it utterly illogical by human standards, such computer behaviour !

    Regards,

    borgibo the illiterate

  14. @John Vliouras: Some pieces of info one items you mention.

    a) Aegyptus does not print; I believe this has to do with the fact that Aegyptus is an OpenType font, and you are trying to print from OpenOffice.org. Some combinations of fonts may cause problem at the moment, to be fixed (in OOo) in the near future.

    b) The work to fix Greek Polytonic has been done (I am not sure if you read my regular blog posts, see http://blogs.gnome.org/simos/ for some posts on Polytonic and GTK+). The issue is that by Ubuntu 8.10 (or any other distribution from fall 2008 and onwards, will work with Polytonic out of the box. You just select the Polytonic layout, and you will be able to type in GNOME, Mozilla, OpenOffice and so on. That’s the way it should be done.

    c) If I were to put effort with Polytonic, I would put it in creating content as in OpenOffice.org documents. We need documents, and especially to make them available online. If you see at http://simos.info/blog/archives/454 you will find a version of the Holy Bible in Greek Polytonic.

    • George J. Georganas on May 28, 2008 at 08:14
    • Reply

    I am reporting this here, as there may still be time to prevent a forthcoming problem.
    Debian unstable and Sidux both do not display aspiration marks or diairesis and they fail entirely to display characters with combined diacritics. Since those distros are supposed to foreshadow what comes next, we are in for a nasty surprise.
    It is interesting to report the experience with Sidux. Installing the latest ISO named «Νύξ» one does not have Polytonic Greek out of the box. However, by copying the Greek Compose file onto the US Compose file, one works around the problem. If one further proceeds to an “apt-get dist-upgrade” (through the command line as recommended by Sidux) one loses Polytonic Greek beyond recall. The usual workarounds do not work.
    One wonders whether the expected forthcoming improvement in Polytonic Greek support is going to be an improvement at all.

  15. @George G: If you go through this posts and the comments, it explains the process of how Greek works.
    I am not familiar with the details of Sidux, and which versions of the packages (xkeyboard-config/X.org) they have. Knowing these versions or the contents of the said files is good to figure out what’s going on.

    I may get to know this once Sidux packages land in Ubuntu, in a few months time.

    • George J. Georganas on May 30, 2008 at 04:14
    • Reply

    Thanks Simos !
    Can you confirm that the only packages affecting display or non-display Polytonic Greek are :
    xkeyboard-config
    and
    X.org ?
    I would like to try to trace the problem and report it in time, so that it does not land in Ubuntu.

  16. @George G: Indeed, those are the packages, xkeyboard-config (/etc/X11/xkb/symbols/gr), and X.org (whichever package provides /usr/share/X11/locale/*).

    However, on top of that, if the application is based on GTK+ (any GNOME application, Firefox, OpenOffice,org to name a few), then there is the issue of the GTK+ library. For this, see the comment at the top of the page; the work in the GTK+ library has been fixed and is available in the development version of GTK+). Effectively, GTK+ applications override the contents of /usr/share/X11/locale/* unless you get GTK_IM_MODULE=xim in /etc/environment.

    • George J. Georganas on June 2, 2008 at 06:05
    • Reply

    I have spent such free time as I got over the weekend trying to locate the problem. The exact symptoms are the following : Psili and Dasseia are not responding, either alone or in combination with other diacritics, while Hypogegrammeni and Diairesis combine perfectly with Oxeia, Bareia and Perispomeni, if not always grammatically, for instance in ῧ.
    The problem appears upon upgrading Debian Etch to Debian Lenny and persists in Sid. It must be a problem deep inside since both KDE anf GNOME have it.
    It must be simple to resolve, if only one could locate the developer. Since othe diacritics work and dasseia and psili don’t, it must be possible to fix it.

    • stelios chronopoulos on June 2, 2008 at 10:47
    • Reply

    I can only confirm exactly what G.J.Georganas says. I have the problem with Ubuntu 8.04.
    I would be grateful, if someone could propose a solution.

  17. @Stelios: You should be able to type Greek Polytonic in Ubuntu 8.04, when you do the workaround that is described at the very top of this post. I assume you have selected the Greek Polytonic keyboard layout from the Keyboard settings, can you confirm this?

    I can verify that on my vanilla Ubuntu 8.04 I am able to type Greek Polytonic,
    άὰἅἅᾅᾂΐᾴᾲ

    If you use Kubuntu (or QT-based application), you should be able to type Greek Polytonic without the need of the workaround.

    • George J. Georganas on June 2, 2008 at 14:17
    • Reply

    I have filed this bug report :
    http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=484076
    Let’s see what comes of it.

    • stelios chronopoulos on June 2, 2008 at 16:27
    • Reply

    Thank You very much for the repsonse.
    The workaround You propose works for everything except breathings (psile, daseia).
    But perhaps I have to try a little bit more, since I am a new user.

  18. @George, @Stelios: If psili and daseia do not work, then this is probably related to a change that took place in two different packages. If Debian has an older version of one of the two packages, you are not able to type dasia/psili.

    To figure out which versions you have, have a look at
    A. /usr/share/X11/xkb/symbols/gr

    My Ubuntu says

    key { [ dead_tilde, dead_diaeresis, dead_macron ] }; // ~ ¨ ¯
    key { [ dead_iota, VoidSymbol, dead_breve ] }; // ͺ ˘

    key { [ dead_acute, dead_horn ] }; // ´ ̓
    key { [ dead_grave, dead_ogonek ] }; // ` ̔

    This means that “dead_horn” and “dead_ogonek” are for dasia and psili respectively (or vice versa; I always confuse the two).

    There has been an update with the new definitions of dead_psili and dead_dasia, so your version of “gr” may have these. However, for those to be operational, your main X.Org needs to define dead_psili and dead_dasia. I believe that since Xorg 7.3 and newer, they define these.

    Then, the last piece of the puzzle. If your locale is el_GR.UTF-8, then see /usr/share/X11/locale/el_GR.UTF-8/Compose. Else, see /usr/share/X11/locale/en_US.UTF-8/Compose
    In there, you will notice the compose sequences for Greek Polytonic that mention either dead_ogonek/dead_horn or dead_dasia/dead_psili. What you get in the “gr” file has to be in agreement with what you see in the “Compose” file.

    I hope this helps.

    • George J. Georganas on June 3, 2008 at 04:46
    • Reply

    Simos, you are, as usual, dead_right ! Thanks again !
    A quick fix is to put dead_horn and dead_ogonek back into the /usr/share/X11/xkb/symbols/gr file. Then one restarts X and the aspiration marks work.

    The correct fix is, perhaps, to replace dead_horn and dead_ogonek with dead_psili and dead_dasia wherever they occur in Greek keyboard and Compose files. But this matter is for people more expert than I.
    The mess-up is due to a decision made , I think, by Alejandros Diamantidis a long time ago. He has explained the problem long ago, but the consequences are still with us.

  19. @George G: It’s great that it works for you!

    Upon closer inspection on Ubuntu 8.04, it shows that the recent changes (about Jan 2008) did not make it in the Ubuntu packages. What appears to have happened is that in the new Debian version, it gets the updated “gr” (xkeyboard-config) file with dead_psili/dead_dasia, however the “Compose” files did not get updated as well.

    Dead_psili and dead_dasia were added around Dec2007/Jan2008, and it appears they actually missed the release of X.Org 7.3(?).

    Until all files get in sync (and considering distributions/developers release at different schedules), we will have to put up with the bumpy ride ;-).

    • stelios chronopoulos on June 3, 2008 at 09:03
    • Reply

    Thanks a lot! It worked also for me, whereas the actual (final) problem, was that the definitions in the en_US file and those in the el_Gr were totally different.
    Thanks a lot once more. Some colleagues of me and of course myself are grateful.

    ps. If You are still interested, promoting Your idea about ancient greek texts in .odf fromat, and if You think I could help please let me know.
    e-mail: schronopoulos AT gmail.com

  20. It is great that it has worked for both of you.
    Considering that the “change” did not take place fully, this means that in the following months we have to keep in mind this issue and test that new distributions get it right.
    I have spent quite some time explaining this issue to end-users, it is good to have some more diverse testing effort in those various distributions.

    The GTK+ library maintains its own copy of the Compose file. I am taking care so that this copy is in sync with the upstream version. Some work I did on this (includes dasia/psili) will go into the next versions of the distributions coming in about 3 months time from now. Once this is in effect, we do not need to use the XKB_IM_MODULE=xim line (which effectively bypasses GTK and uses the stock X.Org Compose files). As long as xkeyboard-config defines dead_psili/dead_dasia, any GTK+ application will work out of the box.

    In addition to this, I am toying with the idea of merging the Greek Extended and Greek Polytonic keyboard layouts into a single, default keyboard layout for the Greek language. Users will still be able to use existing variants, however the default layout will fit for all. If you have this blog in your RSS feed, you should be able to get notice of the announcement.

    @stelios: I am all in getting more OpenDocument files to use Greek Polytonic. I can help with the technical side of writing Polytonic with less difficulty. However, I would need help with the promotion/dissemination of information on how to write polytonic.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.