Ankur - Supporting Bangla (Bengali) on GNU/Linux
Home
বাংলা পাতা
General
»
»
»
»
»
»
People & Projects
Documents
Downloads
Contact
Screenshots
Wiki
» Mailing Lists
Miscellaneous
» Linux.org
» Related Links
Bangla Keyboard Mini HOWTO

This really *is* a mini-how-to. The intention of this howto is not to explain what is xkb symbol file, or how to create a new layout, etc. There are tons of places on the web where one can find a better and more in-depth HOWTO about Xfree86 keyboard[layout/xkb/etc].

There is nothing special about setting up a Bangla Keyboard for Linux, just follow the steps described below. Remember everything you need in the following steps can be downloaded from the download section of Ankur's web page, except the machine and the OS :) Make sure you have some Unicode encoded Bangla fonts installed on your system, otherwise there is no point setting up the keyboard layout. If you are running XFree86's version 4.x server then you should already have the symbol file for Bangla keyboard layout, otherwise you can download it from our download section and copy it to the directory where the other xkb symbol files are. Usually this would be:

/usr/X11R6/lib/X11/xkb/symbols
BTW, usually only root can copy files into this directory.

There are many ways to setup an keyboard layout. Desktops like GNOME and KDE come with their own programs to set up keyboard layouts. However, here only two basic ways are discussed.

Setting Bangla keyboard through X server configuration file

If you want Bangla keyboard option available for all users then this is the easy way. Add the following lines to your XFree86's configuration file:
  Section "InputDevice"
       Identifier  "Keyboard0"
       Driver      "keyboard"
       ...
       # Add the following three lines
       Option      "XkbLayout"   "us+ben"
       Option      "XkbVariant"  "probhat"
       Option      "XkbOptions"  "grp:ctrl_shift_toggle,grp_led:scroll,compose:ralt"
       ...
You should alread have the XkbLayout option, so just change it. Also, the XkbVariant set to "probhat" will pick up the phonetic layout created by Ankur.

Setting Bangla keyboard through shell command

With the following command you can get the same effect as above. However, you will have to do this everytime you start X server.
> setxkbmap -symbols "us+ben(probhat)+group(ctrl_shift_toggle)"

What are those values?

The above sets the us layout in first group and ben in the second group. What does that mean? Well in simple words: with X you can have different layouts in different groups and you can switch between these different layouts. And that is exactly why we added the XkbOptions in first method and group(ctrl_shift_toggle) in the second! This means we can switch between the two groups by pressing control+shift buttons together. Matter of fact there are other options for the toggle switch. If your XFree86 is new enough, you will find a file named group in the same directory you copied ben. If your system does not have this file do not worry - you can not use the first method mentioned here, and in the second method you can use an option like grp:shift_toggle which will toggle by pressing both shift buttons. In which case your command becomes:
> setxkbmap -symbols "us(pc101)+ben" -option "grp:shift_toggle"
This would in fact be preferable if you use KDE, since many standard KDE keyboard shortcuts involve the Ctrl+Shift combination.


This project is hosted by SourceForge Logo

Copyright (c) 2002, Taneem Ahmed <taneem@eyetap.org>