]> granicus.if.org Git - docbook-dsssl/commitdiff
Initial checkin
authorNorman Walsh <ndw@nwalsh.com>
Mon, 2 Apr 2001 22:12:36 +0000 (22:12 +0000)
committerNorman Walsh <ndw@nwalsh.com>
Mon, 2 Apr 2001 22:12:36 +0000 (22:12 +0000)
gentext/dsssl/dsssl.dsl [new file with mode: 0644]

diff --git a/gentext/dsssl/dsssl.dsl b/gentext/dsssl/dsssl.dsl
new file mode 100644 (file)
index 0000000..b9955ef
--- /dev/null
@@ -0,0 +1,71 @@
+<!DOCTYPE style-sheet PUBLIC "-//James Clark//DTD DSSSL Style Sheet//EN" [
+<!ENTITY lt "&#38;#60;">
+<!ENTITY gt     "&#62;">
+<!ENTITY RE '(make formatting-instruction data: "
+")'>
+<!ENTITY blank '(make formatting-instruction data: " ") (empty-sosofo)'>
+]>
+
+<style-sheet>
+<style-specification>
+<style-specification-body>
+
+;; This stylesheet would work, except that files like ../locale/ca.xml
+;; have a doctype declaration but no DTD and Jade doesn't like that.
+
+;; $Id$
+
+(declare-flow-object-class formatting-instruction
+  "UNREGISTERED::James Clark//Flow Object Class::formatting-instruction")
+
+(define debug
+  (external-procedure "UNREGISTERED::James Clark//Procedure::debug"))
+
+(root
+ (make sequence
+
+   (make formatting-instruction
+     data: "&lt;!-- This file is generated automatically. --&gt;")
+   &RE;
+   (make formatting-instruction
+     data: "&lt;!-- Do not edit this file by hand! --&gt;")
+   &RE;
+   (make formatting-instruction
+     data: "&lt;!-- See http://docbook.sourceforge.net/ --&gt;")
+   &RE;
+   &RE;
+
+   (process-children)))
+
+(element locale
+  (process-node-list (select-elements (children (current-node)) "gentext")))
+
+(element gentext
+  (make sequence
+    (make formatting-instruction
+      data: "&lt;!ENTITY ")
+    (literal (attribute-string "key"))
+    (if (&lt; (string-length (attribute-string "key")) 15) &blank;)
+    (if (&lt; (string-length (attribute-string "key")) 14) &blank;)
+    (if (&lt; (string-length (attribute-string "key")) 13) &blank;)
+    (if (&lt; (string-length (attribute-string "key")) 12) &blank;)
+    (if (&lt; (string-length (attribute-string "key")) 11) &blank;)
+    (if (&lt; (string-length (attribute-string "key")) 10) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  9) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  8) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  7) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  6) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  5) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  4) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  3) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  2) &blank;)
+    (if (&lt; (string-length (attribute-string "key"))  1) &blank;)
+    (make formatting-instruction data: "\"")
+    (make formatting-instruction data: (attribute-string "text"))
+    (make formatting-instruction data: "\"&gt;")
+    &RE;
+    ))
+
+</style-specification-body>
+</style-specification>
+</style-sheet>