From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/15320 Path: main.gmane.org!not-for-mail From: Idris Samawi Hamid Newsgroups: gmane.comp.tex.context Subject: Arabic-utf-8 (plus a sample) Date: Sat, 05 Jun 2004 13:32:35 -0600 Organization: Colorado State University Sender: ntg-context-admin@ntg.nl Message-ID: Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1086464123 25128 80.91.224.253 (5 Jun 2004 19:35:23 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 5 Jun 2004 19:35:23 +0000 (UTC) Cc: "aleph@ntg.nl" Original-X-From: ntg-context-admin@ntg.nl Sat Jun 05 21:35:10 2004 Return-path: Original-Received: from ref.vet.uu.nl ([131.211.172.13] helo=ref.ntg.nl) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BWgwg-0001iu-00 for ; Sat, 05 Jun 2004 21:35:10 +0200 Original-Received: from ref.ntg.nl (localhost.localdomain [127.0.0.1]) by ref.ntg.nl (Postfix) with ESMTP id 7C41410B1E; Sat, 5 Jun 2004 21:34:59 +0200 (MEST) Original-Received: from eagle.acns.ColoState.EDU (eagle.acns.colostate.edu [129.82.100.90]) by ref.ntg.nl (Postfix) with ESMTP id A02B510ABB; Sat, 5 Jun 2004 21:32:43 +0200 (MEST) Original-Received: from lamar.colostate.edu (lamar.acns.colostate.edu [129.82.100.75]) by eagle.acns.ColoState.EDU (AIX5.1/8.11.6p2/8.11.0) with ESMTP id i55JWbL503782; Sat, 5 Jun 2004 13:32:42 -0600 Original-Received: from IHAMID (ihamid.libarts.colostate.edu [129.82.187.166]) by lamar.colostate.edu (AIX5.1/8.11.6p2/8.11.0) with ESMTP id i55JWae344974; Sat, 5 Jun 2004 13:32:37 -0600 Original-To: "ntg-context@ntg.nl" User-Agent: Opera7.23/Win32 M2 build 3227 Errors-To: ntg-context-admin@ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.0.13 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.comp.tex.context:15320 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:15320 Hi gang, For Arabic we use a Latin transcription in Aleph/(e-)Omega (or even ArabTeX) unless one of the encoding filters like utf-8 is used. Even for utf-8 files, however, it would be very useful to be able to convert a utf-8 file to Latin transcription for further processing by Aleph/(e-)Omega. For example, adding diacritics is much easier to do in Latin than in an Arabic script editor because Latin transcription is one-dimensional and adding diacritics to Arabic is a 2-dimen affair. The best thing would be a perl script but I don't know perl at all (except to run some some precreated scripts). If someone out of the kindness of their heart could write a short and simple script for just seven characters I could do the rest myself and present it back here. Now all of the Arabic charachters in utf-8 can be represented by extended ascii. I need something like this, that converts every extended ascii representation of Arabic utf-8 into a Latin transcription: ا => A ب => b ج => j د => d ه => h و => w ز => z If someone could write a perl script that can accomplish the above conversion, I can manually fill in the rest of the script. Basically I use a modified version of the ArabTeX transcription. Here is a "gift" in return: a sample utf-8 Arabic file that can be processed by Aleph/(e-)Omega in ConTeXt (you will probably need to dvips this, though some dvi-viewers can do the postscript/16-bit thing): ============================================== \hoffset=0pt % for Omega bug: has this been fixed? \def\ArabicUTF{\ocp\UTFArUni=inutf8 %% in88596 %\ocp\UTFArUni=in88596 \ocp\UniCUni=uni2cuni \ocp\CUniArab=cuni2oar \ocplist\UTFArOCP= \addbeforeocplist 1 \UTFArUni \addbeforeocplist 1 \UniCUni \addbeforeocplist 1 \CUniArab \nullocplist \pushocplist\UTFArOCP} \input m-gamma.tex \input type-omg.tex \switchtobodyfont[omarb,12pt] % \textdir TRT% \pardir TRT% \ArabicUTF \starttext ، ؛ ؟ ء آ أ ؤ إ ئ ا ب ة ت ث ج ح خ د ذ ر ز س ش ص ض ط ظ ع غ ـ ف ق ك ل م ن ه و ى ي \blank[big] %ً ٌ ٍ َ ُ ِ ّ ْ ٠ ١ ٢ ٣ ٤ ٥ ٦ ٧ ٨ ٩ ٪ ٫ ٬ ٰ ٱ ٲ ٳ ٴ ٵ ٶ ٷ ٸ ٹ ٺ ٻ ټ ٽ پ ٿ ڀ ځ ڂ ڃ ڄ څ چ ڇ ڈ ډ ڊ ڋ ڌ ڍ ڎ ڏ ڐ ڑ ڒ ړ ڔ ڕ ږ ڗ ژ ڙ ښ ڛ ڜ ڝ ڞ ڟ ڢ ڡ ڢ ڣ ڤ ڥ ڦ ڧ ڨ ک ڪ ګ ڬ ڭ ڮ گ ڰ ڱ ڲ ڳ ڴ ڵ ڶ ڷ ں ڻ ڼ ھ ۀ ہ ۃ ۄ ۅ ۆ ۇ ۈ ۉ ۊ ۋ ی ې ۑ ے ۓ ۔ ە ۰ ۱ ۲ ۳ ۴ ۵ ۶ ۷ ۸ ۹ \blank[big] ـً ـٌ ـٍ ـَ ـُ ـِ ـّ ـْ ـٰ ا ب ج د ه و ز \stoptext ============================================== Best Idris -- Professor Idris Samawi Hamid Department of Philosophy Colorado State University Fort Collins, CO 80523