]> git.lyx.org Git - lyx.git/blobdiff - lib/layouts/scrlttr2.layout
Fix several layout related problems revealed by -dbg tclass.
[lyx.git] / lib / layouts / scrlttr2.layout
index fe6c08575adc757ff8b3b3f549043755b49ca73f..4d73cda897928b13188311f2a1d290fd26667ac0 100644 (file)
@@ -1,9 +1,12 @@
 #% Do not delete the line below; configure depends on this
-#  \DeclareLaTeXClass[scrlttr2]{letter (koma-script v.2)}
+#  \DeclareLaTeXClass{letter (KOMA-Script v.2)}
 # KOMA scrlettr2 textclass definition file.
 # Juergen Spitzmueller <j.spitzmueller@gmx.de>, 2003/2/17.
+# Uwe Stöhr <uwestoehr@web.de>, 2008/2/03.
+
+Format 31
+Provides subscript 1
 
-Format 3
 Style Standard
        LatexName             dummy
        ParSep                0.4
@@ -13,7 +16,7 @@ End
 Input stdlists.inc
 Input stdlayouts.inc
 Input stdcounters.inc
-
+Input stdinsets.inc
 
 Style Description
        LabelFont
@@ -30,19 +33,23 @@ Style Labeling
        EndPreamble
 End
 
+
 Style List
        Obsoletedby           Labeling
 End
 
 
+Preamble
+       \newif\ifletterclosed
+EndPreamble
+
 
 Style Address
        LatexType             Command
        LatexName             begin
        LatexParam            {letter}
-       #Ugly hack!
        Preamble
-       \AtEndDocument{\end{letter}}
+               \AtEndDocument{\ifletterclosed\else\end{letter}\fi}
        EndPreamble
        KeepEmpty             1
        LeftMargin            xxxxxxxxxxxx::xx
@@ -51,10 +58,8 @@ Style Address
        BottomSep             1.5
        ParSep                1.5
        Align                 Left
-       AlignPossible         Left
        LabelType             Static
        LabelString           "Address:"
-
        LabelFont
          Series              Bold
          Shape               Italic
@@ -75,10 +80,8 @@ Style NextAddress
        BottomSep             1.5
        ParSep                1.5
        Align                 Left
-       AlignPossible         Left
        LabelType             Static
        LabelString           "Next Address:"
-
        LabelFont
          Series              Bold
          Shape               Italic
@@ -98,10 +101,8 @@ Style Opening
        BottomSep             0.4
        ParSep                0.4
        Align                 Left
-       AlignPossible         Left
        LabelType             Static
        LabelString           "Opening:"
-
        LabelFont
          Series              Bold
          Shape               Italic
@@ -146,13 +147,12 @@ Style Name
        LatexName             setkomavar
        LatexParam            {fromname}
        KeepEmpty             1
-       LeftMargin            xxxxxxxxxxxx::xx
+       LeftMargin            xxxxxxxxxxxxxxxxx::xx
        LabelSep              xx
        TopSep                0.4
        BottomSep             0.4
        ParSep                0.4
        Align                 Left
-       AlignPossible         Left
        LabelType             Static
        LabelString           "Sender Name:"
 
@@ -273,6 +273,7 @@ Style Title
        LatexName             setkomavar
        LatexParam            {title}
        LabelString           "Title:"
+       HTMLTitle             true
 End
 
 
@@ -330,3 +331,24 @@ Style Invoice
        LatexParam            {invoice}
        LabelString           "Invoice no.:"
 End
+
+
+Style EndLetter
+       Margin                Dynamic
+       LatexType             Command
+       LatexName             end{letter}
+       Preamble
+               \letterclosedtrue
+       EndPreamble
+       KeepEmpty             1
+       TopSep                1
+       ParSkip               0.4
+       Align                 Block
+       LabelSep              xx
+       LabelType             Static
+       LabelString           "End of letter"
+       LabelFont
+         Series              Bold
+         Color               Green
+       EndFont
+End