Firstly, hello to all listmembers from a new member and first-time poster --- please excuse any accidental breach of list etiquette in my initial postings :-) I would just like to start by saying a huge thank-you to Hans, Taco and the LuaTeX team for producing this wonderful, facinating, piece of software. Thanks also to whoever wrote the rsynch-based installation of the ConTeXt minimals, it worked **beautifully** on my Windows Vista laptop. I've come back to using TeX after a gap of a few years and I have to say that I am quite addicted to LuaTeX already. I have, in the recent past, programmed (mostly as a hobby) in C, Perl, PostScript etc --- so I am very keen to learn more about LuaTeX, and get to grips with it. There is much to learn, I am sure! My personsal interest is to use LuaTeX as a tool in my (self-teaching) studies of learning Arabic. Incidentally, that is how I discovered LuaTeX, through the videos of Idris' talks at the River-Valley site. Specifically, I want to keep notes of my Arabic studies in a nice way, so LuaTeX looks perfect for that. And so to my question. I would very much like to explore using (or writing (eventually...)???) commands that let me "format" Arabic words etc as part of my notes. I have not explored this yet, so I apologise if this is already possible 'out of the box'. I just wanted to ask the experts here, before spending too much time exploring the wrong things! For example, I would like to be able to use colour with certain glyphys in (any location) within Arabic words. For example \somecommand{Arabic text} where \somecommand{...} would (for example) put certain glyphs in colour --- particularly for grammar, where you are writing out verb tables, or dual/plural endings for adjectives/nouns etc. In essence, where do I need to start exploring to be able to write such things --- LuaTeX node processing, colour attributes etc?? Any pointers or guidance to help me start looking in the right place would be very welcome. Warm wishes to all Graham Douglas
Graham Douglas wrote:
And so to my question. I would very much like to explore using (or writing (eventually...)???) commands that let me "format" Arabic words etc as part of my notes. I have not explored this yet, so I apologise if this is already possible 'out of the box'. I just wanted to ask the experts here, before spending too much time exploring the wrong things!
The expert on the practical side of this would be Idris, but he is on the road for a while. If you want to make sure to get his attention, best would be to email him personally.
For example, I would like to be able to use colour with certain glyphys in (any location) within Arabic words. For example \somecommand{Arabic text} where \somecommand{...} would (for example) put certain glyphs in colour --- particularly for grammar, where you are writing out verb tables, or dual/plural endings for adjectives/nouns etc.
You can use \color in the middle of an arabic word without disrupting anything in the processing, so perhaps it would be good enough to just do something like this: \def\coloredalef{{\color[green]ا}} \catcode`ا=\active \defا{\coloredalef} but for more advanced stuff, node processing will be needed.
In essence, where do I need to start exploring to be able to write such things --- LuaTeX node processing, colour attributes etc??
I would have to say: the context source code (for now). There are no articles specifically on luatex node/attribute processing yet, just the reference manual. Best wishes, Taco
On 8-3-2010 10:38, Taco Hoekwater wrote:
Graham Douglas wrote:
And so to my question. I would very much like to explore using (or writing (eventually...)???) commands that let me "format" Arabic words etc as part of my notes. I have not explored this yet, so I apologise if this is already possible 'out of the box'. I just wanted to ask the experts here, before spending too much time exploring the wrong things!
The expert on the practical side of this would be Idris, but he is on the road for a while. If you want to make sure to get his attention, best would be to email him personally.
For example, I would like to be able to use colour with certain glyphys in (any location) within Arabic words. For example \somecommand{Arabic text} where \somecommand{...} would (for example) put certain glyphs in colour --- particularly for grammar, where you are writing out verb tables, or dual/plural endings for adjectives/nouns etc.
You can use \color in the middle of an arabic word without disrupting anything in the processing, so perhaps it would be good enough to just do something like this:
\def\coloredalef{{\color[green]ا}} \catcode`ا=\active \defا{\coloredalef}
but for more advanced stuff, node processing will be needed.
In essence, where do I need to start exploring to be able to write such things --- LuaTeX node processing, colour attributes etc??
I would have to say: the context source code (for now). There are no articles specifically on luatex node/attribute processing yet, just the reference manual.
we have been working on an experimental mechanism 'font goodies' which provides means to enhance fonts and one application is coloring arabic for instance, for the husayni font (by idris, presented last week at the dante meeting), we have a goodies file that looks like: return { name = "husayni", version = "1.00", comment = "Goodies that complement the Husayni font by Idris Samawi Hamid.", author = "Idris Samawi Hamid and Hans Hagen", featuresets = { default = { basics, analysis, regular, positioning, -- xxxx = yes, yyyy = 2, }, }, stylistics = { ss01 = "Allah, Muhammad", .... ss55 = "idgham-tanwin", js01 = "Raawide", .... js21 = "Haa.final_alt2", }, colorschemes = { default = { [1] = { "Onedotabove", "Onedotbelow", "Twodotsabove", "Twodotsbelow", "Threedotsabove", "Twodotsabove.vrt", "Twodotsbelow.vrt", "Twodotsabove.KBA", "Threedotsabove.KBA", "Threedotsbelowinv", "Hamzahabove", "Hamzahbelow", "MaaddahHamzah.identity", "Waslah","Hamzah.initial_medial", }, .... [5] = { "Ayah", "Ayah.alt1", "Ayah.alt2", "Ayah.alt3", "Ayah2", } } } } Of course such a file should match a font, but it permits things like: \definefontfeature [husayni-colored] [goodies=husayni, colorscheme=default, featureset=default] I can imagine that we make a collection of goodies for fonts that make sense. Concerning the arabic ... best coordinate this with idris as he's working on the benchmark arabic font. And no, this is not documentted (yet) apart from an 'article' in hybrid.pdf which is not net on line. Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 08.03.10 10:53, schrieb Hans Hagen:
we have been working on an experimental mechanism 'font goodies' which provides means to enhance fonts and one application is coloring arabic Will it then be also possible to assign a single color to a complete font, e.g.
\definefontfeature[blue][default][color=blue] \starttext {\setfontfeature[blue]Blue text} gives the same result as \color[blue]{blue text} \stoptext Wolfgang
On 8-3-2010 11:18, Wolfgang Schuster wrote:
Am 08.03.10 10:53, schrieb Hans Hagen:
we have been working on an experimental mechanism 'font goodies' which provides means to enhance fonts and one application is coloring arabic Will it then be also possible to assign a single color to a complete font, e.g.
\definefontfeature[blue][default][color=blue]
\starttext
{\setfontfeature[blue]Blue text}
gives the same result as
\color[blue]{blue text}
\stoptext
No, at least not now as i see color as completely unrelated to fonts. In the case of arabic it's part of the tradition to color certain glyphs. Of course it's possible to implement it but somehow coloring a whole font sounds like a hack to me (as we have style/color pairs in setups already). Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Am 08.03.10 11:39, schrieb Hans Hagen:
Will it then be also possible to assign a single color to a complete font, e.g. [...] No, at least not now as i see color as completely unrelated to fonts. In the case of arabic it's part of the tradition to color certain glyphs.
Of course it's possible to implement it but somehow coloring a whole font sounds like a hack to me (as we have style/color pairs in setups already). OK, you’re the boss.
Wolfgang
On 8-3-2010 13:08, Wolfgang Schuster wrote:
Am 08.03.10 11:39, schrieb Hans Hagen:
Will it then be also possible to assign a single color to a complete font, e.g. [...] No, at least not now as i see color as completely unrelated to fonts. In the case of arabic it's part of the tradition to color certain glyphs.
Of course it's possible to implement it but somehow coloring a whole font sounds like a hack to me (as we have style/color pairs in setups already). OK, you’re the boss.
well, that's a weak argument for not pressing me -) btw, adding color as option to a font would slow down font switching etc significantly ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Just a short note to thank everyone for their various comments. I will read some more and see how far I can get... and come back when I can formulate some more precise (better) questions. Am reading through the reference manual --- LuaTeX's versatility is quite incredible. Warm regards to all. Graham
participants (6)
-
Arthur Reutenauer
-
Graham Douglas
-
Hans Hagen
-
Taco Hoekwater
-
Thomas A. Schmitz
-
Wolfgang Schuster