Re: [XeTeX] Diacritics in color

2011-12-03 Thread Khaled Hosny
On Sat, Dec 03, 2011 at 08:45:24AM +0200, Tobias Schoel wrote: On 02.12.2011 21:48, Ross Moore wrote: Hi Tobias, On 03/12/2011, at 6:06, Tobias Schoelliesdieda...@googlemail.com wrote: As a teacher I can think of some more Applications. Of course, these are pedagogical:

Re: [XeTeX] Diacritics in color

2011-12-02 Thread Khaled Hosny
OpenType has ligature caret info (in GDEF table) but is less flexible than what Graphite offers (only horizontal position is provided) and very few fonts, if any, have it. Regards, Khaled On Thu, Dec 01, 2011 at 01:56:45PM -0500, Karljurgen Feuerherm wrote: I seem to recall from the days when

Re: [XeTeX] Diacritics in color

2011-12-02 Thread Karljurgen Feuerherm
Thanks, Khaled. I realize the limitations etc.--just thought I'd note that these things are in some measure possible, if one wishes to implement them (not that one 'should', necessarily). In particular with regards to some recent posts, I seem to remember that glyph sub-definition was not limited

Re: [XeTeX] Diacritics in color

2011-12-02 Thread Ross Moore
Hi Tobias, On 03/12/2011, at 6:06, Tobias Schoel liesdieda...@googlemail.com wrote: As a teacher I can think of some more Applications. Of course, these are pedagogical: Teaching scripts to beginners (learning to write a primary school, learning to write in a different script when

Re: [XeTeX] Diacritics in color

2011-12-02 Thread Tobias Schoel
On 02.12.2011 21:48, Ross Moore wrote: Hi Tobias, On 03/12/2011, at 6:06, Tobias Schoelliesdieda...@googlemail.com wrote: As a teacher I can think of some more Applications. Of course, these are pedagogical: Teaching scripts to beginners (learning to write a primary school, learning to

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Aleksandr Andreev
Matthew Skala writes: Demonstration attached. Of course, the correct behavior in this case is that of Firefox: if I type: 기lt;FONT COLOR=REDgt;ᆷlt;/FONTgt; I get the precomposed Korean glyph all in black. Why? Because in the font (I don't have Jieubsida Dodum), the substitution rules tell us

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Khaled Hosny
On Wed, Nov 30, 2011 at 05:09:09PM -0600, msk...@ansuz.sooke.bc.ca wrote: On Wed, 30 Nov 2011, Khaled Hosny wrote: processed by the layout engine, which would require keeping account of character to glyph mapping (which is doable, all text editing GUI's have to do it). It will, of

Re: [XeTeX] Diacritics in color

2011-12-01 Thread mskala
On Thu, 1 Dec 2011, Khaled Hosny wrote: Suppose someone types f\textcolor{red}{f} In this case FireFox colourises half of resulting ff ligatures (1/3 in ffi etc), I'm not sure how this is done or if it is possible with PDF at I don't think XeTeX should attempt to do that. -- Matthew

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Philip TAYLOR
On Thu, 1 Dec 2011, Khaled Hosny wrote: Suppose someone types f\textcolor{red}{f} In this case FireFox colourises half of resulting ff ligatures (1/3 in ffi etc), And if you look at the rendered output, is there a single ff ligature-digraph glyph, or two f glyphs kerned ? Philip

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Karljurgen Feuerherm
It's not given that that's the only conceivable application. But even if it is, that's plenty useful in and of itself. K But I am willing to submit that this is a difficult task, and probably one of limited importance -- I can see it being useful only for people who for some reason need

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Karljurgen Feuerherm
I seem to recall from the days when I was doing demos/mock-ups for the cuneiform encoding proposal that SIL's graphite/WorldPad combo allowed one to do things of this sort; it involved specifying sub-areas in special font tables, which the software of course had to know about. Not sure whether

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Khaled Hosny
On Thu, Dec 01, 2011 at 09:35:29AM -0500, Aleksandr Andreev wrote: coloring components of a precomposed ligature. Clearly, that is impossible. Not entirely: http://robert.ocallahan.org/2006/10/partial-ligatures_24.html (OK, it is a hack, but far from being impossible)

Re: [XeTeX] Diacritics in color

2011-12-01 Thread Aleksandr Andreev
Khaled Hosny writes: Not entirely: http://robert.ocallahan.org/2006/10/partial-ligatures_24.html The page reads: Basically it's a hack --- a ligature with N characters is divided into N vertical strips of equal width which I pretend are pseudocharacters While that could work for a sans

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Heiko Oberdiek
On Wed, Nov 30, 2011 at 05:10:07AM +0200, Khaled Hosny wrote: A\textcolor{red}{0308}\\ % (3) It seems Charis SIL composes accented glyphs, try Gentium Basic instead (GenBasR.ttf). Thanks, the result is correct, the box contents after luacolor's processing is:

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Aleksandr Andreev
Khaled Hosny writes: use/build an OpenType font with proper combining mark positioning and apply the colors to individual glyphs à la what FireFox/LuaTeX and may be many other does. What I get out of this comment and the post by Heiko Oberdiek is that this should be possible to accomplish in

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Ross Moore
Hi Heiko, and others On 30/11/2011, at 8:56 PM, Heiko Oberdiek wrote: The PDF stuff: % without color: 0 -99.63 Td[0024]TJ 54.19 15.57 Td[0301]TJ % with color: -54.19 -115.2 Td[0024]TJ ET 1 0 0 RG 1 0 0 rg BT /F1 99.626 Tf 59.3 -278.84 Td[0301]TJ % with color via

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Keith J. Schultz
Hi Khaled, I am afraid you are completely misconceived about what the subject matter is here. 1) adding a diacritic mark(glyph) is composing a a glyph, You are able to output it on its own. 2) There is a difference between the glyph ä and adding the diactirc mark

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Khaled Hosny
On Wed, Nov 30, 2011 at 02:17:07PM -0500, Aleksandr Andreev wrote: Khaled Hosny writes: use/build an OpenType font with proper combining mark positioning and apply the colors to individual glyphs à la what FireFox/LuaTeX and may be many other does. What I get out of this comment and

Re: [XeTeX] Diacritics in color

2011-11-30 Thread Khaled Hosny
On Wed, Nov 30, 2011 at 09:47:31PM +0100, Keith J. Schultz wrote: Hi Khaled, I am afraid you are completely misconceived about what the subject matter is here. 1) adding a diacritic mark(glyph) is composing a a glyph, You are able to output it on its own. 2)

Re: [XeTeX] Diacritics in color

2011-11-30 Thread mskala
On Wed, 30 Nov 2011, Khaled Hosny wrote: processed by the layout engine, which would require keeping account of character to glyph mapping (which is doable, all text editing GUI's have to do it). It will, of course, have to do something sensible (even if that just means complain) should the

Re: [XeTeX] Diacritics in color

2011-11-30 Thread mskala
On Wed, 30 Nov 2011, msk...@ansuz.sooke.bc.ca wrote: In the Korean fonts I'm currently working on, some syllables are converted to single precomposed glyphs by ligature substitution, and others are built up by overlaying zero-width glyphs, and the difference between the I was interested to

Re: [XeTeX] Diacritics in color (was Re: XETEX cannot access OpenType features in PUA?)

2011-11-29 Thread Aleksandr Andreev
Ross Moore writes: Would you be so kind as to post the PDF from this? And where does one obtain the font MezenetsUnicode ? Mezenets Unicode is a font I'm developing for Znamenny neumatic notation and it is available here: http://www.ponomar.net/files/mezen_uni.ttf Attempting to encode

Re: [XeTeX] Diacritics in color (was Re: XETEX cannot access OpenType features in PUA?)

2011-11-29 Thread Philip TAYLOR
Aleksandr Andreev wrote: Mezenets Unicode is a font I'm developing for Znamenny neumatic notation Oohhh, this is exciting : [p]nuematic notation as in [p]neumes and as in [p]neumatic music ? Will this be a first for TeX, if you succeed ? Philip Taylor

Re: [XeTeX] Diacritics in color

2011-11-29 Thread Heiko Oberdiek
Hi Ross, On Wed, Nov 30, 2011 at 06:23:54AM +1100, Ross Moore wrote: Hi Heiko, On 29/11/2011, at 9:29 AM, Heiko Oberdiek wrote: The same also works in XeLaTeX: \documentclass{minimal} \usepackage{fontspec} \usepackage{color} \pagestyle{empty} \begin{document}

Re: [XeTeX] Diacritics in color

2011-11-29 Thread Heiko Oberdiek
On Wed, Nov 30, 2011 at 10:58:23AM +1100, Ross Moore wrote: On 30/11/2011, at 10:32 AM, Heiko Oberdiek wrote: or 00c4\\ A0308\\ A\textcolor{red}{0308} As you can see, this problem is not related to color, both XeTeX and LuaTeX fail: With this font (Latin

Re: [XeTeX] Diacritics in color

2011-11-29 Thread Aleksandr Andreev
Heiko Oberdiek writes: * LuaTeX: A + U+0308 gets combined to one glyph U+00C4, the color attribute of the diaeresis vanishes and the result is black (3). On my machine, in LuaTeX (3) results in a correctly positioned *red* diaeresis over a black A. (4) results in a red diaeresis with

Re: [XeTeX] Diacritics in color

2011-11-29 Thread Khaled Hosny
On Wed, Nov 30, 2011 at 02:09:47AM +0100, Heiko Oberdiek wrote: On Wed, Nov 30, 2011 at 10:58:23AM +1100, Ross Moore wrote: On 30/11/2011, at 10:32 AM, Heiko Oberdiek wrote: or 00c4\\ A0308\\ A\textcolor{red}{0308} As you can see, this problem is not

Re: [XeTeX] Diacritics in color

2011-11-29 Thread Khaled Hosny
On Wed, Nov 30, 2011 at 05:10:07AM +0200, Khaled Hosny wrote: It seems Charis SIL composes accented glyphs, After closer look, this is not entirely true; Charis SIL has AAT tables that, among other things, compose accented glyphs but the OpenType tables do mark positioning. LuaTeX shouldn't be

[XeTeX] Diacritics in color (was Re: XETEX cannot access OpenType features in PUA?)

2011-11-28 Thread Aleksandr Andreev
Jonathan Kew writes: Making this work in xetex would require a different approach to implementing color. I have been able to get it to work (the base glyph in black and the diacritic in red) in LuaTeX using the luacolor package. Here's a minimal example: \documentclass{minimal}

Re: [XeTeX] Diacritics in color (was Re: XETEX cannot access OpenType features in PUA?)

2011-11-28 Thread Ross Moore
Hi Aleks, On 29/11/2011, at 6:18 AM, Aleksandr Andreev wrote: Jonathan Kew writes: Making this work in xetex would require a different approach to implementing color. I have been able to get it to work (the base glyph in black and the diacritic in red) in LuaTeX using the luacolor

Re: [XeTeX] Diacritics in color (was Re: XETEX cannot access OpenType features in PUA?)

2011-11-28 Thread Heiko Oberdiek
On Mon, Nov 28, 2011 at 02:18:56PM -0500, Aleksandr Andreev wrote: Jonathan Kew writes: Making this work in xetex would require a different approach to implementing color. I have been able to get it to work (the base glyph in black and the diacritic in red) in LuaTeX using the