ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* \namedglyph (was: [XeTeX] \XeTeXglyphindex: just a short note)
@ 2006-08-12  7:39 Mojca Miklavec
  2006-08-12 19:00 ` Hans Hagen
  0 siblings, 1 reply; 2+ messages in thread
From: Mojca Miklavec @ 2006-08-12  7:39 UTC (permalink / raw)
  Cc: Adam Lindsay, Will Robertson

Hello,

Some time ago Jonathan implemented a new \XeTeXglyphindex command to
retrieve the glyph from current font by name (it currently only works
for OpenType, but that's the most important). \getglyph is already
taken, I used it in the example below just because I didn't think of a
better name.

Would it name sense to provide a \namedglyph macro in ConTeXt for
XeTeX users as well? (Hopefully the feature will be available in
pdfTeX as well ;)

I don't mind if LaTeX & ConTeXt use the same syntax every now and then ;)

(In the future: It might make sense to provide an optional field to
retrieve a glyph from any font, not just from the current one, but I'm
not sure about what the exact interface should be and if it would be
optional it can be added later anyway.)

Any thoughts?

Mojca

On 8/12/06, Will Robertson wrote:
> On 11/06/2006, at 21:09 , Mojca Miklavec wrote:
>
> > \def\getglyph#1{\XeTeXglyph\XeTeXglyphindex "#1"}
> > \font\A='Antykwa Torunska' \A
> >
> > Thank you, Jonathan, I \getglyph{heart} this new feature!
>
> Just to follow up on this; for LaTeX users, the new version of the
> xltxtra package will include this macro under the name
> "\namedglyph" (it's actually Jonathan's improved version).
>
> Cheers,
>
> Will

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

* Re: \namedglyph (was: [XeTeX] \XeTeXglyphindex: just a short note)
  2006-08-12  7:39 \namedglyph (was: [XeTeX] \XeTeXglyphindex: just a short note) Mojca Miklavec
@ 2006-08-12 19:00 ` Hans Hagen
  0 siblings, 0 replies; 2+ messages in thread
From: Hans Hagen @ 2006-08-12 19:00 UTC (permalink / raw)


Mojca Miklavec wrote:
> Would it name sense to provide a \namedglyph macro in ConTeXt for
> XeTeX users as well? (Hopefully the feature will be available in
> pdfTeX as well ;)
>   
\namedglyph is too generic; you ask for a \fontglyph\font{name} and even then, there probably is not sucha primitive, but just a lua call which will consult the font data so that one can also take care of missign glyphs 
 
anyhow, such a command needs to be defined for each engine, with proper fallbacks which is not somthing i'm gonna do as a quick hack/fix.  

Now, for the moment you can use your definition which you can always (some time in the future) map onto a context one. This way of asking for a glyph is low level anyway. 

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] 2+ messages in thread

end of thread, other threads:[~2006-08-12 19:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-12  7:39 \namedglyph (was: [XeTeX] \XeTeXglyphindex: just a short note) Mojca Miklavec
2006-08-12 19:00 ` 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).