Dear folks,

Here are two Gamma (context-omega) files which any of you can test right out of the 
box with a standard Omega distribution (1.15 is current and on the latest TeX-Live). 
Just compile the omega 
format as per Han's instructions: 

texexec --make --alone --tex=omega en

texexec --tex=omega om-test.tex

The two files are identical except that one (om-test.tex) uses typescripts and the 
other (om-test2.tex) uses \font from Plain. Use odvips (not dvips) or dvipdfm to view. 

om-test2.tex works and u can see the Arabic;
om-test.tex does not work; it substitutes cmr.

A question: The headline in om-test2.tex prints Arabic in the main body but uses cmr 
for the headline. How can I set the headline font using \font?

First the typescript. Two raw virtual fonts, omarab and omarabb. The encoding is OT1:
%==========================================
%type-omarabic.tex

\usetypescriptfile[type-buy]

\starttypescript [naskh] [omarabic]
  \definefontsynonym [Omarab-Roman]       [omarab]  
  \definefontsynonym [Omarab-Bold]        [omarabb]  
  \definefontsynonym [Omarab-Italic]      [omarab] 
  \definefontsynonym [Omarab-Bold-Italic] [omarabb] 
\stoptypescript

\starttypescript [naskh] [omarabic] [name]
  \usetypescript[serif][fallback]
  \definefontsynonym [Serif]           [Omarab-Roman]
  \definefontsynonym [SerifBold]       [Omarab-Bold]
  \definefontsynonym [SerifItalic]     [Omarab-Italic]
  \definefontsynonym [SerifBoldItalic] [Omarab-Bold-Italic]
\stoptypescript

\starttypescript [Omarab]
  \definetypeface [MyOmarab] [rm] [naskh] [omarabic] [default] 
\stoptypescript
%==========================================

Now om-test.tex
%==========================================
%om-test.tex
\pagedir TRT %
\bodydir TRT %
\textdir TRT %
\pardir TRT
\hoffset=-9cm

\usetypescriptfile[type-omarabic]
\usetypescript[Omarab]
\setupbodyfont[MyOmarab]

     \ocp\ArabUni=7arb2uni
     \ocp\UniCUni=uni2cuni
     \ocp\CUniArab=cuni2oar
     \ocplist\ArabicOCP=
     \addbeforeocplist 1 \ArabUni
     \addbeforeocplist 1 \UniCUni
     \addbeforeocplist 1 \CUniArab
     \nullocplist

\starttext%
\pushocplist \ArabicOCP

\raggedright \noindent qaAla: yaA jaAbir! `alayka biAlbayaAni wa
Alma`aAniy.

qaAla: qultu: wa maA AlbayaAnu wa Alma`aAniy?

qaAla: qaAla `aliyyuN (`): 'aammaA AlbayaAnu, fahuwa 'aan ta`rifa ALLaha
subHaAnahu; laysa kamithlihi shay||uN fata`buduhu wa laA tushriku bihi
shay'yaNA. 'ammaA Alma`aAniy, fanaHnu ma`aAniyhi: wa naHnu janbuhu, wa
yaduhu, wa lisaAnuhu, wa 'aamruhu, wa Hukmuhu, wa `ilmuhu, wa Haqquhu.
'iidhaA shi'ynaA, shaA||a ALLahu; wa yuriydu ALLahu maA nuriyduhu~...

\popocplist %
\stoptext
%==========================================

Finally, om-test2.tex:
%==========================================
%om-test2tex
\pagedir TRT %
\bodydir TRT %
\textdir TRT %
\pardir TRT
\hoffset=-9cm

%\usetypescriptfile[type-omarab]
%\usetypescript[Omarab]
%\setupbodyfont[MyOmarab]

\font\naskh=omarab at 14pt %
\naskh

     \ocp\ArabUni=7arb2uni
     \ocp\UniCUni=uni2cuni
     \ocp\CUniArab=cuni2oar
     \ocplist\ArabicOCP=
     \addbeforeocplist 1 \ArabUni
     \addbeforeocplist 1 \UniCUni
     \addbeforeocplist 1 \CUniArab
     \nullocplist

\starttext%
\pushocplist\ArabicOCP

\raggedright \noindent qaAla: yaA jaAbir! `alayka biAlbayaAni wa
Alma`aAniy.

qaAla: qultu: wa maA AlbayaAnu wa Alma`aAniy?

qaAla: qaAla `aliyyuN (`): 'aammaA AlbayaAnu, fahuwa 'aan ta`rifa ALLaha
subHaAnahu; laysa kamithlihi shay||uN fata`buduhu wa laA tushriku bihi
shay'yaNA. 'ammaA Alma`aAniy, fanaHnu ma`aAniyhi: wa naHnu janbuhu, wa
yaduhu, wa lisaAnuhu, wa 'aamruhu, wa Hukmuhu, wa `ilmuhu, wa Haqquhu.
'iidhaA shi'ynaA, shaA||a ALLahu; wa yuriydu ALLahu maA nuriyduhu~...


\popocplist%
\stoptext
%==========================================

I hope this helps u guys to help me find the problem. I am still trying to solve the 
size callibration problem as well.

>The encoding is OT1. `mtnaskhi' is the complete family name.
>
>These fonts constitute a ``naskh'' family analogous to a 
>``roman'' or ``serif'' family in Latin. I want to use these as follows:
>
>mtnaskh for main text greater than 9pt;
>mtnaskh8 for main text smaller than 9pt (like footnotes)
>mtnaskhb for bold text;
>
>All other medium styles should be substituted by the main text fonts as dictated by 
>size
>All other bold styles should be substituted by the bold text font.
>Each font should be scaled by 1.6. 
>
>Put another way, I'm trying to translate the following NFSS code into typescripts:
>
>\DeclareFontShape{OT1}{mtnaskhi}{m}{n}{
>   <9-> [1.6] mtnaskh
>   <-9> [1.6] mtnaskh8
>}{}
>\DeclareFontShape{OT1}{mtnaskhi}{bx}{n}{
>   <-> [1.6] mtnaskhb
>}{}

Best wishes
Idris

==========================
Dr. Idris Samawi Hamid
Depatment of Philosophy
Colorado State University
Fort Collins, CO 80526



Reply via email to