You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by pb...@apache.org on 2002/12/18 17:25:25 UTC

cvs commit: xml-fop/src/documentation/content/xdocs/design/alt.design alt-properties.xml classes-overview.xml compound-properties.xml coroutines.xml footnotes.xml galleys.xml index.xml keeps.xml properties-classes.xml spaces.xml

pbwest      2002/12/18 08:25:25

  Modified:    src/documentation/content/xdocs/design/alt.design
                        alt-properties.xml classes-overview.xml
                        compound-properties.xml coroutines.xml
                        footnotes.xml galleys.xml index.xml keeps.xml
                        properties-classes.xml spaces.xml
  Log:
  W.I.P. changes to alt.design pages.
  
  Revision  Changes    Path
  1.2       +122 -141  xml-fop/src/documentation/content/xdocs/design/alt.design/alt-properties.xml
  
  Index: alt-properties.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/alt-properties.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- alt-properties.xml	2 Dec 2002 12:00:11 -0000	1.1
  +++ alt-properties.xml	18 Dec 2002 16:25:24 -0000	1.2
  @@ -3,170 +3,151 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Implementing Properties</title>
  +  <header>
  +    <title>Implementing Properties</title>
       <authors>
  -       <person id="pbw" name="Peter B. West" email="pbwest@powerup.com.au"/>
  +      <person id="pbw" name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>An alternative properties implementation</title>
         <note> 
  -  The following discussion focusses on the relationship between
  -  Flow Objects in the Flow Object tree, and properties.  There
  -  is no (or only passing) discussion of the relationship between
  -  properties and traits, and by extension, between properties
  -  and the Area tree.  The discussion is illustrated with some
  -  pseudo-UML diagrams.
  +        The following discussion focusses on the relationship between
  +        Flow Objects in the Flow Object tree, and properties.  There
  +        is no (or only passing) discussion of the relationship between
  +        properties and traits, and by extension, between properties
  +        and the Area tree.
         </note>
         <p>
  -  Property handling is complex and expensive. Varying numbers of
  -  properties apply to individual Flow Objects
  -  <strong>(FOs)</strong> in the <strong>FO
  -  tree </strong> but any property may effectively be
  -  assigned a value on any element of the tree.  If that property
  -  is inheritable, its defined value will then be available to
  -  any children of the defining FO.
  +        Property handling is complex and expensive. Varying numbers of
  +        properties <strong>apply</strong> to individual Flow Objects
  +        <strong>(FOs)</strong> in the <strong>FO tree </strong> but
  +        any property may effectively be assigned a value on any
  +        element of the tree.  If that property is inheritable, its
  +        defined value will then be available to any children of the
  +        defining FO.
         </p>
         <note>
  -  <em>(XSL 1.0 Rec)</em> <strong>5.1.4 Inheritance</strong>
  -  ...The inheritable properties can be placed on any formatting
  -  object.
  +        <em>(XSL 1.0 Rec)</em> <strong>5.1.4 Inheritance</strong>
  +        ...The inheritable properties can be placed on any formatting
  +        object.
         </note>
         <p>
  -  Even if the value is not inheritable, it may be accessed by
  -  its children through the <code>inherit</code> keyword or the
  -  <code>from-parent()</code> core function, and potentially by
  -  any of its descendents through the
  -  <code>from-nearest-specified-value()</code> core function.
  +        Even if the value is not inheritable, it may be accessed by
  +        its children through the <code>inherit</code> keyword or the
  +        <code>from-parent()</code> core function, and potentially by
  +        any of its descendents through the
  +        <code>from-nearest-specified-value()</code> core function.
         </p>
         <p>
  -  In addition to the assigned values of properties, almost every
  -  property has an <strong>initial value</strong> which is used
  -  when no value has been assigned.
  +        In addition to the assigned values of properties, almost every
  +        property has an <strong>initial value</strong> which is used
  +        when no value has been assigned.
         </p>
         <section>
           <title>The history problem</title>
  -      <p>
  -  The difficulty and expense of handling properties comes from
  -  this univeral inheritance possibility.  The list of properties
  -  which are assigned values on any particular <em>FO</em>
  -  element will not generally be large, but a current value is
  -  required for each property which applies to the <em>FO</em>
  -  being processed.
  -      </p>
  -      <p>
  -  The environment from which these values may be selected
  -  includes, for each <em>FO</em>, for each applicable property,
  -  the value assigned on this <em>FO</em>, the value which
  -  applied to the parent of this <em>FO</em>, the nearest value
  -  specified on an ancestor of this element, and the initial
  -  value of the property.
  -      </p>
  -      </section>
  -      <section>
  -        <title>Data requirement and structure</title>
  -  <p>
  -    This determines the minimum set of properties and associated
  -    property value assignments that is necessary for the
  -    processing of any individual <em>FO</em>.  Implicit in this
  -    set is the set of properties and associated values,
  -    effective on the current <em>FO</em>, that were assigned on
  -    that <em>FO</em>.
  -  </p>
  -  <p>
  -    This minimum requirement - the initial value, the
  -    nearest ancestor specified value, the parent computed value
  -    and the value assigned to the current element -
  -    suggests a stack implementation.
  -  </p>
  +        <p>
  +          The difficulty and expense of handling properties comes from
  +          this univeral inheritance possibility.  The list of properties
  +          which are assigned values on any particular <em>FO</em>
  +          element will not generally be large, but a current value is
  +          required for each property which applies to the <em>FO</em>
  +          being processed.
  +        </p>
  +        <p>
  +          The environment from which these values may be selected
  +          includes, for each <em>FO</em>, <strong>for each applicable
  +          property</strong>, the value assigned on this <em>FO</em>,
  +          the value which applied to the parent of this <em>FO</em>,
  +          the nearest value specified on an ancestor of this element,
  +          and the initial value of the property.
  +        </p>
         </section>
         <section>
  -        <title>Stack considerations</title>
  -  <p>
  -    One possibility is to push to the stack only a minimal set
  -    of required elements.  When a value is assigned, the
  -    relevant form or forms of that value (specified, computed,
  -    actual) are pushed onto the stack.  As long as each
  -    <em>FO</em> maintains a list of the properties which were
  -    assigned from it, the value can be popped when the focus of
  -    FO processing retreats back up the <em>FO</em> tree.
  -  </p>
  -  <p>
  -    The complication is that, for elements which are not
  -    automatically inherited, when an <em>FO</em> is encountered
  -    which does <strong>not</strong> assign a value to the
  -    property, the initial value must either be already at the
  -    top of the stack or be pushed onto the stack.
  -  </p>
  -  <p>
  -    As a first approach, the simplest procedure may be to push a
  -    current value onto the stack for every element - initial
  -    values for non-inherited properties and the parental value
  -    otherwise.  Then perform any processing of assigned values.
  -    This simplifies program logic at what is hopefully a small
  -    cost in memory and processing time.  It may be tuned in a
  -    later iteration.
  -  </p>
  -  <section>
  -    <title>Stack implementation</title>
  -    <p>
  -      Initial attempts at this implementation have used
  -      <code>LinkedList</code>s as the stacks, on the assumption
  -      that
  -    </p>
  -    <ul>
  -      <!-- one of (dl sl ul ol li) -->
  -      <li>random access would not be required</li>
  -      <li>
  -        pushing and popping of list elements requires nearly
  -        constant (low) time
  -      </li>
  -      <li> no penalty for first addition to an empty list</li>
  -      <li>efficient access to both bottom and top of stack</li>
  -    </ul>
  -    <p>
  -      However, it may be required to perform stack access
  -      operations from an arbitrary place on the stack, in which
  -      case it would probably be more efficient to use
  -      <code>ArrayList</code>s instead.
  -    </p>
  -  </section>
  +        <title>The Construction Hierarchy</title>
  +        <p>
  +          Properties are resoved in the <strong>FO tree</strong> in a
  +          strictly hierarchical manner.  Nodes are detected in the
  +          input in a <strong>pre-order</strong> traversal, and are
  +          built in the same order.  This imples that there are two
  +          phases, or states, of property resolution and construction.
  +          Any particular FO node is either in a state of constructing
  +          its own subtree, or in a stable state where the subtree
  +          construction is complete.  These states have differenct data
  +          requirements.
  +        </p>
  +        <dl>
  +          <dt>Subtree building</dt>
  +          <dd>
  +            In this state, all properties defined on this node, or any
  +            of its ancestors must be available to the subtree.  In
  +            effect, any property defined on this node must be
  +            available to its descendants, as all properties defined on
  +            any ancestor are available to this node.
  +          </dd>
  +          <dt>Stable: subtree building complete</dt>
  +          <dd>
  +            In this state, only the properties <strong>applicable to
  +            this node</strong> need be available.
  +          </dd>
  +        </dl>
         </section>
         <section>
  -        <title>Class vs instance</title>
  -  <p>
  -    An individual stack would contain values for a particular
  -    property, and the context of the stack is the property class
  -    as a whole.  The property instances would be represented by
  -    the individual values on the stack.  If properties are to be
  -    represented as instantiations of the class, the stack
  -    entries would presumably be references to, or at least
  -    referenced from, individual property objects.  However, the
  -    most important information about individual property
  -    instances is the value assigned, and the relationship of
  -    this property object to its ancestors and its descendents.
  -    Other information would include the ownership of a property
  -    instance by a particular <em>FO</em>, and, in the other
  -    direction, the membership of the property in the set of
  -    properties for which an <em>FO</em> has defined values.
  -  </p>
  -  <p>
  -    In the presence of a stack, however, none of this required
  -    information mandates the instantiation of properties.  All
  -    of the information mentioned so far can be effectively
  -    represented by a stack position and a link to an
  -    <em>FO</em>.  If the property stack is maintained in
  -    parallel with a stack of <em>FOs</em>, even that link is
  -    implicit in the stack position.
  -  </p>
  +        <title>Representing Properties: &lt;property&gt; Classes</title>
  +        <section>
  +          <title>Class vs instance</title>
  +          <p>
  +            What information is required of &lt;property&gt; objects?
  +            More particularly, what information is particular to the
  +            &lt;property&gt; classes, and what to the instantiated
  +            objects?  The answer to this question depend largely on
  +            how the &lt;poroperty&gt; objects are used in the context
  +            of layout and Area tree construction.  The approach taken
  +            in this implementation is that properties are simply flags
  +            on certain data values associated with FOs.  The semantics
  +            of these flags are determined within the layout engine.
  +          </p>
  +          <p>
  +            Certain constant information attaches to individual
  +            &lt;property&gt; classes.  This information is detailed in
  +            the descriptions of individual properties in <em>Section
  +            7</em> of the specification.  Such information is
  +            represented in <strong>class</strong> fields and data
  +            structures within the classes.
  +          </p>
  +          <p>
  +            The "instance" information content of a &lt;property&gt;
  +            is:
  +          </p>
  +          <ul>
  +            <li>
  +              explicitly, the <strong>PropertyValue</strong> datum of
  +              the property, and
  +            </li>
  +            <li>
  +              implicitly, the <strong>Flow Object</strong> to which
  +              the property is attached.
  +            </li>
  +          </ul>
  +          <p>
  +            Properties, then, serve essentially to link <em>FO
  +            instances</em> with <em>PropertyValue instances</em>,
  +            attaching certain invariant semantic markers to the
  +            PropertyValues in the process.  In this implementation,
  +            these functions can be realised entirely within the
  +            &lt;property&gt; <strong>classes</strong> themselves,
  +            without the need to instantiate any objects.  In practice,
  +            <strong>&lt;property&gt; singletons</strong> are
  +            instantiated to make access to some invariants simpler.
  +          </p>
  +        </section>
         </section>
         <p>
  -  <strong>Next:</strong> <link href="classes-overview.html"
  -  >property classes overview.</link>
  +        <strong>Next:</strong> <link href="classes-overview.html"
  +                                     >property classes overview.</link>
         </p>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.5       +175 -188  xml-fop/src/documentation/content/xdocs/design/alt.design/classes-overview.xml
  
  Index: classes-overview.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/classes-overview.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- classes-overview.xml	9 Dec 2002 08:45:16 -0000	1.4
  +++ classes-overview.xml	18 Dec 2002 16:25:24 -0000	1.5
  @@ -3,201 +3,188 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Property classes overview</title>
  +  <header>
  +    <title>Property classes overview</title>
       <authors>
         <person id="pbw" name="Peter B. West"
  -        email="pbwest@powerup.com.au"/>
  +              email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
  -      <title>Classes overview</title>
  -      <section>
  -        <title>The class of all properties</title>
  -  <p>
  -    If individual properties can have a "virtual reality" on the
  -    stack, where is the stack itself to be instantiated?  One
  -    possibility is to have the stacks as <code>static</code>
  -    data structures within the individual property classes.
  -    However, the reduction of individual property instances to
  -    stack entries allows the possibility of further
  -    virtualization of property classes.  If the individual
  -    properties can be represented by an integer, i.e. a
  -    <code>static final int</code>, the set of individual
  -    property stacks can be collected together into one array.
  -    Where to put such an overall collection?  Creating an 
  -    &#xFC;ber-class to accommodate everything that applies to
  -    property classes as a whole allows this array to be defined
  -    as a <em><code>static final</code> something[]</em>.
  -  </p>
  -      </section>
  -      <section>
  -        <title>The overall property classes</title>
  -  <p>
  -    This approach has been taken for the experimental code.
  -    Rather than simply creating a overall class containing
  -    common elements of properties and acting as a superclass,
  -    advantage has been taken of the facility for nesting of
  -    top-level classes.  All of the individual property classes
  -    are nested within the <code>Properties</code> class.
  -    This has advantages and disadvantages.
  -  </p>
  -  <dl>
  -    <dt>Disadvantages</dt>
  -    <dd>
  -      The file becomes extremely cumbersome.  This can cause
  -      problems with "intelligent" editors.  E.g.
  -      <em>XEmacs</em>  syntax highlighting virtually grinds to a
  -      halt with the current version of this file.<br/> <br/>
  -
  -      Possible problems with IDEs.  There may be speed problems
  -      or even overflow problems with various IDEs.  The current
  -      version of this and related files had only been tried with
  -      the <em>[X]Emacs JDE</em>  environment, without difficulties
  -      apart from the editor speed problems mentioned
  -      above.<br/> <br/>
  -
  -      Retro look and feel.  Not the done Java thing.<br/> <br/>
  -    </dd>
  -    <dt>Advantages</dt>
  -    <dd>
  -      Everything to do with properties in the one place (more or
  -      less.)<br/> <br/>
  -
  -      Eliminates the need for a large part of the (sometimes)
  -      necessary evil of code generation.  The One Big File of
  -      <code>foproperties.xml</code>, with its ancillary xsl, is
  -      absorbed into the One Bigger File of
  -      <code>Properties.java</code>.  The huge advantage of this
  -      is that it <strong>is</strong>  Java.
  -    </dd>
  -  </dl>
  -      </section>
  -      <section>
  -        <title>The property information classes</title>
  -  <p>
  -    In fact, in order to keep the size of the file down to more
  -    a more manageable level, the property information classes of
  -    static data and methods have been split tentatively into
  -    three:
  -  </p>
  -  <figure src="images/design/alt.design/PropertyStaticsOverview.png" alt="Top level
  -    property classes"/>
  -  <dl>
  -    <dt><link href="PropNames-png.html">PropNames</link></dt>
  -    <dd>
  -      Contains an array, <code>propertyNames</code>, of the names of
  -      all properties, and a set of enumeration constants, one
  -      for each property name in the <code>PropertyNames</code>
  -      array.  These constants index the name of the properties
  -      in <code>propertyNames</code>, and must be manually kept in
  -      sync with the entries in the array. (This was the last of
  -      the classes split off from the original single class;
  -      hence the naming tiredness.)
  -      <br/> <br/>
  -    </dd>
  -    <dt><link href="PropertyConsts-png.html">PropertyConsts</link></dt>
  -    <dd>
  -      Contains two basic sets of data:<br/>
  -      Property-indexed arrays and property set
  -      definitions.<br/> <br/>
  -
  -      <strong>Property-indexed arrays</strong>  are elaborations
  -      of the property indexing idea discussed in relation to the
  -      arrays of property stacks.  One of the arrays is<br/> <br/>
  -
  -      <code>public static final LinkedList[]
  -      propertyStacks</code><br/> <br/>
  -
  -      This is an array of stacks, implemented as
  -      <code>LinkedList</code>s, one for each property.<br/> <br/>
  -
  -      The other arrays provide indexed access to fields which
  -      are, in most cases, common to all of the properties.  An
  -      exception is<br/> <br/>
  -
  -      <code>public static final Method[]
  -        complexMethods</code><br/> <br/>
  -
  -      which contains a reference to the method
  -      <code>complex()</code>  which is only defined for
  -      properties which have complex value parsing requirements.
  -      It is likely that a similar array will be defined for
  -      properties which allow a value of <em>auto</em>.<br/> <br/>
  -
  -      The property-indexed arrays are initialized by
  -      <code>static</code>  initializers in this class.  The
  -      <code>PropNames</code>  class and
  -      <code>Properties</code>
  -      nested classes are scanned in order to obtain or derive
  -      the data necessary for initialization.<br/> <br/>
  -
  -      <strong>Property set definitions</strong>  are
  -      <code>HashSet</code>s of properties (represented by
  -      integer constants) which belong to each of the categories
  -      of properties defined.  They are used to simplify the
  -      assignment of property sets to individual FOs.
  -      Representative <code>HashSet</code>s include
  -      <em>backgroundProps</em>  and
  -      <em>tableProps</em>.<br/> <br/>
  -    </dd>
  -    <dt><link href="Properties-png.html">Properties</link></dt>
  -    <dd>
  -       <br/>
  -      This class contains only sets of constants for use by the
  -      individual property classes, but it also importantly
  -      serves as a container for all of the property classes, and
  -      some convenience pseudo-property classes.<br/> <br/>
  -
  -      <strong>Constants sets</strong>  include:<br/> <br/>
  -
  -      <em>Datatype constants</em>. A bitmap set of
  -      integer constants over a possible range of 2^0 to 2^31
  -      (represented as -2147483648).  E.g.<br/>
  -      INTEGER = 1<br/>
  -      ENUM = 524288<br/> <br/>
  -      Some of the definitions are bit-ORed
  -      combinations of the basic values.  Used to set the
  -      <em>dataTypes</em>  field of the property
  -      classes.<br/> <br/>
  -
  -      <em>Trait mapping constants</em>. A bitmap set of
  -      integer constants over a possible range of 2^0 to 2^31
  -      (represented as -2147483648), representing the manner in
  -      which a property maps into a <em>trait</em>.  Used to set
  -      the <code>traitMapping</code>  field of the property
  -      classes.<br/> <br/>
  -
  -      <em>Initial value constants</em>. A sequence of
  -      integer constants representing the datatype of the initial
  -      value of a property.  Used to set the
  -      <code>initialValueType</code>  field of the property
  -      classes.<br/> <br/>
  -
  -      <em>Inheritance value constants</em>. A sequence
  -      of integer constants representing the way in which the
  -      property is normally inherited.  Used to set the
  -      <code>inherited</code>  field of the property
  -      classes.<br/> <br/>
  -
  -      <strong>Nested property classes</strong>.  The
  -      <em>Properties</em>  class serves as the holding pen for
  -      all of the individual property classes, and for property
  -      pseudo-classes which contain data common to a number of
  -      actual properties, e.g. <em>ColorCommon</em>.
  -    </dd>
  -  </dl>
  -      </section>
  +      <title>Properties: packages</title>
  +      <ul>
  +        <li>
  +          org.apache.fop.fo
  +          <dl>
  +            <dt><fork href="PropNames.html">PropNames</fork></dt>
  +            <dd>
  +              This class maintains an array of <fork href=
  +              "PropNames.html#propertyNames" >property names</fork>,
  +              synchronized to a complete set of property name <fork
  +              href= "PropNames.html#NO_PROPERTY" >constants</fork> for
  +              indexing property-based arrays.  It includes methods to
  +              <fork href= "PropNames.html#getPropertyName" >convert an
  +              index to a name</fork> and to <fork href=
  +              "PropNames.html#getPropertyIndex" >convert a property
  +              name to an index</fork>.
  +            </dd>
  +
  +            <dt>
  +              <fork href= "PropertyConsts.html" >PropertyConsts</fork>
  +            </dt>
  +            <dd>
  +              A singleton instance of <strong>PropertyConsts</strong>
  +              is created by the static initializer of the <fork href=
  +              "PropertyConsts.html#pconsts" >pconsts</fork> field.
  +              Working from the &lt;property&gt; indices defined in
  +              PropNames, the methods in this class collect and supply
  +              the values of fields defined in &lt;property&gt; objects
  +              into arrays.<br/>
  +              
  +              The heart of this class in the method <fork href=
  +              "PropertyConsts.html#setupProperty"
  +              >setupProperty</fork>, which constructs the
  +              &lt;property&gt; name from the index, instantiates a
  +              singleton of the appropriate class, and extracts static
  +              fields by reflection from that instance into the arrays
  +              of field values.
  +            </dd>
  +
  +            <dt><fork href= "PropertySets.html" >PropertySets</fork></dt>
  +            <dd>
  +              This class provides a number of
  +              <strong>ROBitSet</strong>s representing many of the sets
  +              of properties defined in <em>Section 7</em> of the
  +              specification.  Note that the <em>Border</em>,
  +              <em>Padding</em> and <em>Background</em> sets are
  +              defined separately.
  +            </dd>
  +
  +            <dt><fork href= "FOPropertySets.html"
  +                      >FOPropertySets</fork></dt>
  +            <dd>
  +              This class provides a number of
  +              <strong>ROBitSet</strong>s representing sets of
  +              properties which are applicable in particular subtrees
  +              of the FO tree.  These sets are provided so that other
  +              properties can be ignored during processing of the
  +              subtrees.
  +            </dd>
  +
  +            <dt><fork href= "ShorthandPropSets.html"
  +                      >ShorthandPropSets</fork></dt>
  +            <dd>
  +              This class contains arrays of <fork href=
  +              "ShorthandPropSets.html#shorthands" >shorthand property
  +              indices</fork> and <fork href=
  +              "ShorthandPropSets.html#compounds" >compound property
  +              indices</fork>, and <strong>ROBitSet</strong>s
  +              representing the expansion sets of these shorthands and
  +              compounds.  Various methods useful in the expansion of
  +              these properties are also included.
  +            </dd>
  +
  +            <dt>FOAttributes</dt>
  +            <dd></dd>
  +          </dl>
  +        </li>
  +        <li>
  +          org.apache.fop.fo.properties
  +          <dl>
  +            <dt>Property</dt>
  +            <dd>
  +              The base class for all individual &lt;property&gt; classes.
  +            </dd>
  +            <dt>ColumnNumber</dt>
  +            <dd>
  +              The actual &lt;property&gt; class with the lowest index
  +              number, followed in the oindex order by properties
  +              required for further processing, e.g. FontSize.
  +            </dd>
  +            <dt>....</dt>
  +            <dd>....</dd>
  +            <dt>Background</dt>
  +            <dd>
  +              First in index order of the remainining shorthand
  +              properties, followed in index order by all other
  +              remaining shorthands.
  +            </dd>
  +            <dt>....</dt>
  +            <dd>....</dd>
  +            <dt>AbsolutePosition</dt>
  +            <dd>
  +              First in index order of the remaining properties.
  +              Within this ordering, compound properties precede their
  +              expansion properties, and corresponding relative
  +              properties precede corresponding absolute properties.
  +            </dd>
  +            <dt>....</dt>
  +            <dd>....</dd>
  +            <dt>ZIndex</dt>
  +            <dd>
  +              The &lt;property&gt; class with the highest index
  +              number.
  +            </dd>
  +          </dl>
  +        </li>
  +        <li>
  +          org.apache.fop.fo.expr
  +          <dl>
  +            <dt><fork href= "PropertyTokenizer.html"
  +                      >PropertyTokenizer</fork></dt>
  +            <dd>
  +              The tokenizer for the &lt;property&gt; expression
  +              parser.  Defines a set of <fork href=
  +              "PropertyTokenizer.html#EOF" >token constants</fork> and
  +              returns these with associated token values.
  +            </dd>
  +
  +            <dt><fork href= "PropertyParser.html"
  +                      >PropertyParser</fork></dt>
  +            <dd>
  +              This extends <strong>PropertyTokenizer</strong>.  It
  +              parses &lt;property&gt; expressions on the basis of the
  +              tokens passed to it by its superclass, generating
  +              <strong>PropertyValue</strong>s, including
  +              <strong>PropertyValueList</strong>s.
  +            </dd>
  +
  +            <dt>PropertyException</dt>
  +            <dd>
  +              The basic class for all &lt;property&gt;-related
  +              exceptions.  It extends
  +              <strong>FOPException</strong>. It is housed in this
  +              package by historical accident.
  +            </dd>
  +
  +            <dt>
  +              DataTypeNotImplementedException<br/>
  +              FunctionNotImplementedException<br/>
  +              PropertyNotImplementedException
  +            </dt>
  +            <dd>
  +             A set of particular exceptions extending
  +             <strong>PropertyException</strong>.  Also in this package
  +             by accident.
  +            </dd>
  +
  +          </dl>
  +        </li>
  +        <li>org.apache.fop.datatypes</li>
  +        <li>org.apache.fop.datatypes.indirect</li>
  +      </ul>
  +    </section>
         <p>
  -  <strong>Previous:</strong> <link href=
  -  "alt-properties.html" >alt.properties</link>
  +        <strong>Previous:</strong> <link href= "alt-properties.html"
  +        >alt.properties</link>
         </p>
  +    <!--
         <p>
  -  <strong>Next:</strong> <link href=
  -  "properties-classes.html" >Properties classes</link>
  +        <strong>Next:</strong> <link href= "properties-classes.html"
  +        >Properties classes</link>
         </p>
  -    </section>
  -    </body>
  +    -->
  +  </body>
   </document>
   
  
  
  
  1.2       +203 -203  xml-fop/src/documentation/content/xdocs/design/alt.design/compound-properties.xml
  
  Index: compound-properties.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/compound-properties.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- compound-properties.xml	2 Dec 2002 10:19:43 -0000	1.1
  +++ compound-properties.xml	18 Dec 2002 16:25:24 -0000	1.2
  @@ -3,216 +3,216 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Compound properties</title>
  +  <header>
  +    <title>Compound properties</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Compound properties in XSLFO</title>
         <table>
  -  <tr>
  -    <th>Property type</th> 
  -    <th>Section</th>
  -    <th>Inherited</th>
  -    <th>'inherit'</th>
  -  </tr>
  -  <tr>
  -    <th>&lt;length-range&gt;</th>
  -  </tr>
  -  <tr>
  -    <th>minimum</th>
  -  </tr>
  -  <tr>
  -    <th>optimum</th>
  -  </tr>
  -  <tr>
  -    <th>maximum</th>
  -  </tr>
  -  <tr>
  -    <td>block-progression-dimension</td>
  -    <td>7.14.1</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>inline-progression-dimension</td>
  -    <td>7.14.5</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>leader-length</td>
  -    <td>7.21.4</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <th>&lt;length-conditional&gt;</th>
  -  </tr>
  -  <tr>
  -    <th>length</th>
  -  </tr>
  -  <tr>
  -    <th>conditionality</th>
  -  </tr>
  -  <tr>
  -    <td>border-after-width</td>
  -    <td>7.7.12</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>border-before-width</td>
  -    <td>7.7.9</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -   <tr>
  -    <td>border-end-width</td>
  -    <td>7.7.18</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -   <tr>
  -    <td>border-start-width</td>
  -    <td>7.7.15</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>padding-after</td>
  -    <td>7.7.32</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>padding-before</td>
  -    <td>7.7.31</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -   <tr>
  -    <td>padding-end</td>
  -    <td>7.7.34</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -   <tr>
  -    <td>padding-start</td>
  -    <td>7.7.33</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <th>&lt;length-bp-ip-direction&gt;</th>
  -  </tr>
  -  <tr>
  -    <th>block-progression-direction</th>
  -  </tr>
  -  <tr>
  -    <th>inline-progression-direction</th>
  -  </tr>
  -  <tr>
  -    <td>border-separation</td>
  -    <td>7.26.5</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <th>&lt;space&gt;</th>
  -  </tr>
  -  <tr>
  -    <th>minimum</th>
  -  </tr>
  -  <tr>
  -    <th>optimum</th>
  -  </tr>
  -  <tr>
  -    <th>maximum</th>
  -  </tr>
  -  <tr>
  -    <th>precedence</th>
  -  </tr>
  -  <tr>
  -    <th>conditionality</th>
  -  </tr>
  -  <tr>
  -    <td>letter-spacing</td>
  -    <td>7.16.2</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>line-height</td>
  -    <td>7.15.4</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>space-after</td>
  -    <td>7.10.6</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>space-before</td>
  -    <td>7.10.5</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>space-end</td>
  -    <td>7.11.1</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>space-start</td>
  -    <td>7.11.2</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>word-spacing</td>
  -    <td>7.16.8</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <th>&lt;keep&gt;</th>
  -  </tr>
  -  <tr>
  -    <th>within-line</th>
  -  </tr>
  -  <tr>
  -    <th>within-column</th>
  -  </tr>
  -  <tr>
  -    <th>within-page</th>
  -  </tr>
  -  <tr>
  -    <td>keep-together</td>
  -    <td>7.19.3</td>
  -    <td>yes</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>keep-with-next</td>
  -    <td>7.19.4</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  -  <tr>
  -    <td>keep-with-previous</td>
  -    <td>7.19.5</td>
  -    <td>no</td>
  -    <td>yes</td>
  -  </tr>
  +        <tr>
  +          <th>Property type</th> 
  +          <th>Section</th>
  +          <th>Inherited</th>
  +          <th>'inherit'</th>
  +        </tr>
  +        <tr>
  +          <th>&lt;length-range&gt;</th>
  +        </tr>
  +        <tr>
  +          <th>minimum</th>
  +        </tr>
  +        <tr>
  +          <th>optimum</th>
  +        </tr>
  +        <tr>
  +          <th>maximum</th>
  +        </tr>
  +        <tr>
  +          <td>block-progression-dimension</td>
  +          <td>7.14.1</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>inline-progression-dimension</td>
  +          <td>7.14.5</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>leader-length</td>
  +          <td>7.21.4</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <th>&lt;length-conditional&gt;</th>
  +        </tr>
  +        <tr>
  +          <th>length</th>
  +        </tr>
  +        <tr>
  +          <th>conditionality</th>
  +        </tr>
  +        <tr>
  +          <td>border-after-width</td>
  +          <td>7.7.12</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>border-before-width</td>
  +          <td>7.7.9</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>border-end-width</td>
  +          <td>7.7.18</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>border-start-width</td>
  +          <td>7.7.15</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>padding-after</td>
  +          <td>7.7.32</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>padding-before</td>
  +          <td>7.7.31</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>padding-end</td>
  +          <td>7.7.34</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>padding-start</td>
  +          <td>7.7.33</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <th>&lt;length-bp-ip-direction&gt;</th>
  +        </tr>
  +        <tr>
  +          <th>block-progression-direction</th>
  +        </tr>
  +        <tr>
  +          <th>inline-progression-direction</th>
  +        </tr>
  +        <tr>
  +          <td>border-separation</td>
  +          <td>7.26.5</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <th>&lt;space&gt;</th>
  +        </tr>
  +        <tr>
  +          <th>minimum</th>
  +        </tr>
  +        <tr>
  +          <th>optimum</th>
  +        </tr>
  +        <tr>
  +          <th>maximum</th>
  +        </tr>
  +        <tr>
  +          <th>precedence</th>
  +        </tr>
  +        <tr>
  +          <th>conditionality</th>
  +        </tr>
  +        <tr>
  +          <td>letter-spacing</td>
  +          <td>7.16.2</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>line-height</td>
  +          <td>7.15.4</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>space-after</td>
  +          <td>7.10.6</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>space-before</td>
  +          <td>7.10.5</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>space-end</td>
  +          <td>7.11.1</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>space-start</td>
  +          <td>7.11.2</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>word-spacing</td>
  +          <td>7.16.8</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <th>&lt;keep&gt;</th>
  +        </tr>
  +        <tr>
  +          <th>within-line</th>
  +        </tr>
  +        <tr>
  +          <th>within-column</th>
  +        </tr>
  +        <tr>
  +          <th>within-page</th>
  +        </tr>
  +        <tr>
  +          <td>keep-together</td>
  +          <td>7.19.3</td>
  +          <td>yes</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>keep-with-next</td>
  +          <td>7.19.4</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
  +        <tr>
  +          <td>keep-with-previous</td>
  +          <td>7.19.5</td>
  +          <td>no</td>
  +          <td>yes</td>
  +        </tr>
         </table>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.3       +96 -95    xml-fop/src/documentation/content/xdocs/design/alt.design/coroutines.xml
  
  Index: coroutines.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/coroutines.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- coroutines.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ coroutines.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,116 +3,117 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Implementing co-routines</title>
  +  <header>
  +    <title>Implementing co-routines</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Implementing Co-routines in FOP</title>
         <p>
  -  All general page layout systems have to solve the same
  -  fundamental problem: expressing a flow of text with its own
  -  natural structure as a series of pages corresponding to the
  -  physical and logical structure of the output medium.  This
  -  simple description disguises many complexities.  Version 1.0
  -  of the Recommendation, in Section 3, <em>Introduction to
  -  Formatting </em>, includes the following comments.
  +        All general page layout systems have to solve the same
  +        fundamental problem: expressing a flow of text with its own
  +        natural structure as a series of pages corresponding to the
  +        physical and logical structure of the output medium.  This
  +        simple description disguises many complexities.  Version 1.0
  +        of the Recommendation, in Section 3, <em>Introduction to
  +          Formatting </em>, includes the following comments.
         </p>
         <note>
  -  [Formatting] comprises several steps, some of which depend on
  -  others in a non-sequential way.<br/> ...and...<br/>
  -  [R]efinement is not necessarily a straightforward, sequential
  -  procedure, but may involve look-ahead, back-tracking, or
  -  control-splicing with other processes in the formatter.
  +        [Formatting] comprises several steps, some of which depend on
  +        others in a non-sequential way.<br/> ...and...<br/>
  +        [R]efinement is not necessarily a straightforward, sequential
  +        procedure, but may involve look-ahead, back-tracking, or
  +        control-splicing with other processes in the formatter.
         </note>
         <p>Section 3.1, <em>Conceptual Procedure</em>, includes:</p>
         <note>
  -  The procedure works by processing formatting objects. Each
  -  object, while being processed, may initiate processing in
  -  other objects. While the objects are hierarchically
  -  structured, the processing is not; processing of a given
  -  object is rather like a co-routine which may pass control to
  -  other processes, but pick up again later where it left off.
  +        The procedure works by processing formatting objects. Each
  +        object, while being processed, may initiate processing in
  +        other objects. While the objects are hierarchically
  +        structured, the processing is not; processing of a given
  +        object is rather like a co-routine which may pass control to
  +        other processes, but pick up again later where it left off.
         </note>
         <section>
           <title>Application of co-routines</title>
  -  <p>
  -    If one looks only at the flow side of the equation, it's
  -    difficult to see what the problem might be.  The ordering of
  -    the elements of the flow is preserved in the area tree, and
  -    where elements are in an hierarchical relationship in the
  -    flow, they will generally be in an hierarchical relationship
  -    in the area tree.  In such circumstances, the recursive
  -    processing of the flow seems quite natural.
  -  </p>
  -  <p>
  -    The problem becomes more obvious when one thinks about the
  -    imposition of an unrelated page structure over the
  -    hierarchical structure of the document content.  Take, e.g.,
  -    the processing of a nested flow structure which, at a certain
  -    point, is scanning text and generating line-areas, nested
  -    within other block areas and possibly other line areas.  The
  -    page fills in the middle of this process.  Processing at the
  -    lowest level in the tree must now suspend, immediately
  -    following the production of the line-area which filled the
  -    page.  This same event, however, must also trigger the closing
  -    and flushing to the area tree of every open area of which the last
  -    line-area was a descendant.
  -  </p>
  -  <p>
  -    Once all of these areas have been closed, some dormant process
  -    or processes must wake up, flush the area sub-tree
  -    representing the page, and open a new page sub-tree in the
  -    area tree.  Then the whole nested structure of flow objects
  -    and area production must be re-activated, at the point in
  -    processing at which the areas of the previous page were
  -    finalised, but with the new page environment.  The most
  -    natural way of expressing the temporal relationship of these
  -    processes is by means of co-routines.
  -  </p>
  -  <p>
  -    Normal sub-routines (methods) display a hierarchical
  -    relationship where process A suspends on invoking process B,
  -    which on termination returns control to A which resumes from
  -    the point of suspension. Co-routines instead have a parallel
  -    relationship.  Process A suspends on invoking process B, but
  -    process B also suspends on returning control to process A.  To
  -    process B, this return of control appears to be an invocation
  -    of process A.  When process A subsequently invokes B and
  -    suspends, B behaves as though its previous invocation of A has
  -    returned, and it resumes from the point of that invocation.
  -    So control bounces between the two, each one resuming where it
  -    left off.<br/><br/>
  -    <strong>Figure 1</strong>
  -  </p>
  -  <figure src="images/design/alt.design/coroutines.png" alt="Co-routine diagram"/>
  -  <p>
  -    For example, think of a page-production method working on a
  -    complex page-sequence-master.
  -  </p>
  -  <source>
  -    void makePages(...) {
  -    ...
  -      while (pageSequence.hasNext()) {
  -        ...
  -        page = generateNextPage(...);
  -        boolean over = flow.fillPage(page);
  -        if (over) return;
  -      }
  -    }
  -  </source>
  -  <p>
  -    The <code>fillPage()</code> method, when it fills a page, will
  -    have unfinished business with the flow, which it will want to
  -    resume at the next call; hence co-routines.  One way to
  -    implement them in Java is by threads synchronised on some
  -    common argument-passing object.
  -  </p>
  +        <p>
  +          If one looks only at the flow side of the equation, it's
  +          difficult to see what the problem might be.  The ordering of
  +          the elements of the flow is preserved in the area tree, and
  +          where elements are in an hierarchical relationship in the
  +          flow, they will generally be in an hierarchical relationship
  +          in the area tree.  In such circumstances, the recursive
  +          processing of the flow seems quite natural.
  +        </p>
  +        <p>
  +          The problem becomes more obvious when one thinks about the
  +          imposition of an unrelated page structure over the
  +          hierarchical structure of the document content.  Take, e.g.,
  +          the processing of a nested flow structure which, at a certain
  +          point, is scanning text and generating line-areas, nested
  +          within other block areas and possibly other line areas.  The
  +          page fills in the middle of this process.  Processing at the
  +          lowest level in the tree must now suspend, immediately
  +          following the production of the line-area which filled the
  +          page.  This same event, however, must also trigger the closing
  +          and flushing to the area tree of every open area of which the last
  +          line-area was a descendant.
  +        </p>
  +        <p>
  +          Once all of these areas have been closed, some dormant process
  +          or processes must wake up, flush the area sub-tree
  +          representing the page, and open a new page sub-tree in the
  +          area tree.  Then the whole nested structure of flow objects
  +          and area production must be re-activated, at the point in
  +          processing at which the areas of the previous page were
  +          finalised, but with the new page environment.  The most
  +          natural way of expressing the temporal relationship of these
  +          processes is by means of co-routines.
  +        </p>
  +        <p>
  +          Normal sub-routines (methods) display a hierarchical
  +          relationship where process A suspends on invoking process B,
  +          which on termination returns control to A which resumes from
  +          the point of suspension. Co-routines instead have a parallel
  +          relationship.  Process A suspends on invoking process B, but
  +          process B also suspends on returning control to process A.  To
  +          process B, this return of control appears to be an invocation
  +          of process A.  When process A subsequently invokes B and
  +          suspends, B behaves as though its previous invocation of A has
  +          returned, and it resumes from the point of that invocation.
  +          So control bounces between the two, each one resuming where it
  +          left off.<br/><br/>
  +          <strong>Figure 1</strong>
  +        </p>
  +        <figure src="images/design/alt.design/coroutines.png"
  +                alt="Co-routine diagram"/>
  +        <p>
  +          For example, think of a page-production method working on a
  +          complex page-sequence-master.
  +        </p>
  +        <source>
  +          void makePages(...) {
  +              ...
  +              while (pageSequence.hasNext()) {
  +                  ...
  +                  page = generateNextPage(...);
  +                  boolean over = flow.fillPage(page);
  +                  if (over) return;
  +              }
  +          }
  +        </source>
  +        <p>
  +          The <code>fillPage()</code> method, when it fills a page, will
  +          have unfinished business with the flow, which it will want to
  +          resume at the next call; hence co-routines.  One way to
  +          implement them in Java is by threads synchronised on some
  +          common argument-passing object.
  +        </p>
         </section>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.3       +113 -113  xml-fop/src/documentation/content/xdocs/design/alt.design/footnotes.xml
  
  Index: footnotes.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/footnotes.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- footnotes.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ footnotes.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,138 +3,138 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Implementing footnotes</title>
  +  <header>
  +    <title>Implementing footnotes</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Implementing footnotes in FOP</title>
         <p>  
  -  Footnotes present difficulties for page layout primarily
  -  because their point of invocation in the flow is different
  -  from their point of appearance in the area tree.  All of the
  -  content lines of a footnote may appear on the same page as its
  -  invocation point, all may appear on a following page, or the
  -  lines may be split over a page or pages.  (This characteristic
  -  leads to another problem when a footnote overflows the last
  -  page of flow content, but that difficulty will not be 
  -  discussed here.)  This note considers some aspects of the
  -  implementation of footnotes in a galley-based design.
  +        Footnotes present difficulties for page layout primarily
  +        because their point of invocation in the flow is different
  +        from their point of appearance in the area tree.  All of the
  +        content lines of a footnote may appear on the same page as its
  +        invocation point, all may appear on a following page, or the
  +        lines may be split over a page or pages.  (This characteristic
  +        leads to another problem when a footnote overflows the last
  +        page of flow content, but that difficulty will not be 
  +        discussed here.)  This note considers some aspects of the
  +        implementation of footnotes in a galley-based design.
         </p>
         <section>
           <title>Footnotes and galleys</title>
  -  <p>
  -    In the structure described in the <link href=
  -    "galleys.html" >introduction to FOP galleys</link>,
  -    footnotes would be pre-processed as galleys themselves, but
  -    they would remain attached as subtrees to their points of 
  -    invocation in the main text.  Allocation to a
  -    footnote-reference-area would only occur in the resolution
  -    to Area nodes. 
  -  </p>
  -  <p>
  -    When footnotes are introduced, the communication between
  -    galleys and layout manager, as mentioned <link href=
  -    "galleys.html#pre-processing" >above</link>, would be
  -    affected.  The returned information would two b-p-d values: 
  -    the primary line-area b-p-d impact and the footnote b-p-d
  -    impact.  The distinction is necessary for two reasons; to
  -    alert the layout manager to the first footnote of the page,
  -    and because the footnote b-p-d will always impact the
  -    main-reference-area b-p-d, whereas the primary inline-area
  -    may not, e.g. in the case of multiple span-areas.
  -  </p>
  +        <p>
  +          In the structure described in the <link href= "galleys.html"
  +          >introduction to FOP galleys</link>, footnotes would be
  +          pre-processed as galleys themselves, but they would remain
  +          attached as subtrees to their points of invocation in the
  +          main text.  Allocation to a footnote-reference-area would
  +          only occur in the resolution to Area nodes.
  +        </p>
  +        <p>
  +          When footnotes are introduced, the communication between
  +          galleys and layout manager, as mentioned <link href=
  +          "galleys.html#pre-processing" >above</link>, would be
  +          affected.  The returned information would two b-p-d values:
  +          the primary line-area b-p-d impact and the footnote b-p-d
  +          impact.  The distinction is necessary for two reasons; to
  +          alert the layout manager to the first footnote of the page,
  +          and because the footnote b-p-d will always impact the
  +          main-reference-area b-p-d, whereas the primary inline-area
  +          may not, e.g. in the case of multiple span-areas.
  +        </p>
         </section>
         <section>
           <title>Multiple columns and footnotes</title>
  -  <note> 
  -    A possible method for multi-column layout and balancing
  -    with footnotes, using a galley-based approach.
  -  </note>
  -  <p>
  -    This note assumes a galley, as discussed <link href=
  -    "galleys.html" >elsewhere</link>, flowing text with
  -    footnotes and possibly other blocks into a possibly
  -    multi-column area.  The logic of flowing into multiple
  -    columns is trivially applied to a single column.  The galley
  -    is manipulated within the context of the <em>layout
  -    tree</em>.
  -  </p>
  -  <p>
  -    Associated with the galley are two sets of data.
  -    One contains the maps of all "natural" break-points and
  -    the of all hyphenation break-points.  This set is
  -    constructed at the time of construction of the galley and
  -    is a constant for a given galley.  The second contains
  -    dynamic data which represents one possible attempt to lay
  -    out the galley.  There may be multiple sets of such data
  -    to reflect varying attempts.  The data of this set are,
  -    essentially, representations of line-areas, with the supporting
  -    information necessary to determine these line-areas.
  -  </p>
  -  <p>
  -    The line-area data includes the boundaries within the
  -    galley of each line-area, the boundaries of each column
  -    and the boundaries of the "page", or main area.  When a
  -    line-area boundary occurs at a hyphenation point, a
  -    "virtual hyphen" is assumed and accounted for in the
  -    i-p-d.  As mentioned, individual footnote galleys will
  -    hang from the parent galley.  The associated data of the
  -    footnote galleys is similar: a once-only break-points map,
  -    and one or more line-area maps.  No column boundaries are
  -    required, but a page boundary is required at the end of
  -    the last footnote or where a footnote breaks across a page
  -    boundary.
  -  </p>
  -  <p>
  -    A number of b-p-d values are also maintained.  For each
  -    line-area, the b-p-d, the main area b-p-d increment, the
  -    footnote b-p-d increment and the footnote's page-related
  -    b-p-d increment are required.  The main-area b-p-d
  -    increments for any particular line-area are dependent on
  -    the column position of the line-area.  Total b-p-d's are
  -    also kept: total footnote b-p-d, total main area b-p-d,
  -    and totals for each column.<br/><br/>
  -    <strong>Figure 1</strong> Columns before first footnote.
  -  </p>
  -  <figure src="images/design/alt.design/initial-column-values.png" alt="Columns before
  -    first footnote"/>
  +        <note> 
  +          A possible method for multi-column layout and balancing
  +          with footnotes, using a galley-based approach.
  +        </note>
  +        <p>
  +          This note assumes a galley, as discussed <link href=
  +          "galleys.html" >elsewhere</link>, flowing text with
  +          footnotes and possibly other blocks into a possibly
  +          multi-column area.  The logic of flowing into multiple
  +          columns is trivially applied to a single column.  The galley
  +          is manipulated within the context of the <em>layout
  +          tree</em>.
  +        </p>
  +        <p>
  +          Associated with the galley are two sets of data.
  +          One contains the maps of all "natural" break-points and
  +          the of all hyphenation break-points.  This set is
  +          constructed at the time of construction of the galley and
  +          is a constant for a given galley.  The second contains
  +          dynamic data which represents one possible attempt to lay
  +          out the galley.  There may be multiple sets of such data
  +          to reflect varying attempts.  The data of this set are,
  +          essentially, representations of line-areas, with the supporting
  +          information necessary to determine these line-areas.
  +        </p>
  +        <p>
  +          The line-area data includes the boundaries within the
  +          galley of each line-area, the boundaries of each column
  +          and the boundaries of the "page", or main area.  When a
  +          line-area boundary occurs at a hyphenation point, a
  +          "virtual hyphen" is assumed and accounted for in the
  +          i-p-d.  As mentioned, individual footnote galleys will
  +          hang from the parent galley.  The associated data of the
  +          footnote galleys is similar: a once-only break-points map,
  +          and one or more line-area maps.  No column boundaries are
  +          required, but a page boundary is required at the end of
  +          the last footnote or where a footnote breaks across a page
  +          boundary.
  +        </p>
  +        <p>
  +          A number of b-p-d values are also maintained.  For each
  +          line-area, the b-p-d, the main area b-p-d increment, the
  +          footnote b-p-d increment and the footnote's page-related
  +          b-p-d increment are required.  The main-area b-p-d
  +          increments for any particular line-area are dependent on
  +          the column position of the line-area.  Total b-p-d's are
  +          also kept: total footnote b-p-d, total main area b-p-d,
  +          and totals for each column.<br/><br/>
  +          <strong>Figure 1</strong> Columns before first footnote.
  +        </p>
  +        <figure src=
  +        "images/design/alt.design/initial-column-values.png" alt=
  +        "Columns before first footnote"/>
         </section>
         <section>
           <title>Balancing columns</title>
  -  <p>
  -    <strong>Figure 2</strong> Adding a line area with first
  -    footnote.
  -  </p>
  -  <figure src="images/design/alt.design/line-area-5.png"
  -    alt="Columns after adding first footnote"/>
  -  <p>
  -    Columns are balanced dynamically in the galley preliminary
  -    layout.  While the galley retains its basic linear
  -    structure, the accompanying data structures accomplish
  -    column distribution and balancing.  As each line-area is
  -    added, the columns are re-balanced.  <strong>N.B.</strong>
  -    This re-balancing involves only some of the dynamic data
  -    associated with the participating galley(s).  The data
  -    structures associating breakpoints with the beginning and
  -    end of individual line areas does not change in
  -    re-balancing; only the association of line-area with column,
  -    and, possibly, the various impact values for each line-area.
  -    <br/><br/>
  -    <strong>Figure 3</strong> Adding a line area with next
  -    footnote.
  -  </p>
  -  <figure src="images/design/alt.design/line-area-6.png"
  -    alt="Columns after adding next footnote"/>
  +        <p>
  +          <strong>Figure 2</strong> Adding a line area with first
  +          footnote.
  +        </p>
  +        <figure src= "images/design/alt.design/line-area-5.png"
  +                alt= "Columns after adding first footnote"/>
  +        <p>
  +          Columns are balanced dynamically in the galley preliminary
  +          layout.  While the galley retains its basic linear
  +          structure, the accompanying data structures accomplish
  +          column distribution and balancing.  As each line-area is
  +          added, the columns are re-balanced.  <strong>N.B.</strong>
  +          This re-balancing involves only some of the dynamic data
  +          associated with the participating galley(s).  The data
  +          structures associating breakpoints with the beginning and
  +          end of individual line areas does not change in
  +          re-balancing; only the association of line-area with column,
  +          and, possibly, the various impact values for each line-area.
  +          <br/><br/>
  +          <strong>Figure 3</strong> Adding a line area with next
  +          footnote.
  +        </p>
  +        <figure src= "images/design/alt.design/line-area-6.png"
  +                alt= "Columns after adding next footnote"/>
         </section>
         <section>
           <title>Layout managers in the flow of control</title>
  -  <note>To be developed.</note>
  +        <note>To be developed.</note>
         </section>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.3       +189 -188  xml-fop/src/documentation/content/xdocs/design/alt.design/galleys.xml
  
  Index: galleys.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/galleys.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- galleys.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ galleys.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,214 +3,215 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Galleys</title>
  +  <header>
  +    <title>Galleys</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Layout galleys in FOP</title>
         <section>
           <title>Galleys in Lout</title>
  -  <p>
  -    Jeffrey H. Kingston, in <link href =
  -    "http://snark.niif.spb.su/~uwe/lout/design.pdf" ><em>The
  -    Design and Implementation of the Lout Document Formatting
  -    Language</em> Section 5</link>, describes the
  -    <strong>galley</strong> abstraction which he implemented in
  -    <em>Lout</em>.  A document to be formatted is a stream of
  -    text and symbols, some of which are <strong>receptive 
  -    symbols</strong>.  The output file is the first receptive
  -    symbol; the formatting document is the first galley.  The
  -    archetypical example of a receptive symbol is
  -    <strong>@FootPlace</strong> and its corresponding galley
  -    definition, <strong>@FootNote</strong>.
  -  </p>
  -  <p>
  -    Each galley should be thought of as a concurrent process, and
  -    each is associated with a semaphore (or synchronisation
  -    object.)  Galleys are free to "promote" components into
  -    receptive targets as long as</p>
  -  <ul>
  -    <li>
  -      an appropriate target has been encountered in the file,
  -    </li> 
  -    <li>
  -      the component being promoted contains no unresolved galley
  -      targets itself, and
  -    </li>
  -    <li>
  -      there is sufficient room for the galley component at the
  -      target.
  -    </li>
  -  </ul>
  -  <p>
  -    If these conditions are not met, the galley blocks on its
  -    semaphore.  When conditions change so that further progress
  -    may be possible, the semaphore is signalled.  Note that the
  -    galleys are a hierarchy, and that the processing and
  -    promotion of galley contents happens <em>bottom-up</em>.
  -  </p>
  +        <p>
  +          Jeffrey H. Kingston, in <link href =
  +          "http://snark.niif.spb.su/~uwe/lout/design.pdf" ><em>The
  +          Design and Implementation of the Lout Document Formatting
  +          Language</em> Section 5</link>, describes the
  +          <strong>galley</strong> abstraction which he implemented in
  +          <em>Lout</em>.  A document to be formatted is a stream of
  +          text and symbols, some of which are <strong>receptive
  +          symbols</strong>.  The output file is the first receptive
  +          symbol; the formatting document is the first galley.  The
  +          archetypical example of a receptive symbol is
  +          <strong>@FootPlace</strong> and its corresponding galley
  +          definition, <strong>@FootNote</strong>.
  +        </p>
  +        <p>
  +          Each galley should be thought of as a concurrent process, and
  +          each is associated with a semaphore (or synchronisation
  +          object.)  Galleys are free to "promote" components into
  +          receptive targets as long as</p>
  +        <ul>
  +          <li>
  +            an appropriate target has been encountered in the file,
  +          </li> 
  +          <li>
  +            the component being promoted contains no unresolved galley
  +            targets itself, and
  +          </li>
  +          <li>
  +            there is sufficient room for the galley component at the
  +            target.
  +          </li>
  +        </ul>
  +        <p>
  +          If these conditions are not met, the galley blocks on its
  +          semaphore.  When conditions change so that further progress
  +          may be possible, the semaphore is signalled.  Note that the
  +          galleys are a hierarchy, and that the processing and
  +          promotion of galley contents happens <em>bottom-up</em>.
  +        </p>
         </section>
         <section>
           <title>Some features of galleys</title>
  -  <p>
  -    It is essential to note that galleys are self-managing; they
  -    are effectively layout <em>bots</em> which require only a
  -    receptive area.  If a galley fills a receptive area (say, at
  -    the completion of a page), the galley will wait on its
  -    semaphore, and will remain stalled until a new receptive
  -    area is uncovered in the continued processing (say, as the
  -    filled page is flushed to output and a new empty page is
  -    generated.)
  -  </p>
  -  <p>
  -    Difficulties with this approach become evident when there
  -    are mutual dependencies between receptive areas which
  -    require negotiation between the respective galleys, and, in
  -    some cases, arbitrary deadlock breaking when there is no
  -    clear-cut resolution to conflicting demands.  Footnote
  -    processing and side floats are examples.  A thornier example
  -    is table column layout in <em>auto</em> mode, where the
  -    column widths are determined by the contents.  In
  -    implementing galleys in FOP, these difficulties must be
  -    taken into account, and some solutions proposed.
  -  </p>
  -  <p>
  -    Galleys model the whole of the process of creating the final
  -    formatted output; the document as a whole is regarded as a
  -    galley which flushes in to the output file.
  -  </p>
  +        <p>
  +          It is essential to note that galleys are self-managing; they
  +          are effectively layout <em>bots</em> which require only a
  +          receptive area.  If a galley fills a receptive area (say, at
  +          the completion of a page), the galley will wait on its
  +          semaphore, and will remain stalled until a new receptive
  +          area is uncovered in the continued processing (say, as the
  +          filled page is flushed to output and a new empty page is
  +          generated.)
  +        </p>
  +        <p>
  +          Difficulties with this approach become evident when there
  +          are mutual dependencies between receptive areas which
  +          require negotiation between the respective galleys, and, in
  +          some cases, arbitrary deadlock breaking when there is no
  +          clear-cut resolution to conflicting demands.  Footnote
  +          processing and side floats are examples.  A thornier example
  +          is table column layout in <em>auto</em> mode, where the
  +          column widths are determined by the contents.  In
  +          implementing galleys in FOP, these difficulties must be
  +          taken into account, and some solutions proposed.
  +        </p>
  +        <p>
  +          Galleys model the whole of the process of creating the final
  +          formatted output; the document as a whole is regarded as a
  +          galley which flushes in to the output file.
  +        </p>
         </section>
         <section>
           <title>The layout tree</title>
  -  <anchor id="layout-tree"/>
  -  <p>
  -    This proposal for implementing galleys in FOP makes use of a
  -    <strong>layout tree</strong>.  As with the <link href=
  -    "../layout.html" >layout managers</link><em></em> already
  -    proposed, the layout tree acts as a bridge between the <link
  -    href= "../fotree.html" >FO Tree</link> and the <link href=
  -    "../areas.html" >Area Tree</link>.  If the elements of
  -    the FO Tree are FO nodes, and the elements of the Area Tree
  -    are Area nodes, representing areas to be drawn on the output
  -    medium, the elements of the layout tree are <strong>galley
  -    nodes</strong> and <strong>area tree fragments</strong>.
  -    The area tree fragments are the final stages of the
  -    resolution of the galleys; the output of the galleys will be
  -    inserted directly into the Area Tree.  The tree structure
  -    makes it clear that the whole of the formatting process in
  -    FOP, under this model, is a hierarchical series of galleys.
  -    The dynamic data comes from fo:flow and fo:static-content,
  -    and the higher-level receptive areas are derived from the
  -    <em>layout-master-set</em>.
  -  </p>
  +        <anchor id="layout-tree"/>
  +        <p>
  +          This proposal for implementing galleys in FOP makes use of a
  +          <strong>layout tree</strong>.  As with the <link href=
  +          "../layout.html" >layout managers</link><em></em> already
  +          proposed, the layout tree acts as a bridge between the <link
  +          href= "../fotree.html" >FO Tree</link> and the <link href=
  +          "../areas.html" >Area Tree</link>.  If the elements of the
  +          FO Tree are FO nodes, and the elements of the Area Tree are
  +          Area nodes, representing areas to be drawn on the output
  +          medium, the elements of the layout tree are <strong>galley
  +          nodes</strong> and <strong>area tree fragments</strong>.
  +          The area tree fragments are the final stages of the
  +          resolution of the galleys; the output of the galleys will be
  +          inserted directly into the Area Tree.  The tree structure
  +          makes it clear that the whole of the formatting process in
  +          FOP, under this model, is a hierarchical series of galleys.
  +          The dynamic data comes from fo:flow and fo:static-content,
  +          and the higher-level receptive areas are derived from the
  +          <em>layout-master-set</em>.
  +        </p>
         </section>
         <section>
           <title>Processing galleys</title>
  -  <p>
  -    Galleys are processed in two basic processing environments:
  -  </p>
  -  <section>
  -    <title>Inline- and block-progression dimensions known</title>
  -    <p>
  -      The galley at set-up is provided with both an
  -      <em>inline-progression-dimension</em> (<em>i-p-d</em>) and
  -      a <em>block-progression-dimension</em> (<em>b-p-d</em>).
  -      In this case, no further intervention is necessary to lay
  -      out the galley.  The galley has the possibility of laying
  -      itself out, creating all necessary area nodes.  This does
  -      not preclude the possibility that some children of this
  -      galley will not be able to be so directly laid out, and
  -      will fall into the second category.
  -    </p>
  -    <p>
  -      While the option of "automatic" layout exists, to use
  -      such a method would relinquish the possibility of
  -      monitoring the results of such layout and performing
  -      fine-tuning.
  -    </p>
  -  </section>
  -  <section>
  -    <title>Inline- ior block-progression-dimensions unknown</title>
  -    <p>
  -      The galley cannot immediately be provided with an i-p-d
  -      ior a b-p-d.  This will occur in some of the difficult
  -      cases mentioned earlier.  In these cases, the parent
  -      galley acts as a layout manager, similar to the sense used
  -      in <link href= "../layout.html" >another
  -      discussion</link>.  The children, lacking full receptive
  -      area dimensions, will proceed with galley pre-processing,
  -      a procedure which will, of necessity, be followed
  -      recursively by all of its children down to the atomic
  -      elements of the galley.  These atomic elements are the
  -      individual <em>fo:character</em> nodes and images of fixed
  -      dimensions.
  -    </p>
  -  </section>
  +        <p>
  +          Galleys are processed in two basic processing environments:
  +        </p>
  +        <section>
  +          <title>Inline- and block-progression dimensions known</title>
  +          <p>
  +            The galley at set-up is provided with both an
  +            <em>inline-progression-dimension</em> (<em>i-p-d</em>) and
  +            a <em>block-progression-dimension</em> (<em>b-p-d</em>).
  +            In this case, no further intervention is necessary to lay
  +            out the galley.  The galley has the possibility of laying
  +            itself out, creating all necessary area nodes.  This does
  +            not preclude the possibility that some children of this
  +            galley will not be able to be so directly laid out, and
  +            will fall into the second category.
  +          </p>
  +          <p>
  +            While the option of "automatic" layout exists, to use
  +            such a method would relinquish the possibility of
  +            monitoring the results of such layout and performing
  +            fine-tuning.
  +          </p>
  +        </section>
  +        <section>
  +          <title>Inline- ior block-progression-dimensions unknown</title>
  +          <p>
  +            The galley cannot immediately be provided with an i-p-d
  +            ior a b-p-d.  This will occur in some of the difficult
  +            cases mentioned earlier.  In these cases, the parent
  +            galley acts as a layout manager, similar to the sense used
  +            in <link href= "../layout.html" >another
  +              discussion</link>.  The children, lacking full receptive
  +            area dimensions, will proceed with galley pre-processing,
  +            a procedure which will, of necessity, be followed
  +            recursively by all of its children down to the atomic
  +            elements of the galley.  These atomic elements are the
  +            individual <em>fo:character</em> nodes and images of fixed
  +            dimensions.
  +          </p>
  +        </section>
         </section>
         <section>
           <title>Galley pre-processing</title>
  -  <anchor id="pre-processing"/>
  -  <p>
  -    Galley pre-processing involves the spatial resolution of
  -    objects from the flows to the greatest extent possible
  -    without information on the dimensions of the target area.
  -    Line-areas have a block progression dimension which is
  -    determined by their contents. To achieve full generality in
  -    layouts of indeterminate dimensions, the contents of
  -    line-areas should be laid out as though their inline
  -    progression dimension were limited only by their content.
  -    In terms of inline-areas, galleys would process text and
  -    resolve the dimensions of included images.  Text would be
  -    collected into runs with the same alignment
  -    characteristics. In the process, all possible "natural" and
  -    hyphenation break-points can be determined.  Where a
  -    line-area contains mixed fonts or embedded images, the b-p-d
  -    of the individual line-areas which are eventually stacked
  -    will, in general, depend on the line break points, but the
  -    advantage of this approach is that such actual selections
  -    can be backed out and new break points selected with a
  -    minimum of re-calculation.  This can potentially occur
  -    whenever a first attempt at page layout is backed out.
  -    <br/><br/>
  -    <strong>Figure 1</strong>
  -  </p>
  -  <figure src="images/design/alt.design/galley-preprocessing.png" alt="Galley
  -    pre-processing diagram"/>
  -  <p>
  -    Once this pre-processing has been achieved, it is
  -    envisaged that a layout manager might make requests to the
  -    galley of its ability to fill an area of a given
  -    inline-progression-dimension.  A positive response would
  -    be accompanied by the block-progression-dimension.  The
  -    other possibilities are a partial fill, which would also
  -    require b-p-d data, and a failure due to insufficient
  -    i-p-d, in which case the minimum i-p-d requirement would
  -    be returned.  Note that decisions about the
  -    actual dimensions of line-areas to be filled can be
  -    deferred until all options have been tested.
  -  </p>
  -  <p>
  -    The other primary form of information provided by a
  -    pre-processed galley is its minimum and maximum i-p-d, so
  -    that decisions can be made by the parent on the spacing of
  -    table columns.  Apart from information requests,
  -    higher-level processes can either make requests of the
  -    galleys for chunks of nominated sizes, or simply provide the
  -    galley with an i-p-d and b-p-d, which will trigger the
  -    flushing of the galley components into Area nodes.  Until
  -    they have flushed, the galleys must be able to respond to a
  -    sequence of information requests, more or less in the manner
  -    of a request iterator, and separately manage the flushing of
  -    objects into the area tree.  The purpose of the "request
  -    iterator" would be to support "incremental" information
  -    requests like <em>getNextBreakPosition</em>.
  -  </p>
  +        <anchor id="pre-processing"/>
  +        <p>
  +          Galley pre-processing involves the spatial resolution of
  +          objects from the flows to the greatest extent possible
  +          without information on the dimensions of the target area.
  +          Line-areas have a block progression dimension which is
  +          determined by their contents. To achieve full generality in
  +          layouts of indeterminate dimensions, the contents of
  +          line-areas should be laid out as though their inline
  +          progression dimension were limited only by their content.
  +          In terms of inline-areas, galleys would process text and
  +          resolve the dimensions of included images.  Text would be
  +          collected into runs with the same alignment
  +          characteristics. In the process, all possible "natural" and
  +          hyphenation break-points can be determined.  Where a
  +          line-area contains mixed fonts or embedded images, the b-p-d
  +          of the individual line-areas which are eventually stacked
  +          will, in general, depend on the line break points, but the
  +          advantage of this approach is that such actual selections
  +          can be backed out and new break points selected with a
  +          minimum of re-calculation.  This can potentially occur
  +          whenever a first attempt at page layout is backed out.
  +          <br/><br/>
  +          <strong>Figure 1</strong>
  +        </p>
  +        <figure
  +                src="images/design/alt.design/galley-preprocessing.png"
  +                alt="Galley pre-processing diagram"/>
  +        <p>
  +          Once this pre-processing has been achieved, it is
  +          envisaged that a layout manager might make requests to the
  +          galley of its ability to fill an area of a given
  +          inline-progression-dimension.  A positive response would
  +          be accompanied by the block-progression-dimension.  The
  +          other possibilities are a partial fill, which would also
  +          require b-p-d data, and a failure due to insufficient
  +          i-p-d, in which case the minimum i-p-d requirement would
  +          be returned.  Note that decisions about the
  +          actual dimensions of line-areas to be filled can be
  +          deferred until all options have been tested.
  +        </p>
  +        <p>
  +          The other primary form of information provided by a
  +          pre-processed galley is its minimum and maximum i-p-d, so
  +          that decisions can be made by the parent on the spacing of
  +          table columns.  Apart from information requests,
  +          higher-level processes can either make requests of the
  +          galleys for chunks of nominated sizes, or simply provide the
  +          galley with an i-p-d and b-p-d, which will trigger the
  +          flushing of the galley components into Area nodes.  Until
  +          they have flushed, the galleys must be able to respond to a
  +          sequence of information requests, more or less in the manner
  +          of a request iterator, and separately manage the flushing of
  +          objects into the area tree.  The purpose of the "request
  +          iterator" would be to support "incremental" information
  +          requests like <em>getNextBreakPosition</em>.
  +        </p>
         </section>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.2       +100 -57   xml-fop/src/documentation/content/xdocs/design/alt.design/index.xml
  
  Index: index.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/index.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- index.xml	2 Dec 2002 10:19:43 -0000	1.1
  +++ index.xml	18 Dec 2002 16:25:24 -0000	1.2
  @@ -2,83 +2,126 @@
   <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.1//EN"
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
  +<!-- $Id$ -->
  +
   <document>
  -    <header>
  +  <header>
       <title>FOP Alternative Design</title>
       <subtitle>Alternative Design Approach to FOP</subtitle>
       <version>$Revision$ $Name$</version>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  
  +  <body>
       <section>
         <title>Alternative Design</title>
         <p>
  -  This section of the FOP web site contains notes on approaches
  -  to an alternative design for FOP.  The individual documents
  -  here are fragmentary, being notes of particular issues,
  -  without an overall framework as yet. 
  +	This section of the FOP web site contains notes on approaches
  +	to an alternative design for FOP.  The individual documents
  +	here are fragmentary, being notes of particular issues,
  +	without an overall framework as yet.
         </p>
         <p>
  -  The main aims of this redesign effort are:
  +	The main aims of this redesign effort are:
         </p>
         <ul>
  -  <li>full conformance with the Recommendation</li>
  -  <li>increased performance</li> 
  -  <li>reduced memory footprint</li> 
  -  <li>no limitation on the size of files</li>
  +	<li>full conformance with the Recommendation</li>
  +	<li>no limitation on the size of files</li>
  +	<li>increased performance</li>
  +	<li>reduced memory footprint</li>
         </ul>
         <p>
  -  In order to achieve these aims, the primary areas
  -  of design interest are:
  +	Secondary aims include:
         </p>
         <ul>
  -  <li>
  -    Representing properties, for most purposes, as integers.
  -  </li>
  -  <li>
  -    Distributing FOP processing over a number of threads with
  -    single-point downstream communication and flow control by
  -    means of traditional producer/consumer queues.  The threads
  -    so far under consideration are:
  -    <ul>
  -      <li>XML parser</li>
  -      <li>FO tree builder</li>
  -      <li>layout engine</li>
  -      <li>Area tree builder</li>
  -    </ul>
  -  </li>
  -  <li>
  -    Representing trees with explicit Tree objects, rather than
  -    as implicit relationships among other objects.
  -  </li>
  -  <li>
  -    Caching integrated into the tree node access methods.
  -  </li>
  +	<li>increased performance</li>
  +	<li>reduced memory footprint</li>
  +      </ul>
  +      <p>
  +	In order to achieve these aims, the primary areas
  +	of design interest are:
  +      </p>
  +      <ul>
  +	<li>
  +	  Representing properties, for most purposes, as integers.
  +	</li>
  +        <li>
  +          Implementing a top-down processing model for each of the
  +          processing components.
  +        </li>
  +	<li>
  +	  Distributing FOP processing over a number of threads with
  +	  single-point downstream communication and flow control by
  +	  means of traditional producer/consumer queues.  The threads
  +	  so far under consideration are:
  +	  <ul>
  +	    <li>XML parser</li>
  +	    <li>FO tree builder</li>
  +	    <li>layout engine</li>
  +	    <li>Area tree builder</li>
  +	  </ul>
  +	</li>
  +        <li>
  +          Redesigning XML parsing and FO tree building using a
  +          <strong>pull-parsing</strong> methodology with integrated FO
  +          input validation.
  +        </li>
  +        <li>
  +          Representing vital relationships among the elements with
  +          appropriate data structures.  These include:
  +          <ul>
  +            <li>
  +              Representing trees with explicit Tree objects, rather than
  +              as implicit relationships among other objects.
  +            </li>
  +            <li>
  +              Drawing threads through the tree nodes to
  +              represent linear layout relationships for resolving
  +              keeps, breaks and space specifiers. 
  +            </li>
  +          </ul>
  +        </li>
  +	<li>
  +	  Caching integrated into the tree node access methods.
  +	</li>
         </ul>
         <section>
  -        <title>Status and availability</title> 
  -  <p>
  -    The <em>ALT DESIGN</em> effort is not taking place on the
  -    main line of development, represented by the <em>HEAD</em>
  -    tag on the CVS trunk.  The source is available via the
  -    FOP_0-20-0_Alt-Design tag.  This code has only a crude,
  -    non-<em>Ant</em> build environment, and is expected only to
  -    compile at this stage.  Only the parser stage and the first
  -    stage of FO tree building is present.  However, the first
  -    example of producer/consumer binding is working, the Tree
  -    class with inner Tree.Node and inner
  -    Tree.Node.<em>iterators</em> classes are available and
  -    working.  Property handling is quite advanced, and is likely
  -    to be almost complete some time in July, 2002.
  -  </p>
  -  <p>
  -    Only <link href="mailto:pbwest@powerup.com.au">Peter
  -    West</link> is working on the ALT DESIGN sub-project.
  -  </p>
  +        <title>Status and availability</title>
  +	<p>
  +	  The <em>ALT DESIGN</em> effort is not taking place on the
  +	  main line of development, represented by the <em>HEAD</em>
  +	  tag on the CVS trunk.  The source is available via the
  +	  FOP_0-20-0_Alt-Design tag.  This code has only a
  +	  non-<em>Ant</em> build environment based on some small unix
  +	  shell scripts and the <em>jikes</em> compiler.  The parser
  +	  stage and the FO tree building code is present.  The first
  +	  example of producer/consumer binding is working, the Tree
  +	  class and the Node class with inner <em>iterator</em>
  +	  classes are available and working.  Property handling is
  +	  almost complete, and all FO classes are present and
  +          sufficiently complete to allow for FO tree building.
  +	</p>
  +        <p>
  +          <link href=
  +          "http://marc.theaimsgroup.com/%3Fl=fop-dev%26m=103890259919360%26w=2"
  +          >Preliminary results</link> and <link href=
  +          "http://marc.theaimsgroup.com/%3Fl=fop-dev%26m=103918886413611%26w=2"
  +          >follow-up testing</link> of FO tree building shows memory
  +          reductions of almost 50% compared to the most recently tuned
  +          version of the maintenance version of the code (FOP 0.20.5
  +          RC).  Alt-Design FO tree building was also slightly faster,
  +          in spite of the use of pull parsing implemented on top of
  +          SAX.
  +        </p>
  +	<p>
  +	  Currently, only <link href="mailto:pbwest@powerup.com.au">Peter
  +	  West</link> is working on the ALT DESIGN sub-project.
  +	</p>
         </section>
       </section>
  -    </body>
  +
  +  </body>
   </document>
   
  
  
  
  1.3       +89 -89    xml-fop/src/documentation/content/xdocs/design/alt.design/keeps.xml
  
  Index: keeps.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/keeps.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- keeps.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ keeps.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,108 +3,108 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Keeps and breaks</title>
  +  <header>
  +    <title>Keeps and breaks</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Keeps and breaks in layout galleys</title>
         <p>
  -  The <link href= "galleys.html" >layout galleys</link> and the
  -  <link href= "galleys.html#layout-tree" >layout tree</link>
  -  which is their context have been discussed elsewhere.  Here we
  -  discuss a possible method of implementing keeps and breaks
  -  within the context of layout galleys and the layout tree.
  +        The <link href= "galleys.html" >layout galleys</link> and the
  +        <link href= "galleys.html#layout-tree" >layout tree</link>
  +        which is their context have been discussed elsewhere.  Here we
  +        discuss a possible method of implementing keeps and breaks
  +        within the context of layout galleys and the layout tree.
         </p>
         <section>
           <title>Breaks</title>
  -  <p> 
  -    Breaks may be handled by inserting a column- or page-break
  -    pseudo-object into the galley stream.  For break-before, the
  -    object would be inserted before the area in which the flow
  -    object, to which the property is attached, is leading.  If
  -    the flow object is leading in no ancestor context, the
  -    pseudo-object is inserted before the object itself.
  -    Corresponding considerations apply for break-after. 
  -    Selection of the position for these objects will be further
  -    examined in the discussion on keeps.
  -  </p>
  +        <p> 
  +          Breaks may be handled by inserting a column- or page-break
  +          pseudo-object into the galley stream.  For break-before, the
  +          object would be inserted before the area in which the flow
  +          object, to which the property is attached, is leading.  If
  +          the flow object is leading in no ancestor context, the
  +          pseudo-object is inserted before the object itself.
  +          Corresponding considerations apply for break-after. 
  +          Selection of the position for these objects will be further
  +          examined in the discussion on keeps.
  +        </p>
         </section>
         <section>
           <title>Keeps</title>
  -  <p> 
  -    Conceptually, all keeps can be represented by a
  -    keep-together pseudo-area.  The keep-together property
  -    itself is expressed during layout by wrapping all of the
  -    generated areas in a keep-together area.  Keep-with-previous
  -    on formatting object A becomes a keep-together area spanning
  -    the first non-blank normal area leaf node, L, generated by A
  -    or its offspring, and the last non-blank normal area leaf
  -    node preceding L in the area tree.  Likewise, keep-with-next
  -    on formatting object A becomes a keep-together area spanning
  -    the last non-blank normal area leaf node, L, generated by A
  -    or its offspring, and the first non-blank normal area leaf
  -    node following L in the area tree.
  -    <br/>TODO REWORK THIS for block vs inline
  -  </p>
  -  <p>
  -    The obvious problem with this arrangement is that the
  -    keep-together area violate the hierarachical arrangement of
  -    the layout tree.  They form a concurrent structure focussed
  -    on the leaf nodes.  This seems to be the essential problem
  -    of handling keep-with-(previous/next); that it cuts across
  -    the otherwise tree-structured flow of processing.  Such
  -    problems are endemic in page layout. 
  -  </p>
  -  <p>
  -    In any case, it seems that the relationships between areas
  -    that are of interest in keep processing need some form of
  -    direct expression, parallel to the layout tree itself.
  -    Restricting ourselves too block-level elements, and looking
  -    only at the simple block stacking cases, we get a diagram
  -    like the attached PNG.  In order to track the relationships
  -    through the tree, we need four sets of links.
  -  </p>
  -  <p>
  -    <strong>Figure 1</strong>
  -  </p>
  -  <anchor id="Figure1"/>
  -  <figure src="images/design/alt.design/block-stacking.png" alt="Simple block-stacking
  -    diagram"/>
  -  <p>
  -    The three basic links are:
  -  </p>
  -  <ul>
  -    <!-- one of (dl sl ul ol li) -->
  -    <li>Leading edge to leading edge of first normal child.</li>
  -    <li>Trailing edge to leading edge of next normal
  -      sibling.</li>
  -    <li>Trailing edge to trailing edge of parent.</li>
  -  </ul>
  -  <p>
  -    Superimposed on the basic links are bridging links which
  -    span adjacent sets of links.  These spanning links are the
  -    tree violators, and give direct access to the areas which
  -    are of interest in keep processing. They could be
  -    implemented as double-linked lists, either within the layout
  -    tree nodes or as separate structures.  Gaps in the spanning
  -    links are joined by simply reproducing the single links, as
  -    in the diagram. The whole layout tree for a page is
  -    effectively threaded in order of interest, as far as keeps
  -    are concerned.
  -  </p>
  -  <p>
  -    The bonus of this structure is that it looks like a superset
  -    of the stacking constraints.  It gives direct access to all
  -    sets of adjacent edges and sets of edges whose space
  -    specifiers need to be resolved. Fences can be easily enough
  -    detected during the process of space resolution.
  -  </p>
  +        <p> 
  +          Conceptually, all keeps can be represented by a
  +          keep-together pseudo-area.  The keep-together property
  +          itself is expressed during layout by wrapping all of the
  +          generated areas in a keep-together area.  Keep-with-previous
  +          on formatting object A becomes a keep-together area spanning
  +          the first non-blank normal area leaf node, L, generated by A
  +          or its offspring, and the last non-blank normal area leaf
  +          node preceding L in the area tree.  Likewise, keep-with-next
  +          on formatting object A becomes a keep-together area spanning
  +          the last non-blank normal area leaf node, L, generated by A
  +          or its offspring, and the first non-blank normal area leaf
  +          node following L in the area tree.
  +          <br/>TODO REWORK THIS for block vs inline
  +        </p>
  +        <p>
  +          The obvious problem with this arrangement is that the
  +          keep-together area violate the hierarachical arrangement of
  +          the layout tree.  They form a concurrent structure focussed
  +          on the leaf nodes.  This seems to be the essential problem
  +          of handling keep-with-(previous/next); that it cuts across
  +          the otherwise tree-structured flow of processing.  Such
  +          problems are endemic in page layout. 
  +        </p>
  +        <p>
  +          In any case, it seems that the relationships between areas
  +          that are of interest in keep processing need some form of
  +          direct expression, parallel to the layout tree itself.
  +          Restricting ourselves too block-level elements, and looking
  +          only at the simple block stacking cases, we get a diagram
  +          like the attached PNG.  In order to track the relationships
  +          through the tree, we need four sets of links.
  +        </p>
  +        <p>
  +          <strong>Figure 1</strong>
  +        </p>
  +        <anchor id="Figure1"/><figure src=
  +        "images/design/alt.design/block-stacking.png" alt= "Simple
  +        block-stacking diagram"/>
  +        <p>
  +          The three basic links are:
  +        </p>
  +        <ul>
  +          <!-- one of (dl sl ul ol li) -->
  +          <li>Leading edge to leading edge of first normal child.</li>
  +          <li>Trailing edge to leading edge of next normal
  +            sibling.</li>
  +          <li>Trailing edge to trailing edge of parent.</li>
  +        </ul>
  +        <p>
  +          Superimposed on the basic links are bridging links which
  +          span adjacent sets of links.  These spanning links are the
  +          tree violators, and give direct access to the areas which
  +          are of interest in keep processing. They could be
  +          implemented as double-linked lists, either within the layout
  +          tree nodes or as separate structures.  Gaps in the spanning
  +          links are joined by simply reproducing the single links, as
  +          in the diagram. The whole layout tree for a page is
  +          effectively threaded in order of interest, as far as keeps
  +          are concerned.
  +        </p>
  +        <p>
  +          The bonus of this structure is that it looks like a superset
  +          of the stacking constraints.  It gives direct access to all
  +          sets of adjacent edges and sets of edges whose space
  +          specifiers need to be resolved. Fences can be easily enough
  +          detected during the process of space resolution.
  +        </p>
         </section>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.3       +119 -119  xml-fop/src/documentation/content/xdocs/design/alt.design/properties-classes.xml
  
  Index: properties-classes.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/properties-classes.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- properties-classes.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ properties-classes.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,141 +3,141 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Properties$classes</title>
  +  <header>
  +    <title>Properties$classes</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>fo.Properties and the nested properties classes</title>
  -      <figure src="images/design/alt.design/PropertyClasses.png" alt="Nested property and
  -        top-level classes"/> 
  +      <figure src= "images/design/alt.design/PropertyClasses.png" alt=
  +      "Nested property and top-level classes"/>
         <section>
           <title>Nested property classes</title>
  -  <p>
  -    Given the intention that individual properties have only a
  -    <em>virtual</em> instantiation in the arrays of
  -    <code>PropertyConsts</code>, these classes are intended to
  -    remain as repositories of static data and methods.  The name
  -    of each property is entered in the
  -    <code>PropNames.propertyNames</code> array of
  -    <code>String</code>s, and each has a unique integer constant
  -    defined, corresponding to the offset of the property name in
  -    that array.
  -  </p>
  -  <section>
  -    <title>Fields common to all classes</title>
  -    <dl> 
  -      <dt><code>final int dataTypes</code></dt>
  -      <dd>
  -        This field defines the allowable data types which may be
  -        assigned to the property.  The value is chosen from the
  -        data type constants defined in <code>Properties</code>, and
  -        may consist of more than one of those constants,
  -        bit-ORed together.
  -      </dd>
  -      <dt><code>final int traitMapping</code></dt>
  -      <dd>
  -        This field defines the mapping of properties to traits
  -        in the <code>Area tree</code>. The value is chosen from the
  -        trait mapping constants defined in <code>Properties</code>,
  -        and may consist of more than one of those constants,
  -        bit-ORed together.
  -      </dd>
  -      <dt><code>final int initialValueType</code></dt>
  -      <dd>
  -        This field defines the data type of the initial value
  -        assigned to the property.  The value is chosen from the
  -        initial value type constants defined in
  -        <code>Properties</code>.
  -      </dd>
  -      <dt><code>final int inherited</code></dt>
  -      <dd>
  -        This field defines the kind of inheritance applicable to
  -        the property.  The value is chosen from the inheritance
  -        constants defined in <code>Properties</code>. 
  -      </dd>
  -    </dl>
  -  </section>
  -  <section>
  -    <title>Datatype dependent fields</title>
  -    <dl>
  -      <dt>Enumeration types</dt>
  -      <dd>
  -        <strong><code>final String[] enums</code></strong><br/>
  -        This array contains the <code>NCName</code>  text
  -        values of the enumeration.  In the current
  -        implementation, it always contains a null value at
  -        <code>enum[0]</code>.<br/> <br/>
  +        <p>
  +          Given the intention that individual properties have only a
  +          <em>virtual</em> instantiation in the arrays of
  +          <code>PropertyConsts</code>, these classes are intended to
  +          remain as repositories of static data and methods.  The name
  +          of each property is entered in the
  +          <code>PropNames.propertyNames</code> array of
  +          <code>String</code>s, and each has a unique integer constant
  +          defined, corresponding to the offset of the property name in
  +          that array.
  +        </p>
  +        <section>
  +          <title>Fields common to all classes</title>
  +          <dl> 
  +            <dt><code>final int dataTypes</code></dt>
  +            <dd>
  +              This field defines the allowable data types which may be
  +              assigned to the property.  The value is chosen from the
  +              data type constants defined in <code>Properties</code>, and
  +              may consist of more than one of those constants,
  +              bit-ORed together.
  +            </dd>
  +            <dt><code>final int traitMapping</code></dt>
  +            <dd>
  +              This field defines the mapping of properties to traits
  +              in the <code>Area tree</code>. The value is chosen from the
  +              trait mapping constants defined in <code>Properties</code>,
  +              and may consist of more than one of those constants,
  +              bit-ORed together.
  +            </dd>
  +            <dt><code>final int initialValueType</code></dt>
  +            <dd>
  +              This field defines the data type of the initial value
  +              assigned to the property.  The value is chosen from the
  +              initial value type constants defined in
  +              <code>Properties</code>.
  +            </dd>
  +            <dt><code>final int inherited</code></dt>
  +            <dd>
  +              This field defines the kind of inheritance applicable to
  +              the property.  The value is chosen from the inheritance
  +              constants defined in <code>Properties</code>. 
  +            </dd>
  +          </dl>
  +        </section>
  +        <section>
  +          <title>Datatype dependent fields</title>
  +          <dl>
  +            <dt>Enumeration types</dt>
  +            <dd>
  +              <strong><code>final String[] enums</code></strong><br/>
  +              This array contains the <code>NCName</code>  text
  +              values of the enumeration.  In the current
  +              implementation, it always contains a null value at
  +              <code>enum[0]</code>.<br/> <br/>
   
  -        <strong><code>final String[]
  -        enumValues</code></strong><br/> When the number of
  -        enumeration values is small,
  -        <code>enumValues</code>  is a reference to the
  -        <code>enums</code>  array.<br/> <br/>
  +              <strong><code>final String[]
  +                  enumValues</code></strong><br/> When the number of
  +              enumeration values is small,
  +              <code>enumValues</code>  is a reference to the
  +              <code>enums</code>  array.<br/> <br/>
   
  -        <strong><code>final HashMap
  -        enumValues</code></strong><br/> When the number of
  -        enumeration values is larger,
  -        <code>enumValues</code>  is a
  -        <code>HashMap</code>  statically initialized to
  -        contain the integer constant values corresponding to
  -        each text value, indexed by the text
  -        value.<br/> <br/>
  +              <strong><code>final HashMap
  +                  enumValues</code></strong><br/> When the number of
  +              enumeration values is larger,
  +              <code>enumValues</code>  is a
  +              <code>HashMap</code>  statically initialized to
  +              contain the integer constant values corresponding to
  +              each text value, indexed by the text
  +              value.<br/> <br/>
   
  -        <strong><code>final int</code></strong>
  -        <em><code>enumeration-constants</code></em><br/> A
  -        unique integer constant is defined for each of the
  -        possible enumeration values.<br/> <br/>
  -      </dd>
  -      <dt>Many types:
  -        <code>final</code>  <em>datatype</em>
  -        <code>initialValue</code></dt>
  -      <dd>
  -        When the initial datatype does not have an implicit
  -        initial value (as, for example, does type
  -        <code>AUTO</code>) the initial value for the property is
  -        assigned to this field.  The type of this field will
  -        vary according to the <code>initialValueType</code>
  -        field.
  -      </dd>
  -      <dt>AUTO: <code>PropertyValueList auto(property,
  -        list)></code></dt>
  -      <dd>
  -        When <em>AUTO</em>  is a legal value type, the
  -        <code>auto()</code>  method must be defined in the property
  -        class.<br/>
  -        <em>NOT YET IMPLEMENTED.</em>
  -      </dd>
  -      <dt>COMPLEX: <code>PropertyValueList complex(property,
  -        list)></code></dt>
  -      <dd>
  -        <em>COMPLEX</em>  is specified as a value type when complex
  -        conditions apply to the selection of a value type, or
  -        when lists of values are acceptable.  To process and
  -        validate such a property value assignment, the
  -        <code>complex()</code>  method must be defined in the
  -        property class.
  -      </dd>
  -    </dl>
  -  </section>
  +              <strong><code>final int</code></strong>
  +              <em><code>enumeration-constants</code></em><br/> A
  +              unique integer constant is defined for each of the
  +              possible enumeration values.<br/> <br/>
  +            </dd>
  +            <dt>Many types:
  +              <code>final</code>  <em>datatype</em>
  +              <code>initialValue</code></dt>
  +            <dd>
  +              When the initial datatype does not have an implicit
  +              initial value (as, for example, does type
  +              <code>AUTO</code>) the initial value for the property is
  +              assigned to this field.  The type of this field will
  +              vary according to the <code>initialValueType</code>
  +              field.
  +            </dd>
  +            <dt>AUTO: <code>PropertyValueList auto(property,
  +                list)></code></dt>
  +            <dd>
  +              When <em>AUTO</em>  is a legal value type, the
  +              <code>auto()</code>  method must be defined in the property
  +              class.<br/>
  +              <em>NOT YET IMPLEMENTED.</em>
  +            </dd>
  +            <dt>COMPLEX: <code>PropertyValueList complex(property,
  +                list)></code></dt>
  +            <dd>
  +              <em>COMPLEX</em>  is specified as a value type when complex
  +              conditions apply to the selection of a value type, or
  +              when lists of values are acceptable.  To process and
  +              validate such a property value assignment, the
  +              <code>complex()</code>  method must be defined in the
  +              property class.
  +            </dd>
  +          </dl>
  +        </section>
         </section>
         <section>
           <title>Nested property pseudo-classes</title>
  -  <p>
  -    The property pseudo-classes are classes, like
  -    <code>ColorCommon</code>  which contain values, particularly
  -    <em>enums</em>, which are common to a number of actual
  -    properties.
  -  </p>
  +        <p>
  +          The property pseudo-classes are classes, like
  +          <code>ColorCommon</code>  which contain values, particularly
  +          <em>enums</em>, which are common to a number of actual
  +          properties.
  +        </p>
         </section>
         <p>
  -  <strong>Previous:</strong> <link href= "classes-overview.html"
  -  >property classes overview.</link>
  +        <strong>Previous:</strong> <link href= "classes-overview.html"
  +                                         >property classes overview.</link>
         </p>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  
  1.3       +155 -155  xml-fop/src/documentation/content/xdocs/design/alt.design/spaces.xml
  
  Index: spaces.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/design/alt.design/spaces.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- spaces.xml	2 Dec 2002 12:00:11 -0000	1.2
  +++ spaces.xml	18 Dec 2002 16:25:24 -0000	1.3
  @@ -3,177 +3,177 @@
       "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/resources/schema/dtd/document-v11.dtd">
   
   <document>
  -    <header>
  -        <title>Keeps and space-specifiers</title>
  +  <header>
  +    <title>Keeps and space-specifiers</title>
       <authors>
         <person name="Peter B. West" email="pbwest@powerup.com.au"/>
       </authors>
  -    </header>
  -    <body>
  +  </header>
  +  <body>
       <section>
         <title>Keeps and space-specifiers in layout galleys</title>
         <p> 
  -  The <link href= "galleys.html" >layout galleys</link> and the
  -  <link href= "galleys.html#layout-tree" >layout tree</link>
  -  which is the context of this discussion have been discussed 
  -  elsewhere.  A <link href="keeps.html">previous document</link>
  -  discussed data structures which might facilitate the lining of
  -  blocks necessary to implement keeps.  Here we discuss the
  -  similarities between the keep data structures and those
  -  required to implement space-specifier resolution.
  +        The <link href= "galleys.html" >layout galleys</link> and the
  +        <link href= "galleys.html#layout-tree" >layout tree</link>
  +        which is the context of this discussion have been discussed 
  +        elsewhere.  A <link href="keeps.html">previous document</link>
  +        discussed data structures which might facilitate the lining of
  +        blocks necessary to implement keeps.  Here we discuss the
  +        similarities between the keep data structures and those
  +        required to implement space-specifier resolution.
         </p>
         <section>
           <title>Space-specifiers</title>
  -  <note>
  -    <strong>4.3 Spaces and Conditionality</strong>
  -    ... Space-specifiers occurring in sequence may interact with
  -    each other. The constraint imposed by a sequence of
  -    space-specifiers is computed by calculating for each
  -    space-specifier its associated resolved space-specifier in
  -    accordance with their conditionality and precedence.
  -  </note>
  -  <note>
  -    4.2.5 Stacking Constraints ... The intention of the
  -    definitions is to identify areas at any level of the tree
  -    which have only space between them. 
  -  </note>
  -  <p>
  -    The quotations above are pivotal to understanding the
  -    complex discussion of spaces with which they are associated,
  -    all of which exists to enable the resolution of adjacent 
  -    &lt;space&gt;s.  It may be helpful to think of <em>stacking
  -    constraints</em> as <em>&lt;space&gt;s interaction</em> or
  -    <em>&lt;space&gt;s stacking interaction</em>.
  -  </p>
  +        <note>
  +          <strong>4.3 Spaces and Conditionality</strong>
  +          ... Space-specifiers occurring in sequence may interact with
  +          each other. The constraint imposed by a sequence of
  +          space-specifiers is computed by calculating for each
  +          space-specifier its associated resolved space-specifier in
  +          accordance with their conditionality and precedence.
  +        </note>
  +        <note>
  +          4.2.5 Stacking Constraints ... The intention of the
  +          definitions is to identify areas at any level of the tree
  +          which have only space between them. 
  +        </note>
  +        <p>
  +          The quotations above are pivotal to understanding the
  +          complex discussion of spaces with which they are associated,
  +          all of which exists to enable the resolution of adjacent 
  +          &lt;space&gt;s.  It may be helpful to think of <em>stacking
  +            constraints</em> as <em>&lt;space&gt;s interaction</em> or
  +          <em>&lt;space&gt;s stacking interaction</em>.
  +        </p>
         </section>
         <section>
           <title>Block stacking constraints</title>
  -  <p>
  -    In the discussion of block stacking constraints in Section
  -    4.2.5, the notion of <em>fence</em> is introduced.  For
  -    block stacking constraints, a fence is defined as either a
  -    reference-area boundary or a non-zero padding or border
  -    specification.  Fences, however, do not come into play 
  -    when determining the constraint between siblings.  (See
  -    <link href="#Figure1">Figure 1</link>.)
  -  </p>
  -  <p><strong>Figure 1</strong></p><anchor id="Figure1"/> 
  -  <figure src="images/design/alt.design/block-stacking-constraints.png" 
  -    alt="block-stacking-constraints.png"/>
  -  <note>
  -    Figure 1 assumes a block-progression-direction of top to
  -    bottom.
  -  </note>
  -  <p>
  -    In <link href="#Figure1">Diagram a)</link>, block A has
  -    non-zero padding and borders, in addition to non-zero
  -    spaces.  Note, however, that the space-after of A is
  -    adjacent to the space-before of block P, so borders and
  -    padding on these siblings have no impact on the interaction
  -    of their &lt;space&gt;s.  The stacking constraint A,P is
  -    indicated by the red rectangle enclosing the space-after of
  -    A and the space-before of P.
  -  </p>
  -  <p>
  -    In <link href="#Figure1">Diagram b)</link>, block B is the
  -    first block child of P.  The stacking constraint A,P is as
  -    before; the stacking constraint P,B is the space-before of
  -    B, as indicated by the enclosing magenta rectangle.  In this
  -    case, however, the non-zero border of P prevents the
  -    interaction of the A,P and P,B stacking constraints.  There
  -    is a <em>fence-before</em> P.  The fence is notional; it has
  -    no precise location, as the diagram may lead one to believe.
  -  </p>
  -  <p>
  -    In <link href="#Figure1">Diagram c)</link>, because of the
  -    zero-width borders and padding on block P, the fence-before
  -    P is not present, and the adjacent &lt;space&gt;s of blocks
  -    A, P and B are free to interact.  In this case, the stacking
  -    constraints A,P and P,B are as before, but now there is an
  -    additional stacking constraint A,B, represented by the light
  -    brown rectangle enclosing the other two stacking
  -    constraints.
  -  </p>
  -  <p>
  -    The other form of fence occurs when the parent block is a
  -    reference area.  Diagram b) of <link href="#Figure2">Figure
  -    2</link> illustrates this situation.  Block C is a
  -    reference-area, involving a 180 degree change of
  -    block-progression-direction (BPD).  In the diagram, the
  -    inner edge of block C represents the content rectangle, with
  -    its changed BPD.  The thicker outer edge represents the
  -    outer boundary of the padding, border and spaces of C.
  -  </p>
  -  <p>
  -    While not every reference-area will change the
  -    inline-progression-direction (IPD) and BPD of an area, no
  -    attempt is made to discriminate these cases.  A
  -    reference-area always a fence.  The fence comes into play in
  -    analogous circumstances to non-zero borders or padding.
  -    Space resolution between a reference area and its siblings
  -    is not affected.
  -  </p>
  -  <p>
  -    In the case of <link href="#Figure2">Diagram b)</link>,
  -    these are block stacking constraints B,C and C,A.  Within
  -    the reference-area, bock stacing constraints C,D and E,C are
  -    unaffected.  However, the fence prevents block stacking
  -    constraints such as B,E or D,A.  When there is a change of
  -    BPD, as <link href="#Figure2">Diagram b)</link> makes
  -    visually obvious, it is difficult to imagine which blocks
  -    would have such a constraint, and what the ordering of the
  -    constraint would be.
  -  </p>
  -  <p><strong>Figure 2</strong></p>
  -  <anchor id="Figure2"/>
  -  <figure src="images/design/alt.design/block-stacking-keeps.png"
  -    alt="block-stacking-keeps.png"/>
  +        <p>
  +          In the discussion of block stacking constraints in Section
  +          4.2.5, the notion of <em>fence</em> is introduced.  For
  +          block stacking constraints, a fence is defined as either a
  +          reference-area boundary or a non-zero padding or border
  +          specification.  Fences, however, do not come into play 
  +          when determining the constraint between siblings.  (See
  +          <link href="#Figure1">Figure 1</link>.)
  +        </p>
  +        <p><strong>Figure 1</strong></p><anchor id="Figure1"/> <figure
  +        src= "images/design/alt.design/block-stacking-constraints.png"
  +        alt= "block-stacking-constraints.png"/>
  +        <note>
  +          Figure 1 assumes a block-progression-direction of top to
  +          bottom.
  +        </note>
  +        <p>
  +          In <link href="#Figure1">Diagram a)</link>, block A has
  +          non-zero padding and borders, in addition to non-zero
  +          spaces.  Note, however, that the space-after of A is
  +          adjacent to the space-before of block P, so borders and
  +          padding on these siblings have no impact on the interaction
  +          of their &lt;space&gt;s.  The stacking constraint A,P is
  +          indicated by the red rectangle enclosing the space-after of
  +          A and the space-before of P.
  +        </p>
  +        <p>
  +          In <link href="#Figure1">Diagram b)</link>, block B is the
  +          first block child of P.  The stacking constraint A,P is as
  +          before; the stacking constraint P,B is the space-before of
  +          B, as indicated by the enclosing magenta rectangle.  In this
  +          case, however, the non-zero border of P prevents the
  +          interaction of the A,P and P,B stacking constraints.  There
  +          is a <em>fence-before</em> P.  The fence is notional; it has
  +          no precise location, as the diagram may lead one to believe.
  +        </p>
  +        <p>
  +          In <link href="#Figure1">Diagram c)</link>, because of the
  +          zero-width borders and padding on block P, the fence-before
  +          P is not present, and the adjacent &lt;space&gt;s of blocks
  +          A, P and B are free to interact.  In this case, the stacking
  +          constraints A,P and P,B are as before, but now there is an
  +          additional stacking constraint A,B, represented by the light
  +          brown rectangle enclosing the other two stacking
  +          constraints.
  +        </p>
  +        <p>
  +          The other form of fence occurs when the parent block is a
  +          reference area.  Diagram b) of <link href="#Figure2">Figure
  +            2</link> illustrates this situation.  Block C is a
  +          reference-area, involving a 180 degree change of
  +          block-progression-direction (BPD).  In the diagram, the
  +          inner edge of block C represents the content rectangle, with
  +          its changed BPD.  The thicker outer edge represents the
  +          outer boundary of the padding, border and spaces of C.
  +        </p>
  +        <p>
  +          While not every reference-area will change the
  +          inline-progression-direction (IPD) and BPD of an area, no
  +          attempt is made to discriminate these cases.  A
  +          reference-area always a fence.  The fence comes into play in
  +          analogous circumstances to non-zero borders or padding.
  +          Space resolution between a reference area and its siblings
  +          is not affected.
  +        </p>
  +        <p>
  +          In the case of <link href="#Figure2">Diagram b)</link>,
  +          these are block stacking constraints B,C and C,A.  Within
  +          the reference-area, bock stacing constraints C,D and E,C are
  +          unaffected.  However, the fence prevents block stacking
  +          constraints such as B,E or D,A.  When there is a change of
  +          BPD, as <link href="#Figure2">Diagram b)</link> makes
  +          visually obvious, it is difficult to imagine which blocks
  +          would have such a constraint, and what the ordering of the
  +          constraint would be.
  +        </p>
  +        <p><strong>Figure 2</strong></p>
  +        <anchor id="Figure2"/>
  +        <figure src= "images/design/alt.design/block-stacking-keeps.png"
  +                alt= "block-stacking-keeps.png"/>
         </section>
         <section>
           <title>Keep relationships between blocks</title>
  -  <p>
  -    As complicated as space-specifiers become when
  -    reference-areas are involved, the keep relationships as
  -    described in the <link
  -    href="keeps.html#Figure1">keeps</link> document, are
  -    unchanged.  This is also illustrated in <link
  -    href="#Figure2">Figure 2</link>.  Diagram b) shows the
  -    relative placement of blocks in the rendered output when a
  -    180 degree change of BPD occurs, with blocks D and E
  -    stacking in the reverse direction to blocks B and C.
  -    Diagram c) shows what happens when the page is too short to
  -    accommodate the last block.  D is still laid out, but E is
  -    deferred to the next page.
  -  </p>
  -  <p>
  -    Note that this rendering reality is expressed directly in
  -    the area (and layout) tree view.  Consequently, any keep
  -    relationships expressed as links threading through the
  -    layout tree will not need to be modified to account for
  -    reference-area boundaries, as is the case with similar
  -    space-specifier edge links.  E.g., a keep-with-next
  -    condition on block B can be resolved along the path of these
  -    links (B->C->D) into a direct relationship of B->D,
  -    irrespective of the reference-area boundary.
  -  </p>
  -  <p>
  -    While the same relationships obviously hold when a reference
  -    area induces no change of BPD, the situation for BPD changes
  -    perpendicular to the parent's BPD may not be so clear.  In
  -    general, it probably does not make much sense to impose keep
  -    conditions across such a boundary, but there seems to be
  -    nothing preventing such conditions.  They can be dealt with
  -    in the same way, i.e., the next leaf block linked in area
  -    tree order must be the next laid out.  If a keep condition
  -    is in place, an attempt must be made to meet it.  A number
  -    of unusual considerations would apply, e.g. the minimum
  -    inline-progression-dimension of the first leaf block within
  -    the reference-area as compared to the minimum IPD of
  -    subsequent blocks, but <em>prima facie</em>, the essential
  -    logic of the keeps links remains.
  -  </p>
  +        <p>
  +          As complicated as space-specifiers become when
  +          reference-areas are involved, the keep relationships as
  +          described in the <link
  +          href="keeps.html#Figure1">keeps</link> document, are
  +          unchanged.  This is also illustrated in <link
  +          href="#Figure2">Figure 2</link>.  Diagram b) shows the
  +          relative placement of blocks in the rendered output when a
  +          180 degree change of BPD occurs, with blocks D and E
  +          stacking in the reverse direction to blocks B and C.
  +          Diagram c) shows what happens when the page is too short to
  +          accommodate the last block.  D is still laid out, but E is
  +          deferred to the next page.
  +        </p>
  +        <p>
  +          Note that this rendering reality is expressed directly in
  +          the area (and layout) tree view.  Consequently, any keep
  +          relationships expressed as links threading through the
  +          layout tree will not need to be modified to account for
  +          reference-area boundaries, as is the case with similar
  +          space-specifier edge links.  E.g., a keep-with-next
  +          condition on block B can be resolved along the path of these
  +          links (B->C->D) into a direct relationship of B->D,
  +          irrespective of the reference-area boundary.
  +        </p>
  +        <p>
  +          While the same relationships obviously hold when a reference
  +          area induces no change of BPD, the situation for BPD changes
  +          perpendicular to the parent's BPD may not be so clear.  In
  +          general, it probably does not make much sense to impose keep
  +          conditions across such a boundary, but there seems to be
  +          nothing preventing such conditions.  They can be dealt with
  +          in the same way, i.e., the next leaf block linked in area
  +          tree order must be the next laid out.  If a keep condition
  +          is in place, an attempt must be made to meet it.  A number
  +          of unusual considerations would apply, e.g. the minimum
  +          inline-progression-dimension of the first leaf block within
  +          the reference-area as compared to the minimum IPD of
  +          subsequent blocks, but <em>prima facie</em>, the essential
  +          logic of the keeps links remains.
  +        </p>
         </section>
       </section>
  -    </body>
  +  </body>
   </document>
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-cvs-help@xml.apache.org