House of Flesh (Yousef Idris)

In 2008, I translated the short story House of Flesh by Yousef Idris (Bayt min Laḥm, originally published in 1972) for a class project. To accompany the translation, I wrote a short paper introducing the work and its author. I did not consult the translation by Denys Johnson-Davies (cf. The Essential Yusuf Idris, AUC Press, 2009, pp. 219-225) until after I had completed mine; I found that comparing the two offers a useful illustration of the different approaches and strategies one can bring to a translation.

Arabic and Persian diacritics for Ubuntu keyboard

I’ll inaugurate my new site with a blast from the past. It may be useful for someone out there.

Some years ago, I started playing with Linux, specifically Ubuntu, and one thing I had to work at to get running was a good layout for Arabic and Persian transliteration. Some of the default international keyboards that come bundled with most Linux distribution carried most of the diacritics I need, but usually they were tucked away in awkward places and none of them included ayn and hamza, so I had to build my own layout. As far as I know, there are no easy GUI programs out there to create a custom layout; you just have to go in the old-fashioned way and edit the text file. Fortunately, it’s pretty simple. Each line begins with a code that defines the key; typically, this will be A (for alphanumeric), A-E (rows 1 to 5, bottom to top) 1-12 (key position in the row, going left to right). After the key is defined, you can offer up to four values, which will correspond with what the key will produce by itself, with Shift, with AltGr (usually the right Alt key), and Shift+AltGr respectively. So, for example, let us consider the following line:

key <AD07> { [ u, U, uacute, Uacute ] };

So from the code, we know that this key on the alphanumeric keyboard, fourth row from bottom, seventh from the left. If you found the letter “U”, good job. Now we see that by itself, it produces “u”, with Shift “U”, with AltGr “ú”, and with Shift+AltGr “Ú”. You can substitute these names with their Unicode equivalents; for example, the Unicode ID for “Ú” is U00DA, so you could erase “Uacute” and replace it with “U00DA” and get the same character. I did this when inserting my characters, simply because I didn’t know all their names and you can be absolutely precise when picking your character.

Installation: In Ubuntu, and I assume most Debian-based flavors of Linux (if not more), the keyboard layout files are located in /usr/share/X11/xkb/symbols. If you don’t find it there, look it up for your system and it should be fairly easy to locate. Now the first thing to do is decide which keyboard you want to modify. I chose the US “alternative international” keyboard, since ‘alternative’ is a good word to describe what we’re doing. First thing’s first, you’ll want to backup your keyboard, so in case you run into any problems, you can restore the original without any hassle. All this will have to be done through the terminal using the sudo command. Here are the steps you’ll go through:

  1. Open a terminal
  2. Type cd /usr/share/X11/xkb/symbols (or the appropriate directory)
  3. Type sudo cp us us_backup (this makes your backup)
  4. Type sudo gedit us (or choose your favorite text editor)
  5. Once the document is opened, search for “Alternative International” group (it was the third one down, for me)
  6. Highlight the text from partial alphanumeric_keys down to };
  7. Delete the text and copy the layout below in its place
  8. Save the document, quit, and log out
  9. When you log back in, go to the “Keyboard Layout” preference, hit the + button, and add English (US, alternative international) to your list of layouts
  10. If you run into problems, you can always sudo rm us and then restore the original by typing sudo cp us_backup us

Here is the code to copy over:

partial alphanumeric_keys
xkb_symbols "alt-intl" {

name[Group1]= "English (US, alternative international)";

include "us"

key <TLDE> { [ grave, asciitilde, dead_grave, dead_tilde ] };
key <AE01> { [ 1, exclam, exclamdown, questiondown ] };
key <AE02> { [ 2, at, U02BE ] };
key <AE03> { [ 3, numbersign, U02BF ] };
key <AE04> { [ 4, dollar, sterling, EuroSign ] };
key <AE05> { [ 5, percent, onehalf, onequarter ] };
key <AE06> { [ 6, asciicircum, U00A7, dead_circumflex ] };
key <AE07> { [ 7, ampersand, U00B6, dead_hook ] };
key <AE08> { [ 8, asterisk, U2022, U00B0 ] };
key <AE09> { [ 9, parenleft, dead_breve ] };
key <AE10> { [ 0, parenright, dead_abovering ] };
key <AE11> { [ minus, underscore, U2013, U2014 ] };
key <AE12> { [ equal, plus, multiply, U00F7 ] };

key <AD01> { [ q, Q, dead_belowdot ] };
key <AD02> { [ w, W, U02B7, U1D5B ] };
key <AD03> { [ e, E, U0113, U0112 ] };
key <AD04> { [ r, R, dead_acute, dead_grave ] };
key <AD05> { [ t, T, U1E6D, U1E6C ] };
key <AD06> { [ y, Y, U1E6F, U1E6E ] };
key <AD07> { [ u, U, U016B, U016A ] };
key <AD08> { [ i, I, U012B, U012A ] };
key <AD09> { [ o, O, U014D, U014C ] };
key <AD10> { [ p, P, leftsinglequotemark, rightsinglequotemark ] };
key <AD11> { [ bracketleft, braceleft, leftdoublequotemark, guillemotleft ] };
key <AD12> { [ bracketright, braceright, rightdoublequotemark, guillemotright ] };
key <BKSL> { [ backslash, bar, notsign, brokenbar ] };

key <AC01> { [ a, A, U0101, U0100 ] };
key <AC02> { [ s, S, U1E63, U1E62 ] };
key <AC03> { [ d, D, U1E0D, U1E0C ] };
key <AC04> { [ f, F, U1E0F, U1E0E ] };
key <AC05> { [ g, G, U0121, U0120 ] };
key <AC06> { [ h, H, U1E25, U1E24 ] };
key <AC08> { [ k, K, U1E35, U1E34 ] };
key <AC09> { [ l, L, U1E2B, U1E2A ] };
key <AC10> { [ semicolon, colon, dead_diaeresis ] };
key <AC11> { [ apostrophe, quotedbl, dead_acute ] };

key <AB01> { [ z, Z, U1E93, U1E92 ] };
key <AB02> { [ x, X, U1E95, U1E94 ] };
key <AB03> { [ c, C, U010D, U010C ] };
key <AB04> { [ v, V, U0161, U0160 ] };
key <AB06> { [ n, N, U23D1, U23D2 ] };
key <AB07> { [ m, M, U2014, U23D4 ] };
key <AB08> { [ comma, less, dead_cedilla, dead_circumflex ] };
key <AB09> { [ period, greater, dead_abovedot, dead_caron ] };
key <AB10> { [ slash, question, U0331, U0304 ] };

include "level3(ralt_switch)"
};

// Keyboard layout by Cameron Cross for Arabists and Persianists.
// Dead characters (use AltGr):
// ~ = grave and tilde / 3 = macron / 6 = circumflex / 7 = hook / 9 = breve / 0 = abovering
// ; = diaresis / ' = accent / , = cedilla / . = dot above / ? = combining macrons below and above
// q = dot below / r = grave and acute / < = circumflex / > = caron
// Special characters (activated with AltGr):
// All vowels have macrons; s t d and z all come with dots below
// 1 = ¡ ¿ / 4 = currencies / 5 = percentages / - = en/em dash / = math characters
// 2 and 3 = ʾ and ʿ (Arabeezi style)
// y = ṯ / f = ḏ / x = ẕ / g = ġ / c = č / v = š /
// k and l = ḵ and ḫ (two alternatives for transliterating "kh")
// w = ʷ and ᵛ (for Persian خو)
// p [ ] = quotes (‘’«»“”)
// n and m = metrical signs ⏑ ⏒ —⏔

As you can see from the comments section, this keyboard is very specifically tailored to my needs. I borrowed elements I like from the US International, UK, and Macintosh layouts, plus some of my own ideas. I write a lot about poetry, so I designated “n” and “m” for metrical units. I also prefer to avoid digraphs in my transliteration, so I have all these special characters for “th”, “kh”, “sh”, “ch”, and “gh” around the center of the keyboard (see comments). The Arabeezi system of 2 for ق (which is often pronounced as hamza, hence ʾ) and 3 for ع is pretty intuitive for me, so I kept that, and I love the Mac’s handling of – for en and em dashes—which I use all the time—so those are there. I will point out that this keyboard is not ideal for Turkish, although you can use AltGr+9+g for ğ and AltGr+.+i for your dotless ı. On the other hand, once the layout is successfully installed, you can go back and tweak the file with your own Unicode characters as you like. Save your changes in a separate text file, so that if you ever upgrade your system, you can just copy and paste it into the document like you did before. Piece o’ cake.

For more information, check out the following sites. I especially liked the one by the fellow medievalist who works on Anglo-Saxon literature.