[Padma] Understanding how Padma functions, and reusing code

Gora Mohanty gora at sarai.net
Thu Nov 16 13:57:48 PST 2006


On Mon, 2006-11-13 at 16:58 -0500, Nagarjuna Venna wrote:
> Gora,
> 
> I'm a little bit concerned about porting Padma code to many languages
> - there is currently an effort underway to port Padma to Python so
> that it can be used in the backend. It will be a problem keeping
> multiple versions in sync. If you want to build a C front end, I would
> urge you to look at engines like SpiderMonkey or Rhino.

I quite agree with the desirability of keeping a single code base, but
am faced with two issues:
(a) I would like to have a library with a well-defined API that provides
    functions for code conversion, but also for things like
    decomposition of a UTF-8 Indic string into syllables. The reason to
    have such a base library in C is maximum portability with the
    minimum of additional dependencies. For example, I would like to use
    the syllable-decomposition code in aspell to build a spellchecker
    specialised for Indian languages. I know for a fact that a patch to
    aspell that had SpiderMonkey/Rhino as a dependency would not be
    accepted.
      Also, I am not sure how familiar you are with SWIG
    (http://www.swig.org), but it automatically creates bindings in
    other languages from a C/C++ code base, i.e., there is no need for a
    reimplementation in other languages. Thus, rather than trying to
    port Padma separately to other languages, I would suggest that any
    such porting be done to C, from which bindings for other languages
    could be automatically derived. From meeting with Sunil Mohan of
    the Swecha project (and, TCS), I understand that they already have
    a PHP port of Padma. Rather than such disparate efforts, I would
    like to see a consensus on what language to use for a common code
    base.
(b) This is a much more minor point, but the other problem that I
    see with Padma is that adding a new font is too difficult for a
    non-programmer. Maybe this can be addressed by building a GUI
    front-end, but I have not yet familiarised myself enough with the
    Padma code to tell if this is feasible.

> As for adding support for a new font, the only documentation we have
> so far is the mail I sent to Karunakar earlier. Many people on this
> list are familiar with the process (Saravan, Anvar, Golam, Cibu etc.),
> so if you have questions it is likely to be answered pretty quickly
> here.

OK.

> We don't have support for Oriya in Padma yet. If you want to work on a
> font, I will add the preliminary support and send the XPI to you.

Please do so. I think that it would be an useful way for me to get into
the Padma code, and some tangible benefit would come out of it.

Regards,
Gora



More information about the Padma mailing list