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 je...@apache.org on 2003/03/07 08:58:52 UTC

cvs commit: xml-fop/src/org/apache/fop/layoutmgr/list ListBlockLayoutManager.java ListItemLayoutManager.java Item.java

jeremias    2003/03/06 23:58:52

  Modified:    src/org/apache/fop/layoutmgr/table Column.java Body.java
                        Cell.java TableAndCaptionLayoutManager.java
                        Row.java Caption.java TableLayoutManager.java
               src/org/apache/fop/layoutmgr LayoutManager.java
                        PositionIterator.java SpaceSpecifier.java
                        HyphContext.java BreakPoss.java
                        BreakPossPosIter.java LayoutContext.java
                        MinOptMax.java LMiter.java LineLayoutManager.java
                        RetrieveMarkerLayoutManager.java
                        LeafNodeLayoutManager.java NonLeafPosition.java
                        LayoutProcessor.java AbstractLayoutManager.java
                        ContentLayoutManager.java PageLayoutManager.java
                        LeafPosition.java BlockStackingLayoutManager.java
                        BreakCost.java StaticContentLayoutManager.java
                        Position.java FlowLayoutManager.java
               src/org/apache/fop/layoutmgr/list
                        ListBlockLayoutManager.java
                        ListItemLayoutManager.java Item.java
  Log:
  Switched to long licence
  Some general checkstyle fixing
  
  Revision  Changes    Path
  1.5       +56 -9     xml-fop/src/org/apache/fop/layoutmgr/table/Column.java
  
  Index: Column.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/Column.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- Column.java	19 Feb 2003 05:49:29 -0000	1.4
  +++ Column.java	7 Mar 2003 07:58:51 -0000	1.5
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.fo.FObj;
  @@ -33,17 +76,21 @@
   
       /**
        * Create a new column layout manager.
  -     *
  -     * @param fobj the table-column formatting object
        */
       public Column() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutManager#setFObj(FObj)
  +     */
       public void setFObj(FObj fobj) {
           super.setFObj(fobj);
           columnWidth = ((TableColumn)fobj).getColumnWidth();
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
  @@ -103,7 +150,7 @@
       public Area createColumnArea() {
           Area curBlockArea = new Block();
   
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(curBlockArea, backgroundProps);
           }
           return curBlockArea;
  
  
  
  1.13      +50 -10    xml-fop/src/org/apache/fop/layoutmgr/table/Body.java
  
  Index: Body.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/Body.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- Body.java	4 Mar 2003 03:48:09 -0000	1.12
  +++ Body.java	7 Mar 2003 07:58:51 -0000	1.13
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -47,8 +90,6 @@
   
       /**
        * Create a new body layout manager.
  -     *
  -     * @param fobj the formatting object that created this manager
        */
       public Body() {
       }
  @@ -231,7 +272,6 @@
        * the areas return by the children.
        *
        * @param childArea the child area to add
  -     * @return unused
        */
       public void addChild(Area childArea) {
           parentLM.addChild(childArea);
  @@ -257,7 +297,7 @@
       public Area createColumnArea() {
           Area curBlockArea = new Block();
   
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(curBlockArea, backgroundProps);
           }
           return curBlockArea;
  
  
  
  1.13      +55 -10    xml-fop/src/org/apache/fop/layoutmgr/table/Cell.java
  
  Index: Cell.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/Cell.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- Cell.java	4 Mar 2003 03:48:09 -0000	1.12
  +++ Cell.java	7 Mar 2003 07:58:51 -0000	1.13
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -50,6 +93,9 @@
       public Cell() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
  @@ -74,7 +120,7 @@
           cellIPD = context.getRefIPD();
   
           while ((curLM = getChildLM()) != null) {
  -            if(curLM.generatesInlineAreas()) {
  +            if (curLM.generatesInlineAreas()) {
                   getLogger().error("table-cell must contain block areas - ignoring");
                   curLM.setFinished(true);
                   continue;
  @@ -188,10 +234,10 @@
               }
           }
   
  -        if(borderProps != null) {
  +        if (borderProps != null) {
               TraitSetter.addBorders(curBlockArea, borderProps);
           }
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(curBlockArea, backgroundProps);
           }
   
  @@ -240,7 +286,6 @@
        * Add the child to the cell block area.
        *
        * @param childArea the child to add to the cell
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.9       +49 -7     xml-fop/src/org/apache/fop/layoutmgr/table/TableAndCaptionLayoutManager.java
  
  Index: TableAndCaptionLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/TableAndCaptionLayoutManager.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- TableAndCaptionLayoutManager.java	4 Mar 2003 03:48:09 -0000	1.8
  +++ TableAndCaptionLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.9
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.layoutmgr.BlockStackingLayoutManager;
  @@ -178,7 +221,6 @@
        * Add the child to the current area.
        *
        * @param childArea the area to add
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.14      +50 -8     xml-fop/src/org/apache/fop/layoutmgr/table/Row.java
  
  Index: Row.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/Row.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- Row.java	4 Mar 2003 03:48:09 -0000	1.13
  +++ Row.java	7 Mar 2003 07:58:51 -0000	1.14
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -341,7 +384,6 @@
        * This simply adds the area to the parent layout manager.
        *
        * @param childArea the child area
  -     * @return unused
        */
       public void addChild(Area childArea) {
           parentLM.addChild(childArea);
  @@ -366,7 +408,7 @@
        */
       public Area getRowArea() {
           Area block = new Block();
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(block, backgroundProps);
           }
           return block;
  
  
  
  1.9       +49 -7     xml-fop/src/org/apache/fop/layoutmgr/table/Caption.java
  
  Index: Caption.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/Caption.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- Caption.java	4 Mar 2003 03:48:09 -0000	1.8
  +++ Caption.java	7 Mar 2003 07:58:51 -0000	1.9
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.layoutmgr.BlockStackingLayoutManager;
  @@ -177,7 +220,6 @@
        * Add the child to the caption area.
        *
        * @param childArea the child area to add
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.13      +54 -9     xml-fop/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java
  
  Index: TableLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/table/TableLayoutManager.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- TableLayoutManager.java	4 Mar 2003 03:48:09 -0000	1.12
  +++ TableLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.13
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.table;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -63,6 +106,9 @@
       public TableLayoutManager() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
  @@ -287,10 +333,10 @@
   
           curBlockArea.setHeight(tableHeight);
   
  -        if(borderProps != null) {
  +        if (borderProps != null) {
               TraitSetter.addBorders(curBlockArea, borderProps);
           }
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(curBlockArea, backgroundProps);
           }
   
  @@ -331,7 +377,6 @@
        * Add the child area to this layout manager.
        *
        * @param childArea the child area to add
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.18      +52 -9     xml-fop/src/org/apache/fop/layoutmgr/LayoutManager.java
  
  Index: LayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LayoutManager.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- LayoutManager.java	4 Mar 2003 03:48:08 -0000	1.17
  +++ LayoutManager.java	7 Mar 2003 07:58:51 -0000	1.18
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.FOUserAgent;
  @@ -22,7 +65,7 @@
        *
        * @param obj the FO object for this layout manager
        */
  -    public void setFObj(FObj obj);
  +    void setFObj(FObj obj);
   
       /**
        * Set the user agent. For resolving user agent values
  @@ -30,13 +73,13 @@
        *
        * @param ua the user agent
        */
  -    public void setUserAgent(FOUserAgent ua);
  +    void setUserAgent(FOUserAgent ua);
   
       /**
        * Get the user agent.
        *
        * @return the user agent
        */
  -    public FOUserAgent getUserAgent();
  +    FOUserAgent getUserAgent();
   
   }
  
  
  
  1.11      +54 -11    xml-fop/src/org/apache/fop/layoutmgr/PositionIterator.java
  
  Index: PositionIterator.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/PositionIterator.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- PositionIterator.java	4 Mar 2003 03:48:08 -0000	1.10
  +++ PositionIterator.java	7 Mar 2003 07:58:51 -0000	1.11
  @@ -1,21 +1,64 @@
   /*
    * $Id$
  - * Copyright (C) 2001 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
  -
   import java.util.Iterator;
   import java.util.NoSuchElementException;
   
   public abstract class PositionIterator implements Iterator {
  -    Iterator parentIter;
  -    Object nextObj;
  -    LayoutProcessor childLM;
  -    boolean bHasNext;
  +    
  +    private Iterator parentIter;
  +    private Object nextObj;
  +    private LayoutProcessor childLM;
  +    private boolean bHasNext;
   
       PositionIterator(Iterator pIter) {
           parentIter = pIter;
  
  
  
  1.11      +12 -3     xml-fop/src/org/apache/fop/layoutmgr/SpaceSpecifier.java
  
  Index: SpaceSpecifier.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/SpaceSpecifier.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- SpaceSpecifier.java	5 Mar 2003 20:38:26 -0000	1.10
  +++ SpaceSpecifier.java	7 Mar 2003 07:58:51 -0000	1.11
  @@ -67,10 +67,17 @@
       private List vecSpaceVals = new java.util.ArrayList();
   
   
  +    /**
  +     * Creates a new SpaceSpecifier.
  +     * @param bStarts true if it starts anew reference area
  +     */
       public SpaceSpecifier(boolean bStarts) {
           bStartsRefArea = bStarts;
       }
   
  +    /**
  +     * @see java.lang.Object#clone()
  +     */
       public Object clone() {
           try {
               SpaceSpecifier ss = (SpaceSpecifier) super.clone();
  @@ -92,8 +99,10 @@
           vecSpaceVals.clear();
       }
   
  -
  -    /** Return true if any space-specifiers have been added. */
  +    /**
  +     * Indicates whether any space-specifiers have been added.
  +     * @return true if any space-specifiers have been added.
  +     */
       public boolean hasSpaces() {
           return (vecSpaceVals.size() > 0);
       }
  
  
  
  1.3       +59 -16    xml-fop/src/org/apache/fop/layoutmgr/HyphContext.java
  
  Index: HyphContext.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/HyphContext.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- HyphContext.java	8 Aug 2002 15:08:08 -0000	1.2
  +++ HyphContext.java	7 Mar 2003 07:58:51 -0000	1.3
  @@ -1,12 +1,55 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
  -
   /**
    * This class is used to pass information to the getNextBreakPoss()
    * method concerning hyphenation. A reference to an instance of the
  @@ -16,26 +59,26 @@
    * processed by a Layout Manager to generate size information.
    */
   public class HyphContext {
  -    private int[] m_hyphPoints;
  -    private int m_iCurOffset = 0;
  -    private int m_iCurIndex = 0;
  +    private int[] hyphPoints;
  +    private int currentOffset = 0;
  +    private int currentIndex = 0;
   
       public HyphContext(int[] hyphPoints) {
  -        m_hyphPoints = hyphPoints;
  +        this.hyphPoints = hyphPoints;
       }
   
       public int getNextHyphPoint() {
  -        for (; m_iCurIndex < m_hyphPoints.length; m_iCurIndex++) {
  -            if (m_hyphPoints[m_iCurIndex] > m_iCurOffset) {
  -                return (m_hyphPoints[m_iCurIndex] - m_iCurOffset);
  +        for (; currentIndex < hyphPoints.length; currentIndex++) {
  +            if (hyphPoints[currentIndex] > currentOffset) {
  +                return (hyphPoints[currentIndex] - currentOffset);
               }
           }
           return -1; // AT END!
       }
   
       public boolean hasMoreHyphPoints() {
  -        for (; m_iCurIndex < m_hyphPoints.length; m_iCurIndex++) {
  -            if (m_hyphPoints[m_iCurIndex] > m_iCurOffset) {
  +        for (; currentIndex < hyphPoints.length; currentIndex++) {
  +            if (hyphPoints[currentIndex] > currentOffset) {
                   return true;
               }
           }
  @@ -43,6 +86,6 @@
       }
   
       public void updateOffset(int iCharsProcessed) {
  -        m_iCurOffset += iCharsProcessed;
  +        currentOffset += iCharsProcessed;
       }
   }
  
  
  
  1.13      +124 -70   xml-fop/src/org/apache/fop/layoutmgr/BreakPoss.java
  
  Index: BreakPoss.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/BreakPoss.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- BreakPoss.java	4 Mar 2003 03:48:08 -0000	1.12
  +++ BreakPoss.java	7 Mar 2003 07:58:51 -0000	1.13
  @@ -1,9 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.traits.LayoutProps;
  @@ -13,81 +57,86 @@
    * Used to pass information between different levels of layout manager concerning
    * the break positions. In an inline context, before and after are interpreted as
    * start and end.
  - * The m_position field is opaque represents where the break occurs. It is a
  + * The position field is opaque represents where the break occurs. It is a
    * nested structure with one level for each layout manager involved in generating
    * the BreakPoss..
    * @author Karen Lease
    */
   public class BreakPoss {
   
  -
  -    /** Values for m_flags returned from lower level LM. */
  -    public static final int CAN_BREAK_AFTER = 0x01; // May break after
  -    public static final int ISLAST = 0x02; // Last area generated by FO
  -    public static final int ISFIRST = 0x04; // First area generated by FO
  -    public static final int FORCE = 0x08; // Forced break (ie LF)
  -    public static final int CAN_BREAK_BEFORE = 0x10;
  -    public static final int HAS_ANCHORS = 0x40;
  -    // Set this flag if all fo:character generated Areas would
  -    // suppressed at the end or beginning of a line
  -    public static final int ALL_ARE_SUPPRESS_AT_LB = 0x80;
  +    // --- Values for flags returned from lower level LM. ---
  +    /** May break after */
  +    public static final int CAN_BREAK_AFTER         = 0x01;
  +    /** Last area generated by FO */
  +    public static final int ISLAST                  = 0x02;
  +    /** First area generated by FO */
  +    public static final int ISFIRST                 = 0x04;
  +    /** Forced break (ie LF) */
  +    public static final int FORCE                   = 0x08;
  +    /** May break before */
  +    public static final int CAN_BREAK_BEFORE        = 0x10;
  +    /** has anchors */
  +    public static final int HAS_ANCHORS             = 0x40;
  +    /** 
  +     * Set this flag if all fo:character generated Areas would
  +     * suppressed at the end or beginning of a line */
  +    public static final int ALL_ARE_SUPPRESS_AT_LB  = 0x80;
       /** This break possibility is a hyphenation */
  -    public static final int HYPHENATED = 0x100;
  -    /** If this break possibility ends the line, all remaining characters
  +    public static final int HYPHENATED              = 0x100;
  +    /** 
  +     * If this break possibility ends the line, all remaining characters
        * in the lowest level text LM will be suppressed.
        */
       public static final int REST_ARE_SUPPRESS_AT_LB = 0x200;
  -    /**
  -     * Next area for LM overflows
  -     */
  -    public static final int NEXT_OVERFLOWS = 0x400;
  +    /** Next area for LM overflows */
  +    public static final int NEXT_OVERFLOWS          = 0x400;
   
       /** The opaque position object used by m_lm to record its
        *  break position.
        */
  -    private Position m_position;
  +    private Position position;
   
       /**
        * The size range in the stacking direction of the area which would be
        * generated if this BreakPoss were used.
        */
  -    private MinOptMax m_stackSize;
  +    private MinOptMax stackSize;
   
       /**
        * Max height above and below the baseline. These are cumulative.
        */
  -    private int m_iLead;
  +    private int lead;
       // the max height of before and after alignment
  -    private int m_iTotal;
  +    private int total;
       // middle alignment height for after
  -    private int m_iMiddle;
  +    private int middle;
   
       /** Size in the non-stacking direction (perpendicular). */
  -    private MinOptMax m_nonStackSize;
  +    private MinOptMax nonStackSize;
   
  -    private long m_flags = 0;
  -    private LayoutProps m_layoutProps = new LayoutProps();
  +    private long flags = 0;
  +    private LayoutProps layoutProps = new LayoutProps();
   
       /** Store space-after (or end) and space-before (or start) to be
        * added if this break position is used.
        */
  -    private SpaceSpecifier m_spaceSpecTrailing;
  -    private SpaceSpecifier m_spaceSpecLeading;
  +    private SpaceSpecifier spaceSpecTrailing;
  +    private SpaceSpecifier spaceSpecLeading;
   
       public BreakPoss(Position position) {
           this(position, 0);
       }
   
       public BreakPoss(Position position, long flags) {
  -        m_position = position;
  -        m_flags = flags;
  +        this.position = position;
  +        this.flags = flags;
       }
   
       /**
        * The top-level layout manager responsible for this break
        */
       public LayoutProcessor getLayoutManager() {
  -        return m_position.getLM();
  +        return position.getLM();
       }
   
       //     public void setLayoutManager(LayoutManager lm) {
  @@ -98,31 +147,31 @@
        * An object representing the break position in this layout manager.
        */
       public Position getPosition() {
  -        return m_position;
  +        return position;
       }
   
       public void setPosition(Position pos) {
  -        m_position = pos;
  +        position = pos;
       }
   
       public void setStackingSize(MinOptMax size) {
  -        this.m_stackSize = size;
  +        this.stackSize = size;
       }
   
       public MinOptMax getStackingSize() {
  -        return this.m_stackSize ;
  +        return this.stackSize ;
       }
   
       public void setNonStackingSize(MinOptMax size) {
  -        this.m_nonStackSize = size;
  +        this.nonStackSize = size;
       }
   
       public MinOptMax getNonStackingSize() {
  -        return this.m_nonStackSize ;
  +        return this.nonStackSize ;
       }
   
       public long getFlags() {
  -        return m_flags;
  +        return flags;
       }
   
       public void setFlag(int flagBit) {
  @@ -131,109 +180,114 @@
   
       public void setFlag(int flagBit, boolean bSet) {
           if (bSet) {
  -            m_flags |= flagBit;
  +            flags |= flagBit;
           } else {
  -            m_flags &= ~flagBit;
  +            flags &= ~flagBit;
           }
       }
   
       public boolean isLastArea() {
  -        return ((m_flags & ISLAST) != 0);
  +        return ((flags & ISLAST) != 0);
       }
   
       public boolean isFirstArea() {
  -        return ((m_flags & ISFIRST) != 0);
  +        return ((flags & ISFIRST) != 0);
       }
   
       public boolean canBreakAfter() {
  -        return ((m_flags & CAN_BREAK_AFTER) != 0);
  +        return ((flags & CAN_BREAK_AFTER) != 0);
       }
   
       public boolean canBreakBefore() {
  -        return ((m_flags & CAN_BREAK_BEFORE) != 0);
  +        return ((flags & CAN_BREAK_BEFORE) != 0);
       }
   
       public boolean couldEndLine() {
  -        return ((m_flags & REST_ARE_SUPPRESS_AT_LB) != 0);
  +        return ((flags & REST_ARE_SUPPRESS_AT_LB) != 0);
       }
   
       public boolean isForcedBreak() {
  -        return ((m_flags & FORCE) != 0);
  +        return ((flags & FORCE) != 0);
       }
   
       public boolean nextBreakOverflows() {
  -        return ((m_flags & NEXT_OVERFLOWS) != 0);
  +        return ((flags & NEXT_OVERFLOWS) != 0);
       }
   
       public boolean isSuppressible() {
  -        return ((m_flags & ALL_ARE_SUPPRESS_AT_LB) != 0);
  +        return ((flags & ALL_ARE_SUPPRESS_AT_LB) != 0);
       }
   
       public SpaceSpecifier getLeadingSpace() {
  -        return m_spaceSpecLeading;
  +        return spaceSpecLeading;
       }
   
       public MinOptMax resolveLeadingSpace() {
  -        if (m_spaceSpecLeading != null) {
  -            return m_spaceSpecLeading.resolve(false);
  -        } else
  +        if (spaceSpecLeading != null) {
  +            return spaceSpecLeading.resolve(false);
  +        } else {
               return new MinOptMax(0);
  +        }
       }
   
       public SpaceSpecifier getTrailingSpace() {
  -        return m_spaceSpecTrailing;
  +        return spaceSpecTrailing;
       }
   
       public MinOptMax resolveTrailingSpace(boolean bEndsRefArea) {
  -        if (m_spaceSpecTrailing != null) {
  -            return m_spaceSpecTrailing.resolve(bEndsRefArea);
  -        } else
  +        if (spaceSpecTrailing != null) {
  +            return spaceSpecTrailing.resolve(bEndsRefArea);
  +        } else {
               return new MinOptMax(0);
  +        }
       }
   
   
       public void setLeadingSpace(SpaceSpecifier spaceSpecLeading) {
  -        m_spaceSpecLeading = spaceSpecLeading;
  +        this.spaceSpecLeading = spaceSpecLeading;
       }
   
       public void setTrailingSpace(SpaceSpecifier spaceSpecTrailing) {
  -        m_spaceSpecTrailing = spaceSpecTrailing;
  +        this.spaceSpecTrailing = spaceSpecTrailing;
       }
   
       public LayoutProps getLayoutProps() {
  -        return m_layoutProps;
  +        return layoutProps;
       }
   
       public int getLead() {
  -        return m_iLead;
  +        return lead;
       }
   
       public int getTotal() {
  -        return m_iTotal;
  +        return total;
       }
   
       public int getMiddle() {
  -        return m_iMiddle;
  +        return middle;
       }
   
       /**
        * set lead height of baseline positioned element
  +     * @param ld new lead value
        */
       public void setLead(int ld) {
  -        m_iLead = ld;
  +        lead = ld;
       }
   
       /**
        * Set total height of top or bottom aligned element
  +     * @param t new total height
        */
       public void setTotal(int t) {
  -        m_iTotal = t;
  +        total = t;
       }
   
       /**
        * Set distance below baseline of middle aligned element
  +     * @param t new value
        */
       public void setMiddle(int t) {
  -        m_iMiddle = t;
  +        middle = t;
       }
   }
  
  
  
  1.10      +70 -12    xml-fop/src/org/apache/fop/layoutmgr/BreakPossPosIter.java
  
  Index: BreakPossPosIter.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/BreakPossPosIter.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- BreakPossPosIter.java	4 Mar 2003 03:48:08 -0000	1.9
  +++ BreakPossPosIter.java	7 Mar 2003 07:58:51 -0000	1.10
  @@ -1,27 +1,82 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
  -
   import java.util.List;
   
  +/**
  + * Position iterator for break possibilities.
  + */
   public class BreakPossPosIter extends PositionIterator {
  -    private int m_iterCount ;
   
  +    private int iterCount;
  +
  +    /**
  +     * Main constructor
  +     * @param bpList List of break possibilities
  +     * @param startPos starting position
  +     * @param endPos ending position
  +     */
       public BreakPossPosIter(List bpList, int startPos, int endPos) {
           super(bpList.listIterator(startPos));
  -        m_iterCount = endPos - startPos;
  +        iterCount = endPos - startPos;
       }
   
       // Check position < endPos
  -
  +    
  +    /**
  +     * @see org.apache.fop.layoutmgr.PositionIterator#checkNext()
  +     */
       protected boolean checkNext() {
  -        if (m_iterCount > 0) {
  +        if (iterCount > 0) {
               return super.checkNext();
           } else {
               endIter();
  @@ -29,8 +84,11 @@
           }
       }
   
  +    /**
  +     * @see java.util.Iterator#next()
  +     */
       public Object next() {
  -        --m_iterCount;
  +        --iterCount;
           return super.next();
       }
   
  
  
  
  1.12      +49 -5     xml-fop/src/org/apache/fop/layoutmgr/LayoutContext.java
  
  Index: LayoutContext.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LayoutContext.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- LayoutContext.java	13 Feb 2003 04:24:17 -0000	1.11
  +++ LayoutContext.java	7 Mar 2003 07:58:51 -0000	1.12
  @@ -1,9 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   
  
  
  
  1.3       +78 -6     xml-fop/src/org/apache/fop/layoutmgr/MinOptMax.java
  
  Index: MinOptMax.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/MinOptMax.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- MinOptMax.java	19 Feb 2003 05:49:28 -0000	1.2
  +++ MinOptMax.java	7 Mar 2003 07:58:51 -0000	1.3
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   /**
  @@ -49,6 +92,9 @@
           this.max = max;
       }
   
  +    /**
  +     * @see java.lang.Object#clone()
  +     */
       public Object clone() {
           try {
               return super.clone();
  @@ -58,27 +104,53 @@
           }
       }
   
  +    /**
  +     * Subtracts one MinOptMax instance from another returning a new one.
  +     * @param op1 first instance to subtract from
  +     * @param op2 second instance
  +     * @return MinOptMax new instance
  +     */
       public static MinOptMax subtract(MinOptMax op1, MinOptMax op2) {
           return new MinOptMax(op1.min - op2.max, op1.opt - op2.opt,
                                op1.max - op2.min);
       }
   
  +    /**
  +     * Adds one MinOptMax instance to another returning a new one.
  +     * @param op1 first instance
  +     * @param op2 second instance
  +     * @return MinOptMax new instance
  +     */
       public static MinOptMax add(MinOptMax op1, MinOptMax op2) {
           return new MinOptMax(op1.min + op2.min, op1.opt + op2.opt,
                                op1.max + op2.max);
       }
   
  +    /**
  +     * Multiplies a MinOptMax instance with a factor returning a new instance.
  +     * @param op1 MinOptMax instance
  +     * @param mult multiplier
  +     * @return MinOptMax new instance
  +     */
       public static MinOptMax multiply(MinOptMax op1, double mult) {
           return new MinOptMax((int)(op1.min * mult),
                                (int)(op1.opt * mult), (int)(op1.max * mult));
       }
   
  +    /**
  +     * Adds another MinOptMax instance to this one.
  +     * @param op the other instance
  +     */
       public void add(MinOptMax op) {
           min += op.min;
           opt += op.opt;
           max += op.max;
       }
   
  +    /**
  +     * Subtracts from this instance using another.
  +     * @param op the other instance
  +     */
       public void subtract(MinOptMax op) {
           min -= op.max;
           opt -= op.opt;
  
  
  
  1.8       +57 -12    xml-fop/src/org/apache/fop/layoutmgr/LMiter.java
  
  Index: LMiter.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LMiter.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- LMiter.java	15 Nov 2002 11:56:29 -0000	1.7
  +++ LMiter.java	7 Mar 2003 07:58:51 -0000	1.8
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.FObj;
  @@ -35,11 +78,11 @@
           // skip over child FObj's that don't add lms
           while (baseIter != null && baseIter.hasNext()) {
               Object theobj = baseIter.next();
  -            if(theobj instanceof FObj) {
  +            if (theobj instanceof FObj) {
                   FObj fobj = (FObj) theobj;
                   //listLMs.add(fobj.getLayoutManager());
                   fobj.addLayoutManager(listLMs);
  -                if(curPos < listLMs.size()) {
  +                if (curPos < listLMs.size()) {
                       return true;
                   }
               }
  @@ -54,24 +97,26 @@
       public Object previous() throws NoSuchElementException {
           if (curPos > 0) {
               return listLMs.get(--curPos);
  -        } else
  +        } else {
               throw new NoSuchElementException();
  +        }
       }
   
       public Object next() throws NoSuchElementException {
           if (curPos < listLMs.size()) {
               return listLMs.get(curPos++);
  -        } else
  +        } else {
               throw new NoSuchElementException();
  +        }
       }
   
       public void remove() throws NoSuchElementException {
           if (curPos > 0) {
               listLMs.remove(--curPos);
               // Note: doesn't actually remove it from the base!
  -        } else
  +        } else {
               throw new NoSuchElementException();
  -
  +        }
       }
   
   
  
  
  
  1.24      +87 -46    xml-fop/src/org/apache/fop/layoutmgr/LineLayoutManager.java
  
  Index: LineLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LineLayoutManager.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -r1.23 -r1.24
  --- LineLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.23
  +++ LineLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.24
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -75,15 +118,13 @@
       private int follow;
   
       // inline start pos when adding areas
  -    int iStartPos = 0;
  +    private int iStartPos = 0;
   
       /**
        * Create a new Line Layout Manager.
        * This is used by the block layout manager to create
        * line managers for handling inline areas flowing into line areas.
        *
  -     * @param fobj the block the is creating the lines
  -     * @param lms the list of layout managers that will add inline areas
        * @param lh the default line height
        * @param l the default lead, from top to baseline
        * @param f the default follow, from baseline to bottom
  @@ -98,6 +139,7 @@
       /**
        * Initialize the properties for this layout manager.
        * The properties are from the block area.
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
        */
       protected void initProperties(PropertyManager propMgr) {
           MarginProps marginProps = propMgr.getMarginProps();
  @@ -141,13 +183,14 @@
           while ((curLM = getChildLM()) != null) {
               // INITIALIZE LAYOUT CONTEXT FOR CALL TO CHILD LM
               // First break for the child LM in each of its areas
  -            boolean bFirstBPforLM = (vecInlineBreaks.isEmpty() ||
  -                                     (((BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1)).
  +            boolean bFirstBPforLM = (vecInlineBreaks.isEmpty()
  +                    || (((BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1)).
                                         getLayoutManager() != curLM));
   
               // Need previous breakpoint! ATTENTION when backing up for hyphenation!
  -            prev = (vecInlineBreaks.isEmpty()) ? null :
  -                     (BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1);
  +            prev = (vecInlineBreaks.isEmpty()) 
  +                    ? null
  +                    : (BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1);
               initChildLC(inlineLC, prev,
                           (vecInlineBreaks.size() == iPrevLineEnd),
                           bFirstBPforLM, new SpaceSpecifier(true));
  @@ -158,10 +201,10 @@
                * then set the SUPPRESS_LEADING_SPACE flag.
                */
               inlineLC.setFlags(LayoutContext.SUPPRESS_LEADING_SPACE,
  -                              (vecInlineBreaks.size() == iPrevLineEnd &&
  -                               !vecInlineBreaks.isEmpty() &&
  -                               ((BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1)).
  -                               isForcedBreak() == false));
  +                              (vecInlineBreaks.size() == iPrevLineEnd
  +                               && !vecInlineBreaks.isEmpty()
  +                               && ((BreakPoss) vecInlineBreaks.get(vecInlineBreaks.size() - 1)).
  +                                    isForcedBreak() == false));
   
               // GET NEXT POSSIBLE BREAK FROM CHILD LM
               // prevBP = bp;
  @@ -209,17 +252,17 @@
   
                           inlineLC.setHyphContext(
                             getHyphenContext(prevBP, bp));
  -                        if (inlineLC.getHyphContext() == null)
  +                        if (inlineLC.getHyphContext() == null) {
                               break;
  +                        }
                           inlineLC.setFlags(LayoutContext.TRY_HYPHENATE,
                                             true);
                           // Reset to previous acceptable break
                           reset();
  -                    }
  -                    /* If we are not in justified text, we can end the line at
  -                     * prevBP.
  -                     */
  -                    else {
  +                    } else {
  +                        /* If we are not in justified text, we can end the line at
  +                         * prevBP.
  +                         */
                           break;
                       }
                   } else {
  @@ -240,23 +283,23 @@
                                * (ie, bpDim.opt closes to availIPD.opt), keeps
                                * and hyphenation.
                                */
  -                            vecPossEnd.add( new BreakCost(bp,
  -                                                          Math.abs(availIPD.opt - bpDim.opt)));
  +                            vecPossEnd.add(new BreakCost(bp,
  +                                    Math.abs(availIPD.opt - bpDim.opt)));
                           }
                           // Otherwise it's short
                       } else {
                           /* Can't end line here. */
                       }
                   } // end of bpDim.min <= availIPD.max
  -            } // end of getNextBreakPoss!=null on current child LM
  -            else {
  +            // end of getNextBreakPoss!=null on current child LM   
  +            } else {
                   /* The child LM can return a null BreakPoss if it has
                    * nothing (more) to layout. This can happen when backing
                    * up. Just try the next child LM.
                    */
               }
  -            if (inlineLC.tryHyphenate() &&
  -                    !inlineLC.getHyphContext().hasMoreHyphPoints()) {
  +            if (inlineLC.tryHyphenate()
  +                    && !inlineLC.getHyphContext().hasMoreHyphPoints()) {
                   break;
               }
           } // end of while on child LM
  @@ -265,10 +308,12 @@
               setFinished(true);
           }
   
  -        if (bp == null)
  +        if (bp == null) {
               return null;
  -        if (prevBP == null)
  +        }
  +        if (prevBP == null) {
               prevBP = bp;
  +        }
   
           // Choose the best break
           if (!bp.isForcedBreak() && vecPossEnd.size() > 0) {
  @@ -289,7 +334,6 @@
           return makeLineBreak(iPrevLineEnd, availIPD, talign);
       }
   
  -
       private void reset() {
           while (vecInlineBreaks.get(vecInlineBreaks.size() - 1) != prevBP) {
               vecInlineBreaks.remove(vecInlineBreaks.size() - 1);
  @@ -350,7 +394,7 @@
   
           vecInlineBreaks.add(newBP);
           ListIterator bpIter =
  -          vecInlineBreaks. listIterator(vecInlineBreaks.size());
  +            vecInlineBreaks.listIterator(vecInlineBreaks.size());
           while (bpIter.hasPrevious() && bpIter.previous() != prev) {
           }
           if (bpIter.next() != prev) {
  @@ -430,8 +474,8 @@
           MinOptMax actual = new MinOptMax();
           BreakPoss lastBP = null;
           LayoutManager lastLM = null;
  -        for(Iterator iter = vecInlineBreaks.listIterator(prevLineEnd);
  -                iter.hasNext(); ) {
  +        for (Iterator iter = vecInlineBreaks.listIterator(prevLineEnd);
  +                iter.hasNext();) {
               BreakPoss bp = (BreakPoss)iter.next();
               if (bp.getLead() > lineLead) {
                   lineLead = bp.getLead();
  @@ -474,20 +518,18 @@
           int targetWith = target.opt;
           int realWidth = actual.opt;
           if (actual.opt > targetWith) {
  -            if (actual.opt - targetWith <
  -                    (actual.opt - actual.min)) {
  -                ipdAdjust = -(actual.opt - targetWith) /
  -                                (float)(actual.opt - actual.min);
  +            if (actual.opt - targetWith < (actual.opt - actual.min)) {
  +                ipdAdjust = -(actual.opt - targetWith)
  +                                / (float)(actual.opt - actual.min);
                   realWidth = targetWith;
               } else {
                   ipdAdjust = -1;
                   realWidth = actual.max;
               }
           } else {
  -            if (targetWith - actual.opt <
  -                    actual.max - actual.opt) {
  -                ipdAdjust = (targetWith - actual.opt) /
  -                                (float)(actual.max - actual.opt);
  +            if (targetWith - actual.opt < actual.max - actual.opt) {
  +                ipdAdjust = (targetWith - actual.opt)
  +                                / (float)(actual.max - actual.opt);
                   realWidth = targetWith;
               } else {
                   ipdAdjust = 1;
  @@ -541,8 +583,7 @@
               prevBP = null;
           } else {
               prevBP = (BreakPoss)vecInlineBreaks.get(((LineBreakPosition)resetPos).getLeafPos());
  -            while (vecInlineBreaks.get(vecInlineBreaks.size() - 1) != prevBP)
  -{
  +            while (vecInlineBreaks.get(vecInlineBreaks.size() - 1) != prevBP) {
                   vecInlineBreaks.remove(vecInlineBreaks.size() - 1);
               }
               reset(prevBP.getPosition());
  @@ -599,7 +640,7 @@
                   lc.setTrailingSpace(new SpaceSpecifier(false));
               }
               // when can this be null?
  -            if(lc.getTrailingSpace() != null) {
  +            if (lc.getTrailingSpace() != null) {
                   addSpace(lineArea, lc.getTrailingSpace().resolve(true),
                            lc.getSpaceAdjust());
               }
  
  
  
  1.4       +52 -6     xml-fop/src/org/apache/fop/layoutmgr/RetrieveMarkerLayoutManager.java
  
  Index: RetrieveMarkerLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/RetrieveMarkerLayoutManager.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- RetrieveMarkerLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.3
  +++ RetrieveMarkerLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.4
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import java.util.ArrayList;
  @@ -113,6 +156,9 @@
           parentLM.addChild(childArea);
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#resetPosition(Position)
  +     */
       public void resetPosition(Position resetPos) {
           loadLM();
           if (resetPos == null) {
  
  
  
  1.23      +49 -8     xml-fop/src/org/apache/fop/layoutmgr/LeafNodeLayoutManager.java
  
  Index: LeafNodeLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LeafNodeLayoutManager.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- LeafNodeLayoutManager.java	19 Feb 2003 05:49:28 -0000	1.22
  +++ LeafNodeLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.23
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.area.Area;
  @@ -29,7 +72,6 @@
   
       /**
        * Create a Leaf node layout mananger.
  -     * @param fobj the fo object that created this manager
        */
       public LeafNodeLayoutManager() {
       }
  @@ -91,7 +133,6 @@
       /**
        * This is a leaf-node, so this method is never called.
        * @param childArea the childArea to add
  -     * @return not used
        */
       public void addChild(Area childArea) {
       }
  
  
  
  1.6       +49 -6     xml-fop/src/org/apache/fop/layoutmgr/NonLeafPosition.java
  
  Index: NonLeafPosition.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/NonLeafPosition.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- NonLeafPosition.java	4 Mar 2003 03:48:08 -0000	1.5
  +++ NonLeafPosition.java	7 Mar 2003 07:58:51 -0000	1.6
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   public class NonLeafPosition extends Position {
  
  
  
  1.2       +67 -24    xml-fop/src/org/apache/fop/layoutmgr/LayoutProcessor.java
  
  Index: LayoutProcessor.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LayoutProcessor.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LayoutProcessor.java	4 Mar 2003 03:48:08 -0000	1.1
  +++ LayoutProcessor.java	7 Mar 2003 07:58:51 -0000	1.2
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.flow.Marker;
  @@ -28,12 +71,12 @@
        *
        * @param lm the parent layout manager
        */
  -    public void setParent(LayoutProcessor lm);
  +    void setParent(LayoutProcessor lm);
   
       /**
        * Initialise this layout manager.
        */
  -    public void init();
  +    void init();
   
       /**
        * Generates inline areas.
  @@ -42,7 +85,7 @@
        *
        * @return true if the layout manager generates inline areas
        */
  -    public boolean generatesInlineAreas();
  +    boolean generatesInlineAreas();
   
       /**
        * Return true if the next area which would be generated by this
  @@ -51,7 +94,7 @@
        * @param lc the layout context
        * @return true if can break before
        */
  -    public boolean canBreakBefore(LayoutContext lc);
  +    boolean canBreakBefore(LayoutContext lc);
   
       /**
        * Generate and return the next break possibility.
  @@ -62,14 +105,14 @@
        * information.
        * @return the next break position
        */
  -    public BreakPoss getNextBreakPoss(LayoutContext context);
  +    BreakPoss getNextBreakPoss(LayoutContext context);
   
       /**
        * Reset to the position.
        *
        * @param position
        */
  -    public void resetPosition(Position position);
  +    void resetPosition(Position position);
   
       /**
        * Get the word chars between two positions and
  @@ -80,7 +123,7 @@
        * @param bp1 the start position
        * @param bp2 the end position
        */
  -    public void getWordChars(StringBuffer sbChars, Position bp1,
  +    void getWordChars(StringBuffer sbChars, Position bp1,
                                Position bp2);
   
       /**
  @@ -89,7 +132,7 @@
        *
        * @return true if this layout manager is finished
        */
  -    public boolean isFinished();
  +    boolean isFinished();
   
       /**
        * Set a flag indicating whether the LayoutManager has laid out all
  @@ -98,7 +141,7 @@
        *
        * @param isFinished the value to set the finished flag to
        */
  -    public void setFinished(boolean isFinished);
  +    void setFinished(boolean isFinished);
   
       /**
        * Get the parent area for an area.
  @@ -108,7 +151,7 @@
        * @param childArea the child area to get the parent for
        * @return the parent Area 
        */
  -    public Area getParentArea(Area childArea);
  +    Area getParentArea(Area childArea);
   
       /**
        * Add the area as a child of the current area.
  @@ -117,7 +160,7 @@
        *
        * @param childArea the child area to add
        */
  -    public void addChild(Area childArea);
  +    void addChild(Area childArea);
   
       /**
        * Tell the layout manager to add all the child areas implied
  @@ -127,14 +170,14 @@
        * @param posIter the position iterator
        * @param context the context
        */
  -    public void addAreas(PositionIterator posIter, LayoutContext context);
  +    void addAreas(PositionIterator posIter, LayoutContext context);
   
       /**
        * Get the string of the current page number.
        *
        * @return the string for the current page number
        */
  -    public String getCurrentPageNumber();
  +    String getCurrentPageNumber();
   
       /**
        * Resolve the id reference.
  @@ -144,7 +187,7 @@
        * @param ref the id reference
        * @return the page containing the id reference or null if not found
        */
  -    public PageViewport resolveRefID(String ref);
  +    PageViewport resolveRefID(String ref);
   
       /**
        * Add an id to the page.
  @@ -152,7 +195,7 @@
        *
        * @param id the id reference to add.
        */
  -    public void addIDToPage(String id);
  +    void addIDToPage(String id);
   
       /**
        * Add an unresolved area.
  @@ -161,7 +204,7 @@
        * @param id the id reference this object needs for resolving
        * @param res the resolveable object
        */
  -    public void addUnresolvedArea(String id, Resolveable res);
  +    void addUnresolvedArea(String id, Resolveable res);
   
       /**
        * Add the marker.
  @@ -172,7 +215,7 @@
        * @param start true if the formatting object is starting false is finishing
        * @param isfirst a flag for is first
        */
  -    public void addMarkerMap(Map marks, boolean start, boolean isfirst);
  +    void addMarkerMap(Map marks, boolean start, boolean isfirst);
   
       /**
        * Retrieve a marker.
  @@ -183,7 +226,7 @@
        * @param boundary the boundary for retrieving the marker
        * @return the layout manaager of the retrieved marker if any
        */
  -    public Marker retrieveMarker(String name, int pos, int boundary);
  +    Marker retrieveMarker(String name, int pos, int boundary);
   
   }
   
  
  
  
  1.24      +53 -10    xml-fop/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java
  
  Index: AbstractLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/AbstractLayoutManager.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -r1.23 -r1.24
  --- AbstractLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.23
  +++ AbstractLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.24
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.FObj;
  @@ -166,8 +209,8 @@
           LayoutManager lm = (pos != null) ? pos.getLM() : null;
           if (curChildLM != lm) {
               // ASSERT curChildLM == (LayoutManager)childLMiter.previous()
  -            if (childLMiter.hasPrevious() && curChildLM !=
  -                    (LayoutManager) childLMiter.previous()) {
  +            if (childLMiter.hasPrevious() && curChildLM
  +                    != (LayoutManager) childLMiter.previous()) {
                   //log.error("LMiter problem!");
               }
               while (curChildLM != lm && childLMiter.hasPrevious()) {
  @@ -177,7 +220,7 @@
               // Otherwise next returns same object
               childLMiter.next();
           }
  -        if(curChildLM != null) {
  +        if (curChildLM != null) {
               curChildLM.resetPosition(pos);
           }
           if (isFinished()) {
  @@ -299,7 +342,7 @@
        * If the id string is not null then add the id to the current page.
        */
       protected void addID() {
  -        if(foID != null) {
  +        if (foID != null) {
               addIDToPage(foID);
           }
       }
  
  
  
  1.17      +57 -6     xml-fop/src/org/apache/fop/layoutmgr/ContentLayoutManager.java
  
  Index: ContentLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/ContentLayoutManager.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- ContentLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.16
  +++ ContentLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.17
  @@ -1,9 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.FObj;
  @@ -89,7 +133,7 @@
                       middlefollow = bp.getMiddle();
                   }
               }
  -            if(lastSize != null) {
  +            if (lastSize != null) {
                   stack.add(lastSize);
               }
           }
  @@ -143,10 +187,17 @@
           userAgent = ua;
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutManager#getUserAgent()
  +     */
       public FOUserAgent getUserAgent() {
           return userAgent;
       }
   
  +    /**
  +     * Returns the logger
  +     * @return the logger
  +     */
       protected Logger getLogger() {
           return userAgent.getLogger();
       }
  
  
  
  1.33      +51 -8     xml-fop/src/org/apache/fop/layoutmgr/PageLayoutManager.java
  
  Index: PageLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/PageLayoutManager.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -r1.32 -r1.33
  --- PageLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.32
  +++ PageLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.33
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.apps.FOPException;
  @@ -535,8 +578,8 @@
        */
       protected void handleBreak(int breakVal) {
           if (breakVal == Constants.COLUMN) {
  -            if (curSpan != null &&
  -                    curSpan.getColumnCount() != curSpanColumns) {
  +            if (curSpan != null
  +                    && curSpan.getColumnCount() != curSpanColumns) {
                   // Move to next column
                   createFlow();
                   return;
  
  
  
  1.6       +49 -6     xml-fop/src/org/apache/fop/layoutmgr/LeafPosition.java
  
  Index: LeafPosition.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/LeafPosition.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- LeafPosition.java	4 Mar 2003 03:48:08 -0000	1.5
  +++ LeafPosition.java	7 Mar 2003 07:58:51 -0000	1.6
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   public class LeafPosition extends Position {
  
  
  
  1.18      +51 -8     xml-fop/src/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java
  
  Index: BlockStackingLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- BlockStackingLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.17
  +++ BlockStackingLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.18
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.area.Area;
  @@ -63,12 +106,12 @@
        */
       public void addBlockSpacing(double adjust, MinOptMax minoptmax) {
           int sp = minoptmax.opt;
  -        if(adjust > 0) {
  +        if (adjust > 0) {
               sp = sp + (int)(adjust * (minoptmax.max - minoptmax.opt));
           } else {
               sp = sp + (int)(adjust * (minoptmax.opt - minoptmax.min));
           }
  -        if(sp != 0) {
  +        if (sp != 0) {
               Block spacer = new Block();
               spacer.setHeight(sp);
               parentLM.addChild(spacer);
  
  
  
  1.4       +49 -6     xml-fop/src/org/apache/fop/layoutmgr/BreakCost.java
  
  Index: BreakCost.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/BreakCost.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- BreakCost.java	13 May 2002 06:12:42 -0000	1.3
  +++ BreakCost.java	7 Mar 2003 07:58:51 -0000	1.4
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.area.Area;
  
  
  
  1.13      +65 -10    xml-fop/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java
  
  Index: StaticContentLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/StaticContentLayoutManager.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- StaticContentLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.12
  +++ StaticContentLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.13
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.area.RegionReference;
  @@ -26,13 +69,17 @@
       private RegionReference region;
       private List blockBreaks = new ArrayList();
   
  -    public StaticContentLayoutManager() {
  -    }
  -
  +    /**
  +     * Sets the region reference
  +     * @param region region reference
  +     */
       public void setRegionReference(RegionReference region) {
           this.region = region;
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#getNextBreakPoss(LayoutContext)
  +     */
       public BreakPoss getNextBreakPoss(LayoutContext context) {
   
           // currently active LM
  @@ -47,7 +94,8 @@
                   if ((bp = curLM.getNextBreakPoss(childLC)) != null) {
                       blockBreaks.add(bp);
                       if (bp.isForcedBreak()) {
  -                        getLogger().error("Forced breaks are not allowed in static content - ignoring");
  +                        getLogger().error("Forced breaks are not allowed in "
  +                                + "static content - ignoring");
                           return null;
                       }
                   }
  @@ -61,6 +109,9 @@
           return null;
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#addAreas(PositionIterator, LayoutContext)
  +     */
       public void addAreas(PositionIterator parentIter, LayoutContext layoutContext) {
   
           LayoutProcessor childLM;
  @@ -88,11 +139,15 @@
        * Add child area to a the correct container, depending on its
        * area class. A Flow can fill at most one area container of any class
        * at any one time. The actual work is done by BlockStackingLM.
  +     * @param childArea child area to add
        */
       public void addChild(Area childArea) {
           region.addBlock((Block)childArea);
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#getParentArea(Area)
  +     */
       public Area getParentArea(Area childArea) {
           return region;
       }
  
  
  
  1.6       +50 -6     xml-fop/src/org/apache/fop/layoutmgr/Position.java
  
  Index: Position.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/Position.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Position.java	4 Mar 2003 03:48:08 -0000	1.5
  +++ Position.java	7 Mar 2003 07:58:51 -0000	1.6
  @@ -1,13 +1,57 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   public class Position {
  +    
       private LayoutProcessor layoutManager;
   
       public Position(LayoutProcessor lm) {
  
  
  
  1.21      +64 -7     xml-fop/src/org/apache/fop/layoutmgr/FlowLayoutManager.java
  
  Index: FlowLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/FlowLayoutManager.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -r1.20 -r1.21
  --- FlowLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.20
  +++ FlowLayoutManager.java	7 Mar 2003 07:58:51 -0000	1.21
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002-2003 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr;
   
   import org.apache.fop.fo.flow.Marker;
  @@ -22,12 +65,13 @@
    */
   public class FlowLayoutManager extends BlockStackingLayoutManager {
   
  +    /** List of break possibilities */
       protected List blockBreaks = new ArrayList();
   
       /** Array of areas currently being filled stored by area class */
       private BlockParent[] currentAreas = new BlockParent[Area.CLASS_MAX];
   
  -    int iStartPos = 0;
  +    private int iStartPos = 0;
   
       /**
        * This is the top level layout manager.
  @@ -36,6 +80,9 @@
       public FlowLayoutManager() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#getNextBreakPoss(LayoutContext)
  +     */
       public BreakPoss getNextBreakPoss(LayoutContext context) {
   
           // currently active LM
  @@ -91,6 +138,9 @@
           return null;
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#addAreas(PositionIterator, LayoutContext)
  +     */
       public void addAreas(PositionIterator parentIter, LayoutContext layoutContext) {
   
           LayoutProcessor childLM;
  @@ -114,12 +164,16 @@
        * Add child area to a the correct container, depending on its
        * area class. A Flow can fill at most one area container of any class
        * at any one time. The actual work is done by BlockStackingLM.
  +     * @param childArea child area to add
        */
       public void addChild(Area childArea) {
           addChildToArea(childArea,
                             this.currentAreas[childArea.getAreaClass()]);
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#getParentArea(Area)
  +     */
       public Area getParentArea(Area childArea) {
           // Get an area from the Page
           BlockParent parentArea =
  @@ -129,6 +183,9 @@
           return parentArea;
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.LayoutProcessor#resetPosition(Position)
  +     */
       public void resetPosition(Position resetPos) {
           if (resetPos == null) {
               reset(null);
  
  
  
  1.11      +54 -9     xml-fop/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java
  
  Index: ListBlockLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/list/ListBlockLayoutManager.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- ListBlockLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.10
  +++ ListBlockLayoutManager.java	7 Mar 2003 07:58:52 -0000	1.11
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.list;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -54,6 +97,9 @@
       public ListBlockLayoutManager() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
  @@ -161,10 +207,10 @@
               }
           }
   
  -        if(borderProps != null) {
  +        if (borderProps != null) {
               TraitSetter.addBorders(curBlockArea, borderProps);
           }
  -        if(backgroundProps != null) {
  +        if (backgroundProps != null) {
               TraitSetter.addBackground(curBlockArea, backgroundProps);
           }
   
  @@ -205,7 +251,6 @@
        * Add the child area to this layout manager.
        *
        * @param childArea the child area to add
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.12      +62 -9     xml-fop/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java
  
  Index: ListItemLayoutManager.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/list/ListItemLayoutManager.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- ListItemLayoutManager.java	4 Mar 2003 03:48:08 -0000	1.11
  +++ ListItemLayoutManager.java	7 Mar 2003 07:58:52 -0000	1.12
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.list;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -56,16 +99,27 @@
       public ListItemLayoutManager() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
       }
   
  +    /**
  +     * Sets the label of the list item
  +     * @param item the label item
  +     */
       public void setLabel(Item item) {
           label = item;
           label.setParent(this);
       }
   
  +    /**
  +     * Sets the body of the list item
  +     * @param item the body item
  +     */
       public void setBody(Item item) {
           body = item;
           body.setParent(this);
  @@ -94,7 +148,7 @@
           int stage = 0;
           boolean over = false;
           while (true) {
  -            if(stage == 0) {
  +            if (stage == 0) {
                   curLM = label;
               } else if (stage == 1) {
                   curLM = body;
  @@ -205,7 +259,7 @@
                   breakPosIter = new BreakPossPosIter(cellsbr, 0, cellsbr.size());
   
                   while ((childLM = (Item)breakPosIter.getNextChildLM()) != null) {
  -                    if(childLM == body) {
  +                    if (childLM == body) {
                           childLM.setXOffset(24000);
                       }
                       childLM.addAreas(breakPosIter, lc);
  @@ -264,7 +318,6 @@
        * This simply adds the area to the parent layout manager.
        *
        * @param childArea the child area
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  
  1.11      +52 -8     xml-fop/src/org/apache/fop/layoutmgr/list/Item.java
  
  Index: Item.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layoutmgr/list/Item.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- Item.java	4 Mar 2003 03:48:08 -0000	1.10
  +++ Item.java	7 Mar 2003 07:58:52 -0000	1.11
  @@ -1,10 +1,53 @@
   /*
    * $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  - * For details on use and redistribution please refer to the
  - * LICENSE file included with these sources.
  - */
  -
  + * ============================================================================
  + *                    The Apache Software License, Version 1.1
  + * ============================================================================
  + * 
  + * Copyright (C) 1999-2003 The Apache Software Foundation. All rights reserved.
  + * 
  + * Redistribution and use in source and binary forms, with or without modifica-
  + * tion, are permitted provided that the following conditions are met:
  + * 
  + * 1. Redistributions of source code must retain the above copyright notice,
  + *    this list of conditions and the following disclaimer.
  + * 
  + * 2. Redistributions in binary form must reproduce the above copyright notice,
  + *    this list of conditions and the following disclaimer in the documentation
  + *    and/or other materials provided with the distribution.
  + * 
  + * 3. The end-user documentation included with the redistribution, if any, must
  + *    include the following acknowledgment: "This product includes software
  + *    developed by the Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself, if
  + *    and wherever such third-party acknowledgments normally appear.
  + * 
  + * 4. The names "FOP" and "Apache Software Foundation" must not be used to
  + *    endorse or promote products derived from this software without prior
  + *    written permission. For written permission, please contact
  + *    apache@apache.org.
  + * 
  + * 5. Products derived from this software may not be called "Apache", nor may
  + *    "Apache" appear in their name, without prior written permission of the
  + *    Apache Software Foundation.
  + * 
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
  + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
  + * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  + * ============================================================================
  + * 
  + * This software consists of voluntary contributions made by many individuals
  + * on behalf of the Apache Software Foundation and was originally created by
  + * James Tauber <jt...@jtauber.com>. For more information on the Apache
  + * Software Foundation, please see <http://www.apache.org/>.
  + */ 
   package org.apache.fop.layoutmgr.list;
   
   import org.apache.fop.fo.PropertyManager;
  @@ -44,11 +87,13 @@
   
       /**
        * Create a new Cell layout manager.
  -     * @param fobj the formatting object for the cell
        */
       public Item() {
       }
   
  +    /**
  +     * @see org.apache.fop.layoutmgr.AbstractLayoutManager#initProperties(PropertyManager)
  +     */
       protected void initProperties(PropertyManager propMgr) {
           borderProps = propMgr.getBorderAndPadding();
           backgroundProps = propMgr.getBackgroundProps();
  @@ -217,7 +262,6 @@
        * Add the child to the list item area.
        *
        * @param childArea the child to add to the cell
  -     * @return unused
        */
       public void addChild(Area childArea) {
           if (curBlockArea != null) {
  
  
  

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