Bengali Writer Font Utilities
bn2html
bn2html is a utility for converting text files written in a specified
format to an html file that you can view using Netscape
in a bengali font. The current version of bn2html works only
on X windows. You need Netscape Navigator version 3.0 onwards for
using this package.
This page gives you an overview of the software:
how to install it and how to write documents in special format so
that you can view Bengali text using Netscape.
How to install bn2html
Decompress and unpack the files bwfu1_0-bn2html.tgz and
bwfu1_1-X11fonts.tgz. Use the gunzip program from GNU and the tar utility. For
example,
gunzip bwfu1_0-bn2html.tgz
tar xvf bwfu1_0-bn2html.tar
First install the X11 bitmap fonts. The procedure is described
elsewhere.
Next go to the bn2html directory and do the following.
Decide a directory to store the character map file bn.enc. Say it is <encdir>.
Copy bn.enc to <encdir>.
Edit the source bn2html.c
Change the line
#define ENCFNAME "/usr/local/lib/bn2html/bn.enc"
to point to the encoding file (bn.enc) for later use by bn2html.
Compile bn2html.c. For example,
gcc -o bn2html bn2html.c
Install the executible (bn2html) in a suitable place.
Viewing Bengali Documents
Suppose you have a bengali page mypage.html.
Add the X11 fonts.
Call netscape to view mypage.html.
Go to Options/General Preferences/Fonts
Select User-defined `For the Encoding:'
Set proportional font to `Bengali(*,*-fontspecific)'
Optionally set the fixed font to `Bengali(*,*-fontspecific)'
Now go to Options/Document Encoding
Set encoding to User-defined
That's it. You should now see mypage.html in bengali.
Converting Bengali Documents
Remember you have compiled bn2html.c. Use this executible to convert.
Write your bengali document in a file, say, mypage.bn
Call bn2html to convert:
bn2html -o mypage.html mypage.bn
This creates mypage.html. View it.
bn2html should be called as:
bn2html [options] input_file
where the options are:
- -o output_file
-
Output to output_file. The default is stdout.
- -t type
-
Set type of the output file. The argument can be either 0 or 1. 0 can also be specified
as BengaliOnly and 1 also as AllowEnglish. The default is BengaliOnly.
It's important that you understand this. BengaliOnly pages should be
viewed with both Proportional font and Fixed font set to Bengali.
On the other hand, AllowEnglish pages should be viewed with
Proportional font set to Bengali and Fixed font set to an English font
(Schumacher or Fixed or ...). The idea is that if your output file
contains text in tt format (obtained by <TT>, <PRE> etc.),
this text will be printed in English.
Writing Bengali documents
And here comes the last part of the game. How to create Bengali
documents that when converted by bn2html will produce the desired html
file? The manual accompanied by the package deals with this topic
in all details.
The roman-to-bengali
conversion rules provided by bn2html are modified versions of those
provided by Bengali Writer.
I think these new rules are easier and
handier to use. I thank all those people whose feedback helped me
modify old-style Bengali Writer rules to create the new interface.
A note on portability
X11 bitmap fonts can be used in any operating system that supports
X windows. Nowadays almost all Unix systems run X windows. bn2html works
for these systems. Other windowing systems (for example, MSDOS windows)
may not support these fonts. You cannot use bn2html in those systems.
If you use windowing systems other than X, check out if there is a
font utility that converts METAFONT/pk/gf/gsf/bdf/pcf files to the
format your windowing system reads. If you find one, generate the
desired font files and use bn2html.
Address for correspondence
Dr. Abhijit Das (Barda)
Ruhr-Universit�t Bochum
Fakult�t f�r Mathematik
Geb�ude NA, Zimmer Nr.3/35
44780 Bochum, Germany
E-mail: [email protected]
URL: http://in.geocities.com/ad_rab/