 
 
|  | Experimental DSSSL extensionsContents
 IntroductionThis document descibes some
        experimental extensions to DSSSL that are implemented in OpenJade.
        These are designed so that, with these
        extensions, DSSSL provides a superset of the semantics XSL for flow
        object tree construction. OpenJade has a  These extensions do not include the additional flow object classes and characteristics that will be needed for XSL; in particular they do not include the HTML/CSS flow object classes. Imperative programmingThe following features come from R4RS: 
 The use of side-effects is restricted. Assignment to top-level variables is not allowed. There is also the concept that a memory location can be read-only. When a memory location is read-only, it is an error to change that location. An memory location can be recursively marked as read-only; this means that the memory location along with all memory locations reachable from that memory location become read-only. A memory location is recursively marked as read-only when: 
 A continuation created with  There's a  Style rulesWhen a construction rule has a keyword argument list instead of a construct expression it is treated as a style rule. For example, (element H1 font-size: 14pt font-weight: 'bold) The keyword argument list can
        include a  Extended patternsThe syntax for element patterns is
        extended. These provide provide a superset of the
        semantics of XSL patterns. They are allowed both in
        element construction rules and in contexts where a  A pattern is either a single gi or a list. A list consists of a sequence of gis, where each gi can be followed by one or more keyword/value pairs (where the value is always a single datum). A gi can be #t, a string or a symbol. The following keywords are allowed: 
 Class attribute names are declared using (declare-class-attribute "class") or (declare-class-attribute class) Id attribute names can be declared
        similarily using  Some examples: 
(element (E importance: 42) ...)
(element (E attributes: (A1 V1)) ...)
(element (P E children: C) ...)
(element (P children: C priority: -11
          E children: C attributes: (A1 V1 A2 V2))
 ...)
(element (P E children: (A children: C B children: C)) ...)
The last is equivalent to the following in XSL syntax: 
<element type="P">
  <target-element type="E">
     <element type="A">
       <element type="C"/>
     </element>
     <element type="B">
       <element type="C"/>
     </element>
  </target-element>
</element>
 Multiple patterns per ruleAn  (or-element (pattern+) expression) where  For example, (or-element (H1 H2 H3) font-weight: 'bold) (or-element ((H1 TITLE) (H2 TITLE) (H3 TITLE)) font-weight: 'bold) is equivalent to (element H1 font-weight: 'bold) (element H2 font-weight: 'bold) (element H3 font-weight: 'bold) (element (H1 TITLE) font-weight: 'bold) (element (H2 TITLE) font-weight: 'bold) (element (H3 TITLE) font-weight: 'bold) 
 Flow object macrosA flow object macro can be defined like this: 
 
 If the formal argument list
        includes  Note that flow object macros are
        quite different from ordinary procedures in that the
        macro body is not evaluated when the make expression is
        evaluated, but rather when the flow object is to be added
        to the tree; this allows  For an example of a library built with the macro facility read: Simple XML to HTML Conversion and Rendition Example Characteristic value conversionMost characteristic values can now
        be specified as strings and will be converted
        appropriately. For boolean valued characteristics any of
        the strings  Characteristic namesThe question mark that can be omitted from those DSSSL characteristic names that end with a question mark. This is because the question mark is not (and cannot reasonably be made) a legal XML name character. The char-map characteristicThe char-map inherited characteristic accept, in addition to #f and a procedure, the symbols uppercase, lowercase and capitalize. uppercase means to convert every character to upper case, lowercase means to convert every character to lower case and capitalize means that the first character in every word is converterd to upper case. The country: and language: characteristics will determine how the case conversion is done. |