Author: manuel
Date: 2007-04-22 15:20:09 -0600 (Sun, 22 Apr 2007)
New Revision: 8100

Modified:
   branches/new-xsl/lfs-nochunks.xsl
   branches/new-xsl/lfs.css
   branches/new-xsl/pdf/lfs-mixed.xsl
   branches/new-xsl/xhtml/lfs-mixed.xsl
Log:
Added templates for better simplelist look.

Modified: branches/new-xsl/lfs-nochunks.xsl
===================================================================
--- branches/new-xsl/lfs-nochunks.xsl   2007-04-22 17:34:50 UTC (rev 8099)
+++ branches/new-xsl/lfs-nochunks.xsl   2007-04-22 21:20:09 UTC (rev 8100)
@@ -566,10 +566,6 @@
   font-style: italic;
 }
 
-.simplelist {
-  background-color: #f0fff0;
-}
-
 .underlined {
   text-decoration: underline;
 }

Modified: branches/new-xsl/lfs.css
===================================================================
--- branches/new-xsl/lfs.css    2007-04-22 17:34:50 UTC (rev 8099)
+++ branches/new-xsl/lfs.css    2007-04-22 21:20:09 UTC (rev 8100)
@@ -530,10 +530,6 @@
   font-style: italic;
 }
 
-.simplelist {
-  background-color: #f0fff0;
-}
-
 .underlined {
   text-decoration: underline;
 }

Modified: branches/new-xsl/pdf/lfs-mixed.xsl
===================================================================
--- branches/new-xsl/pdf/lfs-mixed.xsl  2007-04-22 17:34:50 UTC (rev 8099)
+++ branches/new-xsl/pdf/lfs-mixed.xsl  2007-04-22 21:20:09 UTC (rev 8100)
@@ -332,4 +332,36 @@
     </fo:list-item>
   </xsl:template>
 
+    <!-- simplelist:
+           Self-made template. Wrap it into a fo:block and process member 
childs.
+           If @type is specified, the original templates will be used.
+           NOTE: when using type='horiz' or type='vert', FOP-0.93 will 
complaints
+             about not supported table-layout="auto" -->
+  <xsl:template match="simplelist">
+    <fo:block xsl:use-attribute-sets="simplelist.properties">
+      <xsl:apply-templates mode="condensed"/>
+    </fo:block>
+  </xsl:template>
+
+    <!-- member:
+           Self-made template to wrap it into a fo:block using customized
+           properties. -->
+  <xsl:template match="member" mode="condensed">
+    <fo:block xsl:use-attribute-sets="simplelist.properties">
+      <xsl:call-template name="simple.xlink">
+        <xsl:with-param name="content">
+          <xsl:apply-templates/>
+        </xsl:with-param>
+      </xsl:call-template>
+    </fo:block>
+  </xsl:template>
+
+    <!-- Properties associated with our simplelist format. -->
+  <xsl:attribute-set name="simplelist.properties">
+    <xsl:attribute 
name="keep-with-previous.within-column">always</xsl:attribute>
+    <xsl:attribute name="space-before.optimum">0em</xsl:attribute>
+    <xsl:attribute name="space-before.minimum">0em</xsl:attribute>
+    <xsl:attribute name="space-before.maximum">0.2em</xsl:attribute>
+  </xsl:attribute-set>
+
 </xsl:stylesheet>

Modified: branches/new-xsl/xhtml/lfs-mixed.xsl
===================================================================
--- branches/new-xsl/xhtml/lfs-mixed.xsl        2007-04-22 17:34:50 UTC (rev 
8099)
+++ branches/new-xsl/xhtml/lfs-mixed.xsl        2007-04-22 21:20:09 UTC (rev 
8100)
@@ -125,7 +125,28 @@
     </xsl:choose>
   </xsl:template>
 
+    <!-- para/simplelist:
+           Self-made template. Add a line break and process the childs.
+           If @type is specified, the original templates should be used,
+           but not tested. -->
+  <xsl:template match="para/simplelist">
+    <br/>
+    <xsl:apply-templates mode="condensed"/>
+  </xsl:template>
 
+    <!-- member:
+           Self-made template to process it and add a line break. -->
+  <xsl:template match="member" mode="condensed">
+    <xsl:call-template name="anchor"/>
+    <xsl:call-template name="simple.xlink">
+      <xsl:with-param name="content">
+        <xsl:apply-templates/>
+      </xsl:with-param>
+    </xsl:call-template>
+    <br/>
+  </xsl:template>
+
+
   <!-- Named formating templates -->
 
     <!-- Body attributes:

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-book
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to