rgheck wrote:
On 10/05/2009 01:36 PM, Daniel Owens wrote:
I am working on a dissertation class for my school, and I need to use
XeTeX. The class is working well using LaTeX, but when I create a
layout file for LyX to use the class, it ignores the commands for
using TrueType fonts, so Greek is not typeset. I don't have this
problem in LyX if I just use a *.sty file instead of a class. Then
LyX handles XeTeX very well. Does anyone have any theories about what
is going on? The only thing I can think of is that my layout file is
doing something to interfere with XeTeX. It compiles okay just
without the right fonts.
I have no idea what is happening, but here's how to find out.
Construct some simple test file that exhibits the behavior you
mention, i.e., it works with the sty and not with the cls. Now export
both to LaTeX. Look carefully at the preamble and in particular at the
order in which things are being loaded. Somewhere in there is probably
the difference. If not, then check the order in which things are
being loaded in your class and style files. Maybe it's there.
rh
So, I did what you suggested, and I am getting closer to solving the
mystery. Both preambles are pretty much the same, and it is actually
something which is present in both which causes the problem:
\usepackage[T1]{fontenc}
If I comment out the above line in the file utilizing wheaton.cls (which
basically just points to wheaton.sty), it solves the problem, but the
file using wheaton.sty directly can have the line and there is not
problem. I don't think it has anything to do with my LyX layout file. It
would seem to be related to how I have constructed the class file or
something. Is there any way to prevent LyX from adding the line above?
Here is the class file:
\ProvidesClass{wheaton}[2009/10/04 Wheaton College Dissertation Class]
\LoadClass[letterpaper,oneside,12pt,titlepage]{memoir}
\usepackage{wheaton}
\setromanfont{Times New Roman}
\newfontfamily\hebrewfont[Script=Hebrew]{SBL Hebrew}
\newfontfamily\greekfont[Script=Greek]{SBL Greek}
\RequirePackage[babel=once,english=american]{csquotes}
Daniel