This page documents the Lingala keyboard layout developed in the Spring 2017 section of Computational Linguistics at Swarthmore College. It is licensed under the GNU General Public License v3.0 and available for download on Github.
To discuss any Lingala keyboard layout, it is necessary to have a basic background in Lingala's orthographic history. Lingala is primarily a spoken language with a very limited written tradition. Accordingly, a number of similar, but slightly varying systems of writing have developed over the years. At its core, any Lingala orthography is based upon the Latin alphabet. Lingala contains 35 letters and digraphs. It has seven vowels, including 'ɛ' and 'ɔ' in addition to the five vowels used in English. Of the remaining 28 consonants, the Latin letters j, q, and x are omitted. The remaining Latin letters are used in Lingala (though some only in words borrowed from other languages), with the rest of the consonants being formed as digraphs of two Latin letters. Lingala is a tonal language, consisting primarily of a high tone and low tone, but also, less frequently, making use fo an ascending tone and descending tone.
A typical Lingala orthography uses the system of Latin letters described in the previous paragraph with no additional tone markings. Sometimes, 'ɛ' and 'ɔ' are omitted from the writing system, with 'e' and 'o' taking their place. In some cases, an acute accent might be used with 'e' and 'o' to distinguish 'ɛ' and 'ɔ' from 'e' and 'o'. Because the tone of a word can significantly alter its meaning, however, some works of written Lingala are careful to distinguish tones explicitly. In this case, a low tone is denoted by the lack of an accent, a high tone is denoted by an acute accent, an ascending tone is denoted by a circumflex, and a descending tone is denoted by a caron. In most written works that include tone markings, the circumflex and caron are used sparingly, with the presence or absence of an acute accent as the main indicator of tone.
Due to its limited written tradition, existing Lingala keyboard layouts are sparse. Neither Linux nor iOS nor Windows offer a Lingala keyboard, although Windows allows Lingala language as a selection with the default U.S. keyboard. Still, a couple resources and theoretical layouts are available online and discussed below. None should necessarily be considered the "standard" layout used for Lingala. Indeed, given that most written correspondence in the DRC and Congo is done in French, which has keyboard layouts that make both Latin letters and the acute accent readily available, it is likely those who do wish to type Lingala are able to simply use a French keyboard.
The only functioning Lingala keyboard readily available (here) on the internet is developed by Gate2Home and is available as an online emulator. It is based off the QWERTY Latin keyboard with additional functionality to provide support for tone markings. It differs from a standard U.S. keyboard in two major way: the bracket keys to the left of the 'p' key are replaced with the 'ɛ' and 'ɔ' characters, and accented characters can be formed by typing the character to be accented, followed by the right alt key, followed by one of the accents mapped to the number row across the top of the keyboard. This keyboard has a number of pros and cons. Although based off the U.S. keyboard, it does include the 'ɛ' and 'ɔ' characters which makes typing with that orthography possible if desired. However, they are not centrally located on the keyboard, despite being vowels, so it is possible that there exists a more convenient placement. This keyboard also allows for insertion of accented characters should tone markings be desired. Still, you are required to press three keys (the character, alt, and the accent) in order to produce an accented character which could prove to be a lot of work for someone typing with tone markings. Additionally, the placement of the accents across the number row makes them somewhat difficult to reach with speed and accuracy. Finally, the use of a QWERTY layout may be out of place in the DRC and the Congo, since French (which uses the AZERTY layout) is the most common written language.
Another QWERTY-based keyboard has been developed (here) by Lexilogos. Though this keyboard also uses a QWERTY layout (which is likely undesirable, as previously mentioned), its function is quite different from above. Rather than place the 'ɛ' and 'ɔ' characters separately, it produces them by typing 'e' or 'o' (respectively) follows by two instances of the '=' key. It supports acute accents on vowels (including 'ɛ' and 'ɔ') by typing the vowel followed by the '=' key. This is perhaps slightly more convenient that the previous layout, which requires pressing the alt key at the bottom of the keyboard before pressing a number key at the top of the keyboard to produce an accent, but can get cumbersome quickly if trying to place an acute accent on an 'ɛ' character (e followed by three '='), for example. Additionally, this keyboard does not support the circumflex or caron, which while not used extensively in Lingala, are still sometimes typed. Hence, this keyboard is incomplete in some aspects.
Though the previously described keyboards are the only readily available and functioning keyboards, there is some discussion of Lingala / Congolese keyboard layouts online. One is mentioned in the French Wikipedia discussion page on the AZERTY layout. The keyboard detailed here is based on the AZERTY layout, popular in France and Francophone countries, and is meant as a general purpose Congolese keyboard capable of typing all languages used in the region. Like the online virtual keyboard, this has a number of pros and cons. One significant pro for this keyboard is the fact that it uses an AZERTY layout. AZERTY tends to be the layout of choice for French speakers, and since French, not Lingala or English, is the language most frequently used for writing in the DRC and Congo, it is likely a layout that those literate in Lingala would be familiar with. However, this keyboard is not designed specifically with Lingala in mind. As with the first discussed layout, accents appear to be available via the number row, though the key combinations needed to access them remain unclear from the picture. The keyboard also includes some superflous symbols that might be helpful to someone typing in French or another native language in the area, but they do little to help with typing Lingala.
Given these three very different layouts, it is clear that there is not standardized or typical layout for Lingala. Still, all three contribute some interesting ideas worth pursuing.
My keyboard layout is principled on three key ideas:
- The keyboard should have a familiar feel to users of a typical French language keyboard.
- The keyboard should not simply be a French keyboard with Lingala symbols added where needed. It should feel that it was constructed with typical Lingala orthography in mind, while still retaining the familiarity enumerated above.
- The keyboard should be useful for all of the various methods of writing Lingala text. This includes the presence or absence of 'ɛ' and 'ɔ' characters as will as the ability to use any or all tone markings (acute accent, circumflex, caron). Adding functionality for these variations should not come at the expense of ease of typing another variation.
Due to the absence of standardized Lingala keyboards in standard operating systems, there is wide latitude available in the design of a Lingala keyboard. My design draws primary inspiration from the hypothetical layout discussed on a French language Wikipedia talk page (linked to in the existing resources section). Implementation is done by altering extensively the available xkb US keyboard layout included with Linux and creating a number of custom compose key combinations. However, the keyboard layout linked to above was developed not as a Lingala keyboard but as a Congolese keyboard capable of typing a host of languages used in the area. It also includes a number of unnecessarily duplicative keys. As a result, I have taken some liberties in rearranging characters and symbols. This should be okay, however, since the inspiring keyboard appears to exist only as a hypothetical design and not as a widespread implementation that people in the region are already accustomed to (rather, they perhaps use a typical French keyboard). Where letter placement departs from a standard AZERTY layout, I have taken great care to only alter the location of letters not used in Lingala. Because a typical AZERTY layout includes specific accented characters on the number row, which are no longer needed with my implementation of Lingala tone markings, this has also resulted in some unavoidable rearranging of symbols. The complete justifications for the decisions made in my design follow (note that the layout refers to the layout designed, and the inspiring layout refers to the layout linked to above, with decisions typically described relative to the inspiring layout).
Specific Character Placement
In keeping with design principle (1), a modified AZERTY layout is used. This should be familiar to literate Congolese who are likely accustomed to typing in French. Still, some characters used in French and not Lingala have been rearranged in order to increase ease of typing Lingala specifically. This is in keeping with design principle (2). These alterations include:
- Two key alterations have been made to the placement of the Latin letters relative to the inspiring layout. The placement of the 'R' and 'ɛ' as well as the 'H' and 'ɔ' keys have been swapped. The inspiring layout was constructed with typing both French and Lingala in mind, so it was important to preserve the AZERTY layout exactly as it would appear on a French keyboard. However, the letters 'R' and 'H' are seldom used in Lingala, appearing only in words borrowed from French, whereas 'ɛ' and 'ɔ' are much more frequently used. Hence, for a keyboard designed with Lingala in mind, it makes sense to locate these keys more centrally than their original placement on the far right of the keyboard. For the 'ɛ' key in particular, this is of great convenience since it falls directly to the right of the 'e' key. No similar convenient placement is available for the 'ɔ' key without further alterations to the AZERTY layout.
- Rather than remove the 'R' and 'H' key, they have simply been swapped as described above to the far right side of the keyboard. Similarly, the 'J', 'Q', and 'X' keys have been left in their original position. This is important because Lingala uses a number of borrowed words from French, and, especially when referring to proper nouns, these keys might be necessary to type the occasional French word.
- The number keys, which appear on the second row on the inspiring layout, have been moved to the first row. They likely appear on the second row because a typical French keyboard includes a number of accented characters as first-row characters in these spots and are likely needed more frequently than the number keys. However, accents for tone markings are handled separately with my layout so no such consideration need be taken. Indeed, the punctuation found in the first row on the inspiring layout is all found in the second-row on a standard US keyboard.
- The inspiring keyboard, as only a hypothetical piece of ASCII art, is unclear about how accents and characters (specifically vowels) can be combined. It appears that some of the keys across the number row play a role in this, but these are removed and the punctuation found on the third row moved to the second row to take their place as a matter of convenience (the numbers being moved to the first row, as described above).
- The third and fourth row characters on the 'I', 'O', and 'U' keys on the inspiring layout are removed, since these characters are not present in Lingala.
- The third and fourth row characters on the 'C' key ('c' and 'C' with a cedilla) are maintained, since these characters are found in French and may appear in borrowed Lingala words
- The division and multiplication sign found on the '=' key on the inspiring layout are removed since these symbols do not appear on a typical US keyboard and certainly aren't relevant to the Lingala language.
- The percent sign is moved from the third row of the '-' key to the second row of the '9' key since the removal of the accent from the '9' key creates an empty spot on the second row.
- The dollar sign is moved from the third row of the '*' key to the second row of the '8' key. The symbol with two forward arrow heads is not necessary in Lingala and not found on a US keyboard.
- The '^' character on the third row of the 'ɛ' key (as placed on the inspiring keyboard) is removed, since it appears on the second row of the key to its right.
- The '#' character is moved from the third row of the '1' key to the second row of the '3' key for convenience, taking the place of the two left facing arrows on the inspiring layout, which is not needed.
- The inspiring layout contains the <"> symbol as the third row of the backslash key. It also includes a duplicative '@' on the second row of the '0' key. Hence, the duplicated '@' has been replaced with <"> and the <"> symbol removed from the backslash key.
Tone Marking System
To allow for complete tone marking, it must be possible to add an acute accent, circumflex, or caron to each of the seven vowels. Since Lingala has many borrowed words from France and it should be possible to use the keyboard layout for basic French typing, it is also important to support the addition of a grave accent to each of the seven vowels. Tone marking is implemented on this keyboard layout using a mixture of third-row keys and compose key combinations.
- To each key used for one of the vowels 'a', 'e', 'i', 'o', or 'u', the lowercase version with an acute accent has been added to the third row and the uppercase version with an acute accent has been added to the fourth row. When typing with tones, the acute accent is by far the most frequently used tone marking, so it makes sense to put this version on the third and fourth row where they are readily accessible without the need for combination keys.
- The vowels 'ɛ' and 'ɔ' do not have a single unicode number with any added diacritic marks. Rather, they can only be marked for tone by combining a diacritical mark with the unmarked version, making the third row approach used for 'a', 'e', 'i', 'o', and 'u' not possible here. As a solution, custom compose keys have been set up, so that each character composed with itself (e.g. <Compose key><ɛ><ɛ>) adds an acute accent to the character. It is unfortunate that the same approach used for the other five vowels can't be used here, but it seems to be a limitation of the technology, and it seemed more important to make accessing the acute accent version of the other five vowels quick via the third row than making the method uniform across all seven vowels.
- Since the circumflex and caron are used less frequently but can still be desired when typing with tones, these are set up as custom compose key combinations (requiring three key strokes). These are be available for each of the seven vowels (in upper- and lowercase) by composing them with the '5' key (on which the '<' symbol is found in the second row) for the circumflex or the '6' key (on which the '>' key is found on the second row) for the caron. This is done in part because of the visual similarity (even though there is a rotational difference) between the angular brackets and the circumflex/caron and just as importantly because the '5' and '6' keys are relatively centrally located and it should not be too burdensome to make use of these two keys. The compose key itself should be set as the windows key, since it serves no other function in typing. A compose key, which only requires three key strokes, is preferable to adding dead keys in a third row somewhere in this situation since it results in fewer total key strokes.
- Although Lingala does not make use of the grave accent for tone markings, many words borrowed from French may necessitate using a grave accent. For this reason, compose keys have been configured in a similar manner with the seven vowels and the '`' key.
Installation requires both installing the xkb layout and the custom compose key combinations. After cloning the repository, do the following:
- Copy the xkb keyboard layout to the xkb symbols folder using
sudo cp lin /usr/share/X11/xkb/symbols/lin
- Add a layout entry to
/usr/share/X11/xkb/rules/evdev.xmlby copying the code found in the
evdevtext.txtfile to the bottom of the layout list in the XML file. You can find the bottom of the layout list by searching for the
- Copy the custom compose key combinations to your home directory using
cp .XCompose ~/.XCompose
- Copy .xsessionrc file to your home directory using
cp .xsessionrc ~/.xsessionrc. This forces Gtk applications to use XIM, which is necessary for custom compose key combinations
- Restart cinnamon using
- Open keyboard settings by right clicking the task bar, choosing all settings from the menu, and selecting "Keyboard" from the settings page. Then navigate to the "Keyboard layouts" tab of the settings
- Click the '+' in the lower left hand corner and search for "Andrew's Lingala layout" in the list. Highlight it and press add
- After adding the layout to this list, click on it to highlight, and then choose "Options..." int he lower right hand corner
- Set the "Key to choose 3rd level" to "Right alt"
- Set the "Position of Compose key" to "Left win" and hit close
- Log out and log back in (this is necessary to activate the custom compose key combinations)
- Note that the custom compose key file does not include the typical en_US.UTF-8 compose keys. To enable these, uncomment the first line of the ~/.XCompose file