[XeTeX] Newbie Question: Accessing Glyph

Marc van Dongen dongen at cs.ucc.ie
Tue Sep 14 08:44:21 CEST 2010


Michiel Kamermans <pomax at nihongoresources.com> wrote:

Hi Michiel,

: When switching from LaTeX to XeLaTeX, the first thing to realise is that 
: in XeLaTeX, you write your text in unicode, relying on the unicode way 
: of representing characters and character sequences. As such, the best 
: choice is to not "access glyphs" but to just put them directly in your 
: document: just use ?, ?, etc.
: 
: If you absolutely must access them through artificial means, you can use 
: \char:
: 
: \documentclass{article}
: \usepackage{fontspec}
: \setmainfont{Code2000}
: \begin{document}
: % "latin small letter long S"
: \char"017F
: \end{document}
: 
: but you shouldn't have to resort to this.

Thanks, I know XeTeX lets me enter unicode directly, but
I'm used to doing things the non-unicode way.  (I just
realised I've been using LaTeX for more than 20 years now.)
Also, using commands gives me more flexibility (if not then
I'd like to learn how). For example, if I wanted to I could
make a global change by making one local change in a command.
Of course I have to admit that I cannot see any use for this:)

: Diacritics are handled by the unicode-ness, too. You just type the text 
: that you want, relying on the unicode sequencing in your text editor to 
: get things right, and then you run xelatex with your file. You should 
: emphatically NOT use any of the LaTeX commands for adding diacritics.

I appreciate your advice but I'd really like to get the command right.

: Install Fontforge (should be in every major *nix's package list), use it 
: to open the desired font, and proceed to examine the hell out of it =)

Thanks.

Regards,


Marc van Dongen


More information about the XeTeX mailing list