Keyboard Layouts

Most keyboards send scancodes when a keys are pressed which contain the row and column of the key. It's the responsibility of the Operating System to convert them into characters. This mapping is done by keyboard layouts.

Layout categories

According to Wikipedia we can have three category of layouts.

Physical layout

This is the actual keys on your keyboard. If you know touch typing, this is the most important layout that you need to know.

The most important ones are ANSI and ISO. The former is common in North America and the latter in Europe.

ANSI Physical Layout ISO Physical Layout

Visual layout

Labels on the keys creating this layout. If you are a touch typist, usually you don't care a lot about this layout. You can even buy blank keyboards that don't have any labels. Sometimes there are mismatches between keyboard labels and the actual characters that are shown on the screen.

Functional Layout

This is the most important category that is responsible for converting scancodes to actual characters. You can change it in the Operating System. When you choose for example English layout, then Operating system knows how to convert scancodes to English letters. Although your keyboard has English labels, you can type in other languages by changing functional layout.

Canadian French

Unlike France and Belgium that are using AZERTY, Canadian French is based on QWERTY.

In Linux by default a simplified French layout is used that surprisingly missing some French characters! For example œ, æ and ë. If you're a programmer, it's likely you are used to US keyboards. So you may have difficulty to type characters like #, {, } which are common in programming languages.

Simplified Canadian French Layout

There are two key modifiers to type French characters:

  • dead keys: When you press a dead key nothing happens but it changes the behavior of the next key. For example in Simplified French layout above, the key right to key P is a dead key. If we press it nothing happens but if we press a after it, the character â is shown on the screen. We can type the actual dead key (^) by pressing space key after it
  • Alt GR: In US keyboards it's usually the right Alt key. For example to type @ in simplified French layout, we should type Alt GR + 2

A more recent French Layout is CSA keyboard which seems a bit complicated. This is the default keyboard in Windows 10. It has another modifier key (right Control in Windows) to type some characters (e.g. Æ).

CSA Keyboard

Surprisingly in Linux this layout is separated into two layouts:

Layout (variant) Description
ca(multi) Canadian (intl., 1st part)
ca(multi-2gr) Canadian (intl., 2nd part)

For more information type man xkeyboard-config.

A programming-friendly layout for European languages

EurKEY is based on US layout as well as almost all European characters. You can use it out-of-the-box in Linux but you need to install it in Windows or MacOS. For more information visit its official webpage.

EurKEY Layout

Persian Layout

Linux and MacOS supports All Persian characters out-of-the-box. For Windows you need to install an application. For more information read this Persian article.

پست قبلی پست بعدی