[XeTeX] fontspec location problems in MiKTeX

Michiel Kamermans pomax at nihongoresources.com
Tue Oct 5 23:15:42 CEST 2010


I tried updating to MiKTeX 2.9 beta, to see if that solved the problem - 
everything now at least resolves to the right location, but fontspec is 
exhibiting a different problem. Take the following UTF-8 encoded .tex file:

\documentclass{article}
\usepackage{fontspec}
\setmainfont{MS Mincho}
\begin{document}
This is text - にほんご
\end{document}

This compiles without errors, but gives the following as PDF output:

Sghr hr sdws , ➢➳々➈

That really doesn't look like the text it should be, all the Latin 
letters (including - but not including space!) are shifted one 
alphabetical position, and the Japanese has been completely destroyed 
(に, U+306B, dec 12395, utf-bin {1110.0011-10.000001-10.101011}, has 
been turned into ➢, U+27A2, dec 10146, bin 
{1110.0010-10.011110-10.100010}). The off-by-one for Latin seems an 
honest mistake, but it also looks like it's doing something creative to 
each byte in a set of UTF8 bytes, subtracting 1 in a creative way... but 
not for the last byte, where it's removing 9...

Anyway, the log gives the following information:

This is XeTeX, Version 3.1415926-2.2-0.9997.4 (MiKTeX 2.9 Beta 1) 
(preloaded format=xelatex 2010.10.5) 5 OCT 2010 22:52
entering extended mode
...
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
...
Package: fontspec 2010/09/29 v2.1b Advanced font selection for 
XeLaTeX/LuaLaTeX
...
Package: fontspec-patches 2010/09/29 v2.1b Advanced font selection for 
XeLaTeX/LuaLaTeX
...
("C:\Program Files (x86)\MiKTeX 2.9\tex\xelatex\xunicode\xunicode.sty"
File: xunicode.sty 2008/02/08 v0.91 provides access to latin accents and 
many other characters in Unicode lower plane)
LaTeX Info: Defining document command \fontspec
(LaTeX) with arg. spec. 'O{}m' on line 315.
LaTeX Info: Defining document command \setmainfont
(LaTeX) with arg. spec. 'O{}m' on line 319.
LaTeX Info: Defining document command \setsansfont
(LaTeX) with arg. spec. 'O{}m' on line 323.
LaTeX Info: Defining document command \setmonofont
(LaTeX) with arg. spec. 'O{}m' on line 327.
LaTeX Info: Defining document command \setmathrm
(LaTeX) with arg. spec. 'O{}m' on line 331.
LaTeX Info: Defining document command \setboldmathrm
(LaTeX) with arg. spec. 'O{}m' on line 334.
LaTeX Info: Defining document command \setmathsf
(LaTeX) with arg. spec. 'O{}m' on line 337.
LaTeX Info: Defining document command \setmathtt
(LaTeX) with arg. spec. 'O{}m' on line 340.
LaTeX Info: Defining document command \newfontfamily
(LaTeX) with arg. spec. 'mO{}m' on line 356.
LaTeX Info: Defining document command \newfontface
(LaTeX) with arg. spec. 'mO{}m' on line 359.
LaTeX Info: Defining document command \defaultfontfeatures
(LaTeX) with arg. spec. 'm' on line 362.
LaTeX Info: Defining document command \addfontfeatures
(LaTeX) with arg. spec. 'm' on line 379.
LaTeX Info: Defining document command \newfontfeature
(LaTeX) with arg. spec. 'mm' on line 386.
LaTeX Info: Defining document command \newAATfeature
(LaTeX) with arg. spec. 'mmmm' on line 395.
LaTeX Info: Defining document command \newICUfeature
(LaTeX) with arg. spec. 'mmm' on line 404.
LaTeX Info: Defining document command \aliasfontfeature
(LaTeX) with arg. spec. 'mm' on line 406.
LaTeX Info: Defining document command \aliasfontfeatureoption
(LaTeX) with arg. spec. 'mmm' on line 409.
LaTeX Info: Defining document command \newfontscript
(LaTeX) with arg. spec. 'mm' on line 414.
LaTeX Info: Defining document command \newfontlanguage
(LaTeX) with arg. spec. 'mm' on line 432.
LaTeX Info: Defining document command \DeclareFontsExtensions
(LaTeX) with arg. spec. 'm' on line 449.

\c at fontspec_tmp_int=\count168
LaTeX Info: Redefining \itshape on input line 2016.
LaTeX Info: Redefining \slshape on input line 2020.
LaTeX Info: Redefining \scshape on input line 2024.
LaTeX Info: Redefining \upshape on input line 2028.

("C:\Program Files (x86)\MiKTeX 2.9\tex\latex\fontspec\fontspec.cfg"))
fontspec Info: Font MS Mincho does not contain any OpenType `Script' 
information.

\g_fontspec_family_MS Mincho_int=\count169
fontspec Info: Defining font family for 'MS Mincho' with options [].
fontspec Info: Defining shape 'normal' with NFSS specification:
(fontspec) <->"MS Mincho/ICU:"
fontspec Info: Could not resolve font MS Mincho/B (it probably doesn't 
exist).
fontspec Info: Could not resolve font MS Mincho/I (it probably doesn't 
exist).
fontspec Info: Could not resolve font MS Mincho/BI (it probably doesn't 
exist)
.
(c:\Users\Mike\Documents\ucharclasses\test.aux)
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for EU1/lmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
fontspec Info: Adjusting the maths setup (use [no-math] to avoid this).

\symlegacymaths=\mathgroup4
LaTeX Font Info: Overwriting symbol font `legacymaths' in version `bold'
(Font) OT1/cmr/m/n --> OT1/cmr/bx/n on input line 4.
LaTeX Font Info: Redeclaring math accent \acute on input line 4.
LaTeX Font Info: Redeclaring math accent \grave on input line 4.
LaTeX Font Info: Redeclaring math accent \ddot on input line 4.
LaTeX Font Info: Redeclaring math accent \tilde on input line 4.
LaTeX Font Info: Redeclaring math accent \bar on input line 4.
LaTeX Font Info: Redeclaring math accent \breve on input line 4.
LaTeX Font Info: Redeclaring math accent \check on input line 4.
LaTeX Font Info: Redeclaring math accent \hat on input line 4.
LaTeX Font Info: Redeclaring math accent \dot on input line 4.
LaTeX Font Info: Redeclaring math accent \mathring on input line 4.
LaTeX Font Info: Redeclaring math symbol \colon on input line 4.
LaTeX Font Info: Redeclaring math symbol \Gamma on input line 4.
LaTeX Font Info: Redeclaring math symbol \Delta on input line 4.
LaTeX Font Info: Redeclaring math symbol \Theta on input line 4.
LaTeX Font Info: Redeclaring math symbol \Lambda on input line 4.
LaTeX Font Info: Redeclaring math symbol \Xi on input line 4.
LaTeX Font Info: Redeclaring math symbol \Pi on input line 4.
LaTeX Font Info: Redeclaring math symbol \Sigma on input line 4.
LaTeX Font Info: Redeclaring math symbol \Upsilon on input line 4.
LaTeX Font Info: Redeclaring math symbol \Phi on input line 4.
LaTeX Font Info: Redeclaring math symbol \Psi on input line 4.
LaTeX Font Info: Redeclaring math symbol \Omega on input line 4.
LaTeX Font Info: Redeclaring math symbol \mathdollar on input line 4.
LaTeX Font Info: Redeclaring symbol font `operators' on input line 4.
LaTeX Font Info: Encoding `OT1' has changed to `EU1' for symbol font
(Font) `operators' in the math version `normal' on input line 4.
LaTeX Font Info: Overwriting symbol font `operators' in version `normal'
(Font) OT1/cmr/m/n --> EU1/MSMincho(0)/m/n on input line 4.
LaTeX Font Info: Encoding `OT1' has changed to `EU1' for symbol font
(Font) `operators' in the math version `bold' on input line 4.
LaTeX Font Info: Overwriting symbol font `operators' in version `bold'
(Font) OT1/cmr/bx/n --> EU1/MSMincho(0)/m/n on input line 4.
LaTeX Font Info: Overwriting symbol font `operators' in version `normal'
(Font) EU1/MSMincho(0)/m/n --> EU1/MSMincho(0)/m/n on input li
ne 4.
LaTeX Font Info: Overwriting math alphabet `\mathrm' in version `normal'
(Font) EU1/MSMincho(0)/m/n --> EU1/MSMincho(0)/m/n on input li
ne 4.
LaTeX Font Info: Overwriting math alphabet `\mathit' in version `normal'
(Font) OT1/cmr/m/it --> EU1/MSMincho(0)/m/it on input line 4.
LaTeX Font Info: Overwriting math alphabet `\mathbf' in version `normal'
(Font) OT1/cmr/bx/n --> EU1/MSMincho(0)/bx/n on input line 4.
LaTeX Font Info: Overwriting math alphabet `\mathsf' in version `normal'
(Font) OT1/cmss/m/n --> EU1/lmss/m/n on input line 4.
LaTeX Font Info: Overwriting math alphabet `\mathtt' in version `normal'
(Font) OT1/cmtt/m/n --> EU1/lmtt/m/n on input line 4.
LaTeX Font Info: Overwriting symbol font `operators' in version `bold'
(Font) EU1/MSMincho(0)/m/n --> EU1/MSMincho(0)/bx/n on input l
ine 4.
LaTeX Font Info: Overwriting math alphabet `\mathrm' in version `bold'
(Font) EU1/MSMincho(0)/m/n --> EU1/MSMincho(0)/bx/n on input l
ine 4.
LaTeX Font Info: Overwriting math alphabet `\mathit' in version `bold'
(Font) OT1/cmr/bx/it --> EU1/MSMincho(0)/bx/it on input line 4
.
LaTeX Font Info: Overwriting math alphabet `\mathsf' in version `bold'
(Font) OT1/cmss/bx/n --> EU1/lmss/bx/n on input line 4.
LaTeX Font Info: Overwriting math alphabet `\mathtt' in version `bold'
(Font) OT1/cmtt/m/n --> EU1/lmtt/bx/n on input line 4.
[1

]
(c:\Users\Mike\Documents\ucharclasses\test.aux) )
Here is how much of TeX's memory you used:
9615 strings out of 429300
168598 string characters out of 3169645
234787 words of memory out of 3000000
12818 multiletter control sequences out of 15000+200000
3664 words of font info for 17 fonts, out of 3000000 for 9000
669 hyphenation exceptions out of 8191
38i,4n,35p,496b,158s stack positions out of 5000i,500n,10000p,200000b,50000s

Output written on test.pdf (1 page).


Does anyone have an idea what's going on? Still some bugs in fontspec? A 
glance at MS Mincho's font properties reveals it does seem to have 
OpenType Script information, for instance.

- Mike "Pomax" Kamermans
nihongoresources.com



More information about the XeTeX mailing list