]> pere.pagekite.me Git - text-free-culture-lessig.git/commitdiff
Add indenting for each paragraph in the text.
authorPetter Reinholdtsen <pere@hungry.com>
Tue, 7 Aug 2012 12:41:32 +0000 (14:41 +0200)
committerPetter Reinholdtsen <pere@hungry.com>
Tue, 7 Aug 2012 12:41:32 +0000 (14:41 +0200)
data/origsize.xsl

index 30296327389764adaef16f46319e884ee8acf7bc..501e48de9952c32fb1690a304dad91ba6e1d1d5e 100644 (file)
@@ -1,5 +1,6 @@
 <?xml version='1.0' encoding="iso-8859-1"?>
 <?xml version='1.0' encoding="iso-8859-1"?>
-<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version='1.0'>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version='1.0'
+               xmlns:fo="http://www.w3.org/1999/XSL/Format" >
 
 <!-- settings from original PDF version -->
 
 
 <!-- settings from original PDF version -->
 
 <xsl:param name="title.font.family">Times</xsl:param>
 <xsl:param name="dingbat.font.family">Times</xsl:param>
 
 <xsl:param name="title.font.family">Times</xsl:param>
 <xsl:param name="dingbat.font.family">Times</xsl:param>
 
+<!-- from http://cygwin.com/ml/docbook-apps/2004-q2/msg00107.html -->
+<!-- ~~~~~~~~~~~~~~~~ -->
+<!-- Paragraph layout -->
+<!-- ~~~~~~~~~~~~~~~~ -->
+<xsl:template match="para[1]">
+  <fo:block xsl:use-attribute-sets="normal.para.spacing">
+    <xsl:call-template name="anchor"/>
+    <xsl:apply-templates/>
+  </fo:block>
+</xsl:template>
+
+<xsl:template match="para">
+  <fo:block xsl:use-attribute-sets="normal.para.spacing">
+    <xsl:attribute name="text-indent">0.15in</xsl:attribute>
+    <xsl:attribute name="space-before.optimum">0pt</xsl:attribute>
+    <xsl:attribute name="space-before.minimum">0pt</xsl:attribute>
+    <xsl:attribute name="space-before.maximum">1pt</xsl:attribute>
+    <xsl:call-template name="anchor"/>
+    <xsl:apply-templates/>
+  </fo:block>
+</xsl:template>
+
 </xsl:stylesheet>
 </xsl:stylesheet>