Changes

Jump to navigation Jump to search
10 bytes removed ,  13:02, 19 January 2006
fixed typos
(with apologies to Maimonides)
by Prof. [[User:Ishamid|Idris Samawi Hamid]]
< [[Aleph]] | [[Arabian and Hebrew]] >
Users of MiKTeX and other OS's will need to adjust the following instructions to their own setups.
* Make sure you have a very recent version of ConTeXt that supports the engine path mechanism. This mechanism allows <tt>texexec </tt> to manage two, e.g., <tt>cont-en.fmt </tt> files at once, one in <code>texmf/web2c/aleph</code> and one in <code>texmf/web2c/pdfetex</code>
How recent, you ask? Just be safe and get the latest <tt>:-)</tt>
* Some configuration points:
** Make sure you have the following line in <tt>texexec.ini</tt> set to "true": "<codetexcode>set UseEnginePath to true</codetexcode>"** In <tt>texmf-local\web2c\texmf.cnf</tt>, <tt>texmf-local\web2c\context.cnf</tt>, and <tt>texmf\web2c\texmf.cnf</tt>comment this line as follows<texcode>%extra_mem_bot.context = 2000000</texcode>otherwise Aleph will crash under some conditions, like overfull boxes and the like...<br>The [[XeTeX]] developer found the source to this bug, and a fix; hopefully [[User:Oblomov|Giuseppe ]] will get to it :-)) 
* Get the omega support files [http://www.ctan.org/get?fn=/systems/win32/fptex/0.7/package/omega.zip omega.zip] and [http://www.ctan.org/get?fn=/systems/win32/fptex/0.7/package/omegafonts.zip omegafonts.zip].
 
* Get rid of two directories from omega.zip (not really necessary but if you want to be efficient): <tt>texmf/eomega</tt> and <tt>texmf/omega/encodings</tt>
 
* Put support files in <tt>texmf-local</tt>.
 * Compile the Aleph format:  <texcode>mktexlsr <br>texexec --make en -tex=aleph</texcode>* Here is a test file. Note the preamble<texcode>% tex=aleph output=dvipdfmx</texcode>at the beginning of every Aleph file.
===omarb.tex===
<texcode>
% tex=aleph output=dvipdfmx
\usemodule[gamma] % or \input mtype-gammaomg.tex% perhaps \input usetypescriptfile[type-omg.tex] ?
\setupbodyfont[omlgc,12pt]
</texcode>
* For Arabic script you will probably want to use an [[Encodings_and_Regimes|encoding]] that supports direct Arabic-script editing. There are three: utf-8, iso-8859-6 (Apple/Unix), and cp1256 (Microsoft). We can define the following, using ConTeXt macros for managing filter sequences. Maybe I will add these to [[source:m-gamma-tex|m-gamma]] and ask [[User:Hagen|Hans ]] to distribute. In the meantime, here are some definitions, samples of all three encodings, and an example of mixed lr-rl text: {{todo|the Unicode characters got mixed up in the mail, please fix it, Idris!}}
===m-arabic-enc.tex===
<texcode>
% tex=aleph output=dvipdfmx
%\usemodule[gamma] \input m-gamma.tex%\input type-omg.tex
\usetypescriptfile[type-omg]
\usetypescript[OmegaArab]
@"E000-@"E3FF => #(\1 - @"DF00);
Basically, in <tt>uni2cuni.otp </tt> final-kaaf gets mapped to E343. In the font, we want it mapped to kafswashfin, so we did that. Now recompile the otp:
otp2ocp cuni2oar
Ingredients: omarab.cfg, omseco.afm, omsea1.afm, omsea2.afm, omsea3.afm
#> perl makeovp.pl omarab.cfg omseco.afm omsea1.afm omsea2.afm omsea3.afm omarab.ovp #> pltotf omseco.pl omseco.tfm #> pltotf omsea1.pl omsea1.tfm #> pltotf omsea2.pl omsea2.tfm #> pltotf omsea3.pl omsea3.tfm #> ovp2ovf omarab.ovp omarab.ovf omarab.ofm
If the last line does not work, try
#> ovp2ovf omarab.ovp omarab.ovf omarab.tfm
rename omarab.tfm to omarab.ofm --> ofm directory
get omarab.ofm & rename to omarab.tfm
#> ovf2ovp omarab.ovf omarab.tfm omarab.ovp
====How to cook omarabb.ovf====
Ingredients: omarab.cfg, omsecob.afm, omsea1b.afm, omsea2b.afm, omsea3b.afm
#> perl makeovp.pl omarab.cfg omsecob.afm omsea1b.afm omsea2b.afm omsea3b.afm omarabb.ovp #> pltotf omsecob.pl omsecob.tfm #> pltotf omsea1b.pl omsea1b.tfm #> pltotf omsea2b.pl omsea2b.tfm #> pltotf omsea3b.pl omsea3b.tfm #> ovp2ovf omarabb.ovp omarabb.ovf omarabb.ofm
If the last line does not work, try
#> ovp2ovf omarabb.ovp omarabb.ovf omarabb.tfm
rename omarab.tfm to omarab.ofm --> ofm directory
get omarab.ofm & rename to omarab.tfm
#> ovf2ovp omarabb.ovf omarabb.tfm omarabb.ovp
* For more info, there is also the (mostly cryptic) Omega manual [http://omega.enstb.org/roadmap/doc-1.12.ps in PS-Format]. Don't ask me why it's not in PDF. <tt>:-(</tt>
==To the future==
* The otp mechanism does not seem well suited to support, e.g., opentype OpenType GPOS tables, important for really advanced Arabic (though GDEF and GSUB should work fine with the present mechanism for most purposes). We need a better model for horizontal and vertical glyph substitutions.
* The low-level filtersequence mechanism needs to abstract language processing from font mapping. Right now both are hardwired into a single sequence, so setting up more than one font for a single language is more of a pain than it should be.
* The otp language is a bit cryptic. Hans has suggested switching otp's to a new language (like lua or io) but I don't know how hard that will be...
* One very important feature which may work better at the primitive/engine level by extending the pdfeTeX engine: glyph substitution that depends on the paragraph. For example: In traditional Arabic typography, one way to compensate for "underfull" paragraphs is to substitute a "swash" version of a letter. Another way is by stretching the cursive tie between joining characters (which is already implemented in my own Arabic system). Combined with HZ we can get some pretty interesting high-level options, effects, etc. that the user can choose etc.

Navigation menu