[XeTeX] lmsans font [was: from teTeX-3.0 to TeXLive 2007]

Mike Maxwell maxwell at umiacs.umd.edu
Wed Aug 22 15:21:16 CEST 2007


Bruno Voisin wrote:
> There must be something in the class file or one of the style files  
> used by your document which says that section titles are in \sffamily 
> \bfseries -- or \textsf{\textbf{. \setmainfont sets only the font for  
> the serif family (Times-like), you need \setsansfont for setting the  
> font for the sans-serif family (Helvetica-like), and \setmonofont for  
> setting the font for the monospaced family (Courier-like).

Thanks for your reply AND Jonathan's reply--they both help.

However, I have a more general question: how do I debug things like this 
without posting to this group?  I have a long list of glitches, and 
while I have been able to cross some of them off the list, it baffles me 
how you debug XeTeX.  If it were a programming language, I would use a 
debugger or stick some print commands in.  But that doesn't work here :-).

In this particular case, I realized there was a problem when someone 
else noticed that the IPA characters weren't showing up in certain 
places.  Those places turned out to be (at least) section titles.  At 
that point, I might have put 2 and 2 together and realized that it was a 
sans serif font problem, but I didn't.  So I went into the log, found 
the page the section title in question was on (made easier by the 
inclusion of page #s in the log), and found the warning that a character 
couldn't be found in this lmsans font.  (Again, the sub-string 'sans' 
should have been a clue, but...)

(Producing a minimal file that produced the error might also have gotten 
me here.)

But there the trail went cold; I couldn't figure out why that font was 
being called, or how to override it.

Looking at Bruno's msg above, I see why I couldn't figure it out: first, 
I didn't know to look for \sffamily or \textsf.  But now that I do know, 
I searched through my .xetex file (which, btw, is produced by DBlatex 
from my DocBook file) or the .log file; of the \commands above, only 
\textbf shows up, and I'm not sure that has anything to do with my problem.

Bruno's msg suggests that these \terms actually appear in one of "the 
class file or one of the style files".  How would I have figured that 
out?  And to find that file, do I have to look through every file in my 
TeX path?  Aren't there a lot of those files which are irrelevant?  Or 
is there some way to narrow the path to the packages actually used in my 
doc (and preferably, narrow the path and search for the command 
automatically)?
-- 
	Mike Maxwell
	maxwell at umiacs.umd.edu
	"Theorists...have merely to lock themselves in a room
	with a blackboard and coffee maker to conduct their business."
	--Bruce A. Schumm, Deep Down Things


More information about the XeTeX mailing list