ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* XeTeX and built-in glyph generation
@ 2006-11-02 10:04 Philipp Reichmuth
  2006-11-02 10:48 ` Hans Hagen
  0 siblings, 1 reply; 5+ messages in thread
From: Philipp Reichmuth @ 2006-11-02 10:04 UTC (permalink / raw)


Hi,

I have a question regarding ConTeXt, XeTeX and the use of Unicode fonts 
with diacritic characters which I use quite a lot.  (Note also that I'm 
a novice user.)  Consider the following extreme example (using Gentium 
<http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=gentium>):

-------------------
\definetypeface[lucida][rm][Xserif][Lucida Bright]
\definetypeface[gentium][rm][Xserif][Gentium]
\setupbodyfont[gentium]

\starttext
Ṯḥíş ıš ā pìėçẹ ȯf ṭēxt.
\stoptext
-------------------

If you typeset this with 'texexec --xtx', you get very different results 
with Gentium vis-a-vis Lucida because of the different glyph repertoires 
of both fonts.  This is a bit unsatisfactory because ConTeXt has all the 
logic already in place to construct most of these these from base 
characters plus accents where needed.  Of course I can go through my 
Unicode text manually and change all the missing characters to something 
like \={e}, but that is not a good solution either; having to sift 
through your entire document because your publisher demands a different 
font makes you feel more than a bit stupid :)

Is there a way to tell ConTeXt what Unicode characters are available in 
a font and which ones it has to build using TeX's accent functions?  I 
guess in the above example it would be difficult because no regime gets 
loaded at all.  What would be ideal in my case would be a configurable 
UTF-8 regime where I could specify the following on a per-typeface basis:

- character[ range]s which get passed directly to the underlying engine 
(useful mainly with XeTeX and possibly with Aleph/Omega)
- character[ range]s which get constructed from accents
- character[ range]s which get used from a different typescript; for 
example if I have passages or quotations in a script which isn't 
available in my typescript, it would be nice to say that "all 
IPA/Greek/Old Church Slavonic" should come from a substitution 
typescript where these scripts are available and look good.

Is such a thing possible?

Philipp

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: XeTeX and built-in glyph generation
  2006-11-02 10:04 XeTeX and built-in glyph generation Philipp Reichmuth
@ 2006-11-02 10:48 ` Hans Hagen
  2006-11-02 11:15   ` Philipp Reichmuth
  0 siblings, 1 reply; 5+ messages in thread
From: Hans Hagen @ 2006-11-02 10:48 UTC (permalink / raw)


Philipp Reichmuth wrote:
> - character[ range]s which get passed directly to the underlying engine 
> (useful mainly with XeTeX and possibly with Aleph/Omega)
> - character[ range]s which get constructed from accents
> - character[ range]s which get used from a different typescript; for 
> example if I have passages or quotations in a script which isn't 
> available in my typescript, it would be nice to say that "all 
> IPA/Greek/Old Church Slavonic" should come from a substitution 
> typescript where these scripts are available and look good.
>
> Is such a thing possible?
>   
we're going to built that kind of logic (and a bit more) into luatex / context mkiv ; after that we can see to what extend we can support the xetex way as well 



after tug 2006 we enter the font part pf the luatex/orientaltex project

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: XeTeX and built-in glyph generation
  2006-11-02 10:48 ` Hans Hagen
@ 2006-11-02 11:15   ` Philipp Reichmuth
  2006-11-02 11:50     ` Philipp Reichmuth
  2006-11-02 11:57     ` Hans Hagen
  0 siblings, 2 replies; 5+ messages in thread
From: Philipp Reichmuth @ 2006-11-02 11:15 UTC (permalink / raw)


Hans Hagen schrieb:
> Philipp Reichmuth wrote:
>> - character[ range]s which get passed directly to the underlying engine 
>> (useful mainly with XeTeX and possibly with Aleph/Omega)
>> - character[ range]s which get constructed from accents
>> - character[ range]s which get used from a different typescript; for 
>> example if I have passages or quotations in a script which isn't 
>> available in my typescript, it would be nice to say that "all 
>> IPA/Greek/Old Church Slavonic" should come from a substitution 
>> typescript where these scripts are available and look good.
>
> we're going to built that kind of logic (and a bit more) into luatex / context mkiv ; after that we can see to what extend we can support the xetex way as well 
> 
> after tug 2006 we enter the font part pf the luatex/orientaltex project

OK.  Sounds great.  If you need a tester, I'll be more than happy to 
provide lots of awkward cases and sift through them.

In the meantime, is it possible to enable/disable ConTeXt's UTF-8 
handler selectively for pieces of text?  such as:

\starttext
\enableregime[utf]
- some Unicode text processed by CoNTeXt for diacritics etc. -
\disableregime[utf]
- some Unicode text in some other script processed natively by XeTeX -
\stoptext

That would do the job in the meantime.

Philipp

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: XeTeX and built-in glyph generation
  2006-11-02 11:15   ` Philipp Reichmuth
@ 2006-11-02 11:50     ` Philipp Reichmuth
  2006-11-02 11:57     ` Hans Hagen
  1 sibling, 0 replies; 5+ messages in thread
From: Philipp Reichmuth @ 2006-11-02 11:50 UTC (permalink / raw)


Philipp Reichmuth schrieb:
> In the meantime, is it possible to enable/disable ConTeXt's UTF-8 
> handler selectively for pieces of text?

I just tried

--------------------------------
\definetypeface[lucida][rm][Xserif][Lucida Bright]
\setupbodyfont[lucida]

\starttext
Ṯḥíş ıš ā pìėçẹ ȯf ṭēxt.

\XeTeXinputencoding "bytes"
\enableregime[utf]
Ṯḥíş ıš ā pìėçẹ ȯf ṭēxt.

\XeTeXinputencoding "utf-8"
Ṯḥíş ıš ā pìėçẹ ȯf ṭēxt.
\stoptext
--------------------------------
which doesn't work.  I experimented around with commenting out the XeTeX 
section in base/regi-uni.tex, but that doesn't do anything.

Is there a way of reenabling this from the ConTeXt side?

Philipp

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: XeTeX and built-in glyph generation
  2006-11-02 11:15   ` Philipp Reichmuth
  2006-11-02 11:50     ` Philipp Reichmuth
@ 2006-11-02 11:57     ` Hans Hagen
  1 sibling, 0 replies; 5+ messages in thread
From: Hans Hagen @ 2006-11-02 11:57 UTC (permalink / raw)


Philipp Reichmuth wrote:
> Hans Hagen schrieb:
>   
>> Philipp Reichmuth wrote:
>>     
>>> - character[ range]s which get passed directly to the underlying engine 
>>> (useful mainly with XeTeX and possibly with Aleph/Omega)
>>> - character[ range]s which get constructed from accents
>>> - character[ range]s which get used from a different typescript; for 
>>> example if I have passages or quotations in a script which isn't 
>>> available in my typescript, it would be nice to say that "all 
>>> IPA/Greek/Old Church Slavonic" should come from a substitution 
>>> typescript where these scripts are available and look good.
>>>       
>> we're going to built that kind of logic (and a bit more) into luatex / context mkiv ; after that we can see to what extend we can support the xetex way as well 
>>
>> after tug 2006 we enter the font part pf the luatex/orientaltex project
>>     
>
> OK.  Sounds great.  If you need a tester, I'll be more than happy to 
> provide lots of awkward cases and sift through them.
>
> In the meantime, is it possible to enable/disable ConTeXt's UTF-8 
> handler selectively for pieces of text?  such as:
>
> \starttext
> \enableregime[utf]
> - some Unicode text processed by CoNTeXt for diacritics etc. -
> \disableregime[utf]
> - some Unicode text in some other script processed natively by XeTeX -
> \stoptext
>
> That would do the job in the meantime.
>
>   
hm, dunno, this is related to active characters (>255) and such; 
currently the utf handler is disables in xetex mode

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-11-02 11:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-02 10:04 XeTeX and built-in glyph generation Philipp Reichmuth
2006-11-02 10:48 ` Hans Hagen
2006-11-02 11:15   ` Philipp Reichmuth
2006-11-02 11:50     ` Philipp Reichmuth
2006-11-02 11:57     ` Hans Hagen

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).