[XeTeX] xetex and xfrac?

Stephen Moye stephenmoye at mac.com
Thu Dec 4 15:19:55 CET 2008


 
On Thursday, December 04, 2008, at 06:04AM, "Axel E. Retif" <axel.retif at mac.com> wrote:
>On  4 Dec, 2008, at 04:50, Axel E. Retif wrote:
>
>> On  3 Dec, 2008, at 10:46, Stephen Moye wrote:
>>
>>> I have tried to get xfrac to work using xetex and fontspec, but have
>>> had only limited success. If, for example, I set
>
>[...]
>
>>> \DeclareInstance{xfrac}{"Goudy Std"}{text}{%
>>> 	slash-right-kern = 1pt,
>>> 	slash-left-kern	= 1pt,
>>> }
>>>
>>> but this does not seem to do anything. [...]
>>
>> I guess xfrac doesn't understand fonts that way, but with the tfm
>> family names (cmr, for Computer Modern; hlh, for Lucida, etc.); but  
>> try
>>
>> \DeclareInstance{xfrac}{default}{text}{%
>> 	slash-right-kern = 1pt,
>> 	slash-left-kern	= 1pt,
>> }
>>
>> This will affect sfrac in san serif and italics as well, though.
>
>There is a way to avoid this ---say you don't want that change in your  
>san serif font, but only in roman and italics, then
>
>\DeclareInstance{xfrac}{default}{text}{%
>	slash-right-kern = 1pt,
>	slash-left-kern	= 1pt,
>}
>\DeclareInstance{xfrac}{sanserif}{text}{%
>	slash-right-kern = 0pt,
>	slash-left-kern	= 0pt,
>}
>
>\sfrac{1}{2}, \textit{\sfrac{1}{2}}, \textsf{\sfrac[sanserif]{1}{2}}.
>
>Best,
>
>Axel

Better and better. 

Thank you again.

Stephen


More information about the XeTeX mailing list