Hi

With Lyx lyx-1.1.5, I set up a new layout file based on the newlfm
package for letters and memnos, and a template file.  I installed
these in 

      /share/store/lyx-1.1.5/share/lyx/layouts/smtl-letter.layout
and 
     /share/store/lyx-1.1.5/share/lyx/templates/SMTL-letter.lyx
      
The reason for these locations is that this is our NFS server, and it
allows us to keep different versions of S/W on it, and we use links to 
make the current version available.

I have lyx-1.1.6 running now, and so I copied the files to the same
place but in the  

      /share/store/lyx-1.1.6/share/lyx 

hierarchy.

The template comes up in Lyx, but when I try to print, I get the
following message:

  Undefined control sequence.\LoadClassWithOptions
                  {letter}%
  the control sequence at the end of the top line
  of your error message was never \def'ed. If you have misspelled it
  ....... Otherwise just continue and I'll forget about whatever was
  undefined.

Now it must be OK under latex, because when I run lyx 1.1.5, it all
works perfectly.  Has something changed between 1.1.5 and 1.1.6 ?

Layout and template file attached.
Regards,
Pete

-------------------------LAYOUT FILE------------------------------------
#% Do not delete he line below; configure depends on this
#  \DeclareLaTeXClass[newlfm]{letter (SMTL)}
# Letter textclass definition file. 
# Author : Thomas Hartkens <[EMAIL PROTECTED]>

# Input general definitions
# Input stdletter.inc




# General textclass parameters
Columns                 1
Sides                   1
PageStyle               Empty

Preamble
        \lthSMTL
EndPreamble

# This is just to show how to declare the default font.
# The defaults are exactly those shown here.
DefaultFont
  Family                Roman
  Series                Medium
  Shape                 Up
  Size                  Normal
  Color                 None
EndFont

ClassOptions
        Other "stdletter,printallfrom,a4paper,orderfromdateto,dvips"
        FontSize        "10|11|12"
End



# Letter style definition
# This includes the signature for SMTL Letters
Style Letter
  Margin                Static
  LatexType             Environment
  LatexName             newlfm
  ParSkip               0.4
  ParIndent             MM
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left, Right, Center
  LabelType             Top_Environment
  LabelString           Letter:
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End






# Signature Block of Sender
Style Signame
  Margin                Static
  LatexType             Command
  LatexName             signame
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Signature:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Name and title of sender
Style NameFrom
  Margin                Static
  LatexType             Command
  LatexName             name
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           NameFrom:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End
Style AddressFrom
  Margin                Static
  LatexType             Command
  LatexName             addrfrom
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           AddressFrom:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End


# Telefon
Style PhoneFrom
  Margin                Static
  LatexType             Command
  LatexName             phonefrom
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  TopSep                1.5
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           PhoneTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Telefax
Style FaxFrom
  Margin                Static
  LatexType             Command
  LatexName             faxfrom
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           FaxFrom:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# email  of sender
Style EmailFrom
  Margin                Static
  LatexType             Command
  LatexName             emailfrom
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           EmailFrom:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End



# Name and title of sender
Style NameTo
  Margin                Static
  LatexType             Command
  LatexName             nameto
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           NameTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

Style AddressTo
  Margin                Static
  LatexType             Command
  LatexName             addrto
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           AddressTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End


# Telefon
Style PhoneTo
  Margin                Static
  LatexType             Command
  LatexName             phoneto
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  TopSep                1.5
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           PhoneTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Telefax
Style FaxTo
  Margin                Static
  LatexType             Command
  LatexName             faxto
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           FaxTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# email  of sender
Style EmailTo
  Margin                Static
  LatexType             Command
  LatexName             emailto
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           EmailTo:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End



# Subject
Style Subject
  Margin                Static
  LatexType             Command
  LatexName             re
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  TopSep                1.5
  ParSep                0.4
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Subject:
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Subject (extra)
Style SubjectExtra
  Margin                Static
  LatexType             Command
  LatexName             subre
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  TopSep                1.5
  ParSep                0.4
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Subject(Extra):
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Greeting
Style Greeting
  Margin                Static
  LatexType             Command
  LatexName             greetto
  KeepEmpty             1  
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  TopSep                1.5
  ParSep                0.4
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Greeting:

  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End




# Enclosures
Style Encl.
  Margin                Static
  LatexType             Command
  LatexName             encllist
  KeepEmpty             1  
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  ParSep                0.4
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Encl.: 
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Enclosures
Style PS
  Margin                Static
  LatexType             Command
  LatexName             psitem
  KeepEmpty             1  
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  ParSep                0.4
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           PS: 
  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End

# Verteiler style definition
Style CC
  Margin                Static
  LatexType             Command
  LatexName             cclist
  KeepEmpty             1  
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  ParSep                0.4
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           cc:

  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End




# Gruss style definition
Style Closing
  Margin                Static
  LatexType             Command
  LatexName             closeline
  LeftMargin            xxxxxxxxxx::xx
  LabelSep              xx
  BottomSep             1.5
  ParSep                0.4
  KeepEmpty             1  
  Align                 Block
  AlignPossible         Block, Left
  LabelType             Static
  LabelString           Closing:

  # label font definition
  LabelFont 
    Series              Bold
    Shape               Italic
    Color               Blue
  EndFont
End









# Input lyxmacros.inc

# Remove some unwanted styles.
# NoStyle               Right_Address
# NoStyle               Address

---------------------------- TEMPLATE FILE -------------
#LyX 1.1 created this file. For more info see http://www.lyx.org/
\lyxformat 2.16
\textclass smtl-letter
\options stdletter
\graphics default
\language default
\papersize a4paper
\paperpackage a4
\papercolumns 1
\papersides 1
\paperpagestyle default


\layout NameTo

<Name of recipient>
\layout AddressTo

<Address line 1>
\newline 
<Address line 2>
\newline 
<etc etc>
\layout Signame

<Full Name>
\newline 
<Position>
\newline 
<email>@smtl.co.uk
\layout Greeting

<Dear XXXXXXX>
\layout Closing

Yours Sincerely
\layout Letter

<The main letter contents go here.>
\the_end

Reply via email to