Monday, March 12, 2012

Bengali input in Windows/Linux

This probably will be one of very few times that I will talk about configuring windows os. Mostly because some of my friends use windows and also want to type bengali.

If one uses openoffice/libreoffice along with this method of typing bengali, then it won't matter if the person is using windows or linux since the files will be compatible with each other.

Windows

Download the ``Ekushey probhat" bengali layout from here. This layout is a phonetic layout and is very intuitive. Don't forget to download the Unicode Keyboard Conjunction list given in the above website. After downloading the ``Ekushey probhat" layout, unzip the file and double click on "Setup" and install it.
To easily switch between Bengali and English,
  • For Windows XP
    • Control Panel >Regional and Language Options >Languages > Text services and input languages >Details >Settings >Preferences >Language Bar. Tick mark both
      • Show the Language bar on the desktop
      • Show additional Language bar icons in the taskbar
  • For Windows 7,
    • Control Panel >Change keyboards or other input methods >Keyboards and Languages >Change keyboards >Language Bar >
      • Language Bar >Docked in the taskbar
      • Show additional Language bar icons in the taskbar
      • Show text labels on the Language bar

Linux (Ubuntu)

IBus (Intelligent Input Bus) helps in inputting various languages in linux. For ubuntu install the packages ``ibus", ``ibus-m17n", ``m17n-db" and ``m17n-contrib". To start up ibus for every login, System >Preferences >Startup Applications >Add
Name IBus Daemon
Command ibus-daemon -rd
Comment Input Method System
To setup the input method, go to System >Preferences >IBus Preferences >Input Method >Select an input method >Bengali > Probhat >Add.

Font installation

``SutonnyBanglaOMJ", FreeSerif and ``Free Sans" are good fonts for writing bengali. You can download the ``SutonnyBanglaOMJ" font from here.
You can also download other bengali unicode fonts from the internet. Just give a google search for ``Bengali Unicode fonts".

Windows

Copy the fonts to c:\WINDOWS\fonts\. Done.

Linux

You probably have the font FreeSerif in your system in
/usr/share/fonts/truetype/freefont/FreeSerif.ttf
If you don't, then install the file via you package manager. For ubuntu the package is ``ttf-freefont". You will need root access. However, if the font is not installed and you don't have root access, then create the directory $HOME/.fonts/f/. Notice the ``." in front of ``fonts". This makes the folder hidden. Now download the freefont-ttf.tar.gz font from here and copy the *.ttf files to $HOME/.fonts/f/. Open a terminal and run the command
fc-cache -fv

Default font selection in LibreOffice/OpenOffice

In the instructions below, substitute openoffice where ever I have said libreoffice if you have openoffice instead of libreoffice. However, I found that FreeSerif font has a problem with bengali conjuctions in the ubuntu version of libreoffice/openoffice. Workaround is either to work with FreeSans font or install libreoffice/openoffice downloaded from their respective sites.
To set the default font for bengali do the following. Open libreoffice

  • Tools >Options >Language Settings >Languages >``Enabled for complex text layout (CTL)". Also under ``Default languages for documents" >CTL, select ``Bengali (India)". Click OK.
  • Tools >Options >LibreOffice Writer >Basic Fonts (CTL) >
  • Choose the fonts as follows:
    Font Size
    Default FreeSerif 20
    Heading FreeSerif 22
    List FreeSerif 20
    Caption FreeSerif 20
    Index FreeSerif 20
  • Format >Character >Font >CTL font

    Font Typeface Size Language
    FreeSerif Regular 20 Bengali (India)
I have seen that sometimes, on some computers, FreeSerif font (windows/linux) won't write the conjuction alphabets correctly. I haven't been able to debug it. If that is the case stick to ``SutonnyBanglaOMJ" as your default font.

Input method


Windows

Click on the ``EN" icon on the right hand corner of the taskbar. Click ``Show the language bar". A bar appears on the top right hand. Open libreoffice-writer and click on ``English" to select ``Bengali (India)". The default keyboard shortcut to switch between input languages is ``Left Alt+Shift".

Linux

Open libreoffice-writer. To toggle between ibus input and default language, the keyboard shortcut is ``Ctrl+Space".


No comments:

Post a Comment