[XeTeX] adding some diacritics to a font

Ross Moore ross at ics.mq.edu.au
Thu Jan 8 02:37:40 CET 2009


Hello Benct,

On 08/01/2009, at 3:40 AM, Benct Philip Jonsson wrote:

> On 2009-01-07 Ross Moore wrote:

>> Use the latter as follows.
>> Where  xunicode.sty  has a line
>>
>>     \DeclareUTFcomposite[\UTFencname]{x1E47}{\d}{n}
>>
>> After loading the package, simply include in your
>> preamble:
>>
>>     \UndeclareUTFcomposite[\UTFencname]{x1E47}{\d}{n}
>>
>> (Copy the \Declare... line from  xunicode.sty  and
>>   change the letters at the start of the macro-name.)
>> \UndeclareUTFcharacter  works the same way.
>>
>
> Should it really say '\UTFencname' literally, or should
> it be replaced by an actual encoding name (\utf8 or whatever)?

Mostly people never change the value of  \UTFencname
from its default of
    EU1 (if  fontspec  is loaded first)
or U  if xunicode.sty  is loaded first.
So if you never change  \UTFencname  then it doesn't
matter whether you use the macro or its value.


But there is nothing stopping you from using other values.
e.g.
      \newcommand{\UTFencname}{bubbles}
      \usepackage{xunicode}

will make all the same definitions work in "bubbles" encoding.


Also, you can read-in the file  xunicode.sty  more than once.
e.g.

   \newcommand{\UTFencname}{U2}
   \usepackage{xunicode}
   \UndeclareUTFcomposite[U2]....
   \UndeclareTFcharacter[U2]....
    ...

   \usepackage{fontspec}
   \newcommand{\UTFencname}{U6}
   \InputIfFileExists{xunicode.sty}{}{}

allows you to setup different encodings supporting
different subsets of characters; e.g. for use with
different fonts according to what they do/not support.


I believe that this ability is very useful for the
discussion that started this thread.


> _______________________________________________
>


Hope this helps,

	Ross


------------------------------------------------------------------------
Ross Moore                                       ross at maths.mq.edu.au
Mathematics Department                           office: E7A-419
Macquarie University                             tel: +61 (0)2 9850 8955
Sydney, Australia  2109                          fax: +61 (0)2 9850 8114
------------------------------------------------------------------------





More information about the XeTeX mailing list