ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Idris Samawi Hamid" <ishamid@colostate.edu>
Subject: Re: Aleph - description & more info
Date: Sun, 01 Jan 2006 17:41:41 -0700	[thread overview]
Message-ID: <op.s2p6vrjenx1yh1@walayah1.wildblue.com> (raw)
In-Reply-To: <6faad9f00601011321u401285fbp464264dd9ec61402@mail.gmail.com>

On Sun, 01 Jan 2006 14:21:39 -0700, Mojca Miklavec  
<mojca.miklavec.lists@gmail.com> wrote:

> Idris Samawi Hamid wrote:
>> Hi Mojca,
>>
>> Here is a place to start ():
>>
>> http://www.dtek.chalmers.se/~d97ost/omega-example.html
>
> After some experimenting I managed to get your example on
> http://www.dtek.chalmers.se/~d97ost/omega/gamma/README
> to kind-of-work.
>
> I get those strange arabic and whatever-strange-script-glyphs, but
> just a short question: how to typeset in utf-8?
>

The point is that you have to set up the otp filters to use the utf-8  
filter instead of the transcription filter. See below...

If you already have the regular omega support files in MiKTeX etc, then  
great. Otherwise:
Here is a set of instructions for ConTeXt users:

1. Get the omega support files:

http://www.ctan.org/get?fn=/systems/win32/fptex/0.7/package/omega.zip
http://www.ctan.org/get?fn=/systems/win32/fptex/0.7/package/omegafonts.zip

2. Get rid of the following directories from omega.zip (not really  
necessary but if u want to be efficient):

texmf/eomega
texmf/omega/encodings

3. Put files in texmf-local;

4. Compile the Aleph format:

mktexlsr

texexec --make en -tex=aleph

5. Always start aleph files with this preamble:

% tex=aleph output=dvipdfmx

Now test: texexec the following file (in utf-8). I have included a  
modified version of the one u already have for xtra practice-)

Study \def\ArabicUTF: it uses raw omega/aleph commands, but see also  
m-gamma.tex (in the ConTeXt distro) for some higher-level commands

\definefiltersynonym
\definefiltersequence
\usefiltersequence

Have fun!

Best
Idris

==========================================================
% tex=aleph output=dvipdfmx
\hoffset=0pt

\def\ArabicUTF{\ocp\UTFArUni=inutf8 %% in88596
                %\ocp\UTFArUni=in88596
                \ocp\UniCUni=uni2cuni
                \ocp\CUniArab=cuni2oar % ocp's used

                \ocplist\UTFArOCP=
                \addbeforeocplist 1 \UTFArUni
                \addbeforeocplist 1 \UniCUni
                \addbeforeocplist 1 \CUniArab
                \nullocplist           % ocp list

                \pushocplist\UTFArOCP} % apply this filter sequence

\input m-gamma.tex
\input type-omg.tex
\switchtobodyfont[omarb,12pt] %

\textdir TRT%
\pardir TRT%
\ArabicUTF

\starttext

  ، ۪

  Ø› ØŸ

  ء آ أ ؤ إ ئ ا ب ة ت ث ج ح خ د

  ذ ر ز س ش ص ض ط ظ ع غ

  ـ ف ق ك ل م ن ه و ى ي ً  ٌ  ٍ َ  ُ

  ِ ّ  ْ

  Ù  Ù¡ Ù¢ Ù£ Ù¤ Ù¥ Ù¦ Ù§ Ù¨ Ù© Ùª Ù«

  Ù¬ Ù° Ù± Ù¾

  Ú†

  Ú˜

  Ú¤ Ú¯

  Ú¾

  ۀ ہ ۃ ې ے ۓ ۔ ە

  Û° Û± Û² Û³ Û´ Ûµ Û¶ Û· Û¸ Û¹

% ا ب ج د ه و ز

\stoptext
=================================================================

Here's another file, similar to the one you started with:

=================================================================
% tex=aleph output=dvipdfmx
\input m-gamma.tex
\input type-omg.tex

\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}

\setupbodyfont[omlgc,12pt]

\showframe[text]

\starttext%

\start

\ArabicUTF\switchtobodyfont[omarb]%
      \textdir TRT\pardir TRT

بسم الله الرحمن الرحيم الله اكبر من
أن يوصف

\stop

\textbullet\ This is a test coffin

{\tfb \textbullet\ This is a test coffin}

{\tfc \textbullet\ This is a test coffin}

{\tfd \textbullet\ This is a test coffin}

{\tfx \textbullet\ This is a test coffin}

{\tfxx \textbullet\ This is a test coffin}

{\bf \textbullet\ This is a test coffin}

{\bfc \textbullet\ This is a test coffin}

\startgreek

\textbullet\ A B G D a b g d

{\tfc \textbullet\ A B G D a b g d}

{\bf \textbullet\ A B G D a b g d}

{\bfc \textbullet\ A B G D a b g d}

\stopgreek

\startarab

`rby:

\textbullet\ A b t th j H kh

{\tfc \textbullet\ A b t th j H kh}

{\bf \textbullet\ A b t th j H kh}

{\bfc \textbullet\ A b t th j H kh}

fArsy:

{\tfc \textbullet\ A b p t th j ch H kh}

\starturdu

ArdU:

{\tfc \textbullet\ A b p t 't th j ch H kh}

\stopurdu

`rby:

bsm ALLah Al-rrHmn Al-rrHym

fArsy:

bh nAm khdAwnd b-kh-sh-nde mhrbAn

\starturdu

ArdU:

ALLah kE nAm sE jw rHmAn w rHym hE

\stopurdu

\stoparab

\stoptext

=================================================================

-- 
Professor Idris Samawi Hamid
Department of Philosophy
Colorado State University
Fort Collins, CO 80523

--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

  reply	other threads:[~2006-01-02  0:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-31 17:08 Mojca Miklavec
2005-12-31 18:56 ` Idris Samawi Hamid
2006-01-01 18:05   ` Mojca Miklavec
2006-01-01 19:13     ` Idris Samawi Hamid
2006-01-01 20:20       ` Mojca Miklavec
2006-01-01 21:21       ` Mojca Miklavec
2006-01-02  0:41         ` Idris Samawi Hamid [this message]
2006-01-02  1:22           ` Idris Samawi Hamid

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=op.s2p6vrjenx1yh1@walayah1.wildblue.com \
    --to=ishamid@colostate.edu \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).