kBLOG

All things about Life, Oracle Middleware and Technology

Arabic Reshaper goes open source, codename “BAR=Better Arabic Reshaper”

| 124 Comments

bar1

Dear all,

Sorry for making you wait all this time, but I dont really have time, and some of my attempts to merge my work with some people failed.

So I thought of doing it the right way, and allow people to share the experience with me, and take advantage of the Arabic Reshaper, so I’m gonna put it on github and share the source code to whom it may concern!

And i’m gonna release my latest updated application, which still has some bugs, but I hope you can forgive me with that.

Update:The project has come to live, check out this link all http://bar.amr-gawish.com/

Update #2: The following project has code that enables Arabic Reshaping with Tashkeel (Harakat)  http://github.com/AhmedEssam/Better-Arabic-Reshaper

  • http://blog.amr-gawish.com agawish

    @Hadi Thanks, I believe it has been fixed by now :)

  • http://blog.amr-gawish.com agawish

    @Mumi I totally agree with you, and I believe that’s why I made it open source to change ideas and to be able to direct this to the right one

    However I got the rumors that google gonna release Arabic support -If they survived the law suit of oracle- in the next major release, so I believe this project will go to vain.

    but who knows maybe someone someday can use this, please feel free to fork the project and do the changes you wish to do

  • http://blog.amr-gawish.com agawish

    @Mumi I totally agree with you, and I believe that’s why I made it open source to change ideas and to be able to direct this to the right one

    However I got the rumors that google gonna release Arabic support -If they survived the law suit of oracle- in the next major release, so I believe this project will go to vain.

    but who knows maybe someone someday can use this, please feel free to fork the project and do the changes you wish to do

  • Yaj786

    Salam Amr,

    Jazakallah for this great utility. I was just wondering, to use the tashkil functionality do you need to use a specific constructor?

    Also, since each letter is a unique unicode point, can’t you make the search O(n) by using your ARABIC_GLPHIES array as a hash table?

    To look up a specific letter, just do ARABIC_GLPHIES[letters code - ARABIC_GLPHIES[0]]

    I’m not sure if that is right, but I’ll test it out and let you know!

  • http://www.amr-gawish.com agawish

    @Yaj786 Thanks,
    and that’s why It’s made open source, so that you and other developer enhance the code base and come up with a better utility to help all of us.

  • Yaj786

    Yeah, I realized the point of it being open source after I wrote the comment :) . I’ll try to git the source.

    However you still haven’t answered my other question. I can’t get

    بِسْمِ اللهِ الرَّحْمن الرحيم

    to display correctly. Is it just not implemented yet or is there some way to do it properly?

  • http://www.amr-gawish.com agawish

    There are some work done about Tashkeel from Ahmed Essam, you can check his stuff in here http://github.com/AhmedEssam/Better-Arabic-Reshaper , you will notice the update#2 in my blog post

  • Sarwan

    i found a bug. last one word laking in getWordsFromMixedWord() funiction. may be right add “finalWords.add(tempWord);” back of for loops.

  • hesham

    guts where is the tutorial to install the reshaper

  • hesham

    guys where is the tutorial to install the reshaper

  • Wassimtaleb

    arabic words show as separate letters on my htc desire hd
    will this application solve the issue?

  • http://www.amr-gawish.com agawish

    Yes, it’ll insha’Allah
    However, the application became so old, and I believe there are several better applications that does the same job in the Android market

  • Richoo

    where the f.. the info how to istall it

  • googler

    Hello
    I have been playing around with the soft keyboard sample and taught if there was any way i could use your arabic reshaper. I want it to join the letters that are being typed by the keyboard. Is there any way i can do it

  • al-qurashi

    like what app?
    i need an application name

  • http://profiles.google.com/xeus.man Kamran Zafar

    I tried reshaping the Quranic verses but some characters still appear as boxes. I also used the DejaVuSans font. Do you know why this could be happening?

    Does this lib provides full Arabic support? are there plans to update it in the future to reshape Quranic text?

  • pau

    Hi,

    I’m slightly modifying your software,adding some Farsi characters, but I don’t speak Arabic, nor Farsi… I’m just guessing what your program does, and I have a doubt.
    According to  http://utf8-characters.com/arabic-presentation-forms-a/
    Arabic letters have different forms, including an isolated one.

    If I’m right, your matrix ARABIC_GLPHIES, represents the data as follows:
    unicode – isolated – initial – middle – final -number of forms. For instance,

    { ‘u0622′,’uFE81′,’uFE81′,’uFE82′,’uFE82′,2 }

    means:
    ‘u0622′ is the unicode representation
    ‘uFE81′ is the isolated representation
    ‘uFE81′ is the initial representation
    ‘uFE82′ is the middle representation
    ‘uFE82′ is the final representation
    2 is the number of forms (in this case there are repeated chars)

    by unicode representation I mean the one described here: http://www.unicode.org/charts/PDF/Unicode-6.0/

    If my assumptions are right, your code is apparently not looking for isolated chars. The only time you look for the form 1 is within an if case (reshapeIt method), when

    if(wordLength >= 2)

    my understanding is an isolated char has lenght=1…

    My questions are:

    1) did I understand correctly the representation of your data?
    2) Am I right thinking the isolated chars are never displayed?

    Thanks in advance

  • Kangmarfu

    assalamu’alaikum.
    Hello, im from Indonesia. I’d tried to install the code but always failed. My device is Samsung Galaxy Mini (S5770) with android 2.2.1. AS A new user, i installed the code via ADB TOOL,  i copied the codes (script) from notepad to cmd. is it true method? I very need your help, so would u like to guide step by step. I use a lot of arabic books (al-kutub wa al-turath al-rabiyah) for teaching. thank you fot your help

  • Omarkharrat

    thanks

  • Yahiasayadi

    salam,
    is your program, arabic sms reader & writer,  ready

  • A_q_ghouri

    i from pakistan. i am just trying to write urdu dictionary..i need to add urdu words init. i m helpless to implement. kindly suggest me wat should i do..
    a_q_ghouri@yahoo.com

  • A_q_ghouri

    Asslam-o-Alikum!

    after very hard try i got your contact.
    i am doing little work with Android Urdu Dictionary. and it has many more new words then Arabic.
    Like
    “u0686″,”u067d”,”u0679″ etc.
    i m unable to add-up these extra char. in Ghylps . please help me in this regard. kindly.

    - Abdul Qadeer

  • yosef

    hi
    iwant download farsi for sms & … pls help me

  • Yosef

    hi
    iwant download farsi for sms & … pls help me
    my phone is android sys