cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2003-03-02 Thread pietsch
pietsch 2003/03/02 08:55:19

  Modified:.Tag: fop-0_20_2-maintain CHANGES
   src/org/apache/fop/layout Tag: fop-0_20_2-maintain
FontState.java LineArea.java
   src/org/apache/fop/layout/inline Tag: fop-0_20_2-maintain
InlineArea.java PageNumberInlineArea.java
WordArea.java
   src/org/apache/fop/render Tag: fop-0_20_2-maintain
AbstractRenderer.java PrintRenderer.java
Renderer.java
   src/org/apache/fop/render/awt Tag: fop-0_20_2-maintain
AWTRenderer.java
   src/org/apache/fop/render/pcl Tag: fop-0_20_2-maintain
PCLRenderer.java
   src/org/apache/fop/render/pdf Tag: fop-0_20_2-maintain
PDFRenderer.java
   src/org/apache/fop/render/ps Tag: fop-0_20_2-maintain
PSRenderer.java
   src/org/apache/fop/render/svg Tag: fop-0_20_2-maintain
SVGRenderer.java
   src/org/apache/fop/render/txt Tag: fop-0_20_2-maintain
TXTRenderer.java
   src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Do text align before the line is rendered, not when the line is closed.
  Moved page number resolving to just before text align. Removed page
  number resolving from renderers.
  Also, fix leader expansion in case page number resolving has eaten up
  too much space for the page number, resolving in a possible area overflow.
  Leaders may now be shortened down to leader-length.minimum if necessary.
  PR: 1130, 17194
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.10.2.52 +2 -0  xml-fop/CHANGES
  
  Index: CHANGES
  ===
  RCS file: /home/cvs/xml-fop/CHANGES,v
  retrieving revision 1.10.2.51
  retrieving revision 1.10.2.52
  diff -u -r1.10.2.51 -r1.10.2.52
  --- CHANGES   2 Mar 2003 13:06:23 -   1.10.2.51
  +++ CHANGES   2 Mar 2003 16:55:15 -   1.10.2.52
  @@ -1,5 +1,7 @@
   ==
   Done since 0.20.4 release
  +- Fixed text alingment for lines containing forward pointing page number
  +  citations. This should greatly improve TOC layout. (J.Pietschmann)
   - Fixed repeatedly laid out small caps text (for example in static
 content or due ot keeps). (J.Pietschmann)
   - Fixed marker handling thouroughly. All retrieving boundaries and
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.14.2.8  +111 -7xml-fop/src/org/apache/fop/layout/FontState.java
  
  Index: FontState.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layout/FontState.java,v
  retrieving revision 1.14.2.7
  retrieving revision 1.14.2.8
  diff -u -r1.14.2.7 -r1.14.2.8
  --- FontState.java25 Feb 2003 14:07:03 -  1.14.2.7
  +++ FontState.java2 Mar 2003 16:55:15 -   1.14.2.8
  @@ -215,14 +215,118 @@
   }
   
   // Use default CodePointMapping
  -char d = CodePointMapping.getMapping(WinAnsiEncoding).mapChar(c);
  -if (d != 0) {
  -c = d;
  -} else {
  -c = '#';
  +char d = CodePointMapping.getMapping(WinAnsiEncoding).mapChar(c);
  +if (d != 0) {
  +c = d;
  +} else {
  +c = '#';
  +}
  +return c;
   }
   
  -return c;
  +private int enWidth=-1;
  +private int emWidth=-1;
  +
  +private final int getEmWidth() {
  +if (emWidth0) {
  +char mappedChar = mapChar('m');
  +// The mapping returns '#' for unmapped characters in
  +// standard fonts.  What happens for other fonts?
  +if (mappedChar == '#') {
  +emWidth = 500 * getFontSize();
  +} else {
  +emWidth = width(mappedChar);
  +}
  +}
  +return emWidth;
  +}
  +
  +private final int getEnWidth() {
  +if (enWidth0) {
  +char mappedChar = mapChar('n');
  +// The mapping returns '#' for unmapped characters in
  +// standard fonts.  What happens for other fonts?
  +if (mappedChar != '#') {
  +// Should do something to discover non-proportional fonts.
  +enWidth = (getEmWidth()*9)/10;
  +} else {
  +enWidth = width(mappedChar);
  +}
  +}
  +return enWidth;
  +}
  +
  +/**
  + * Helper method for getting the width of a unicode char
  + * from the current fontstate.
  + * This also performs some guessing on 

cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2003-02-25 Thread jeremias
jeremias2003/02/25 06:58:50

  Modified:src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Switched to long licence
  Cleanup of tab characters where necessary
  Cleanup of unused imports where necessary
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.27.2.11 +50 -9 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.27.2.10
  retrieving revision 1.27.2.11
  diff -u -r1.27.2.10 -r1.27.2.11
  --- XMLRenderer.java  17 Feb 2003 00:09:43 -  1.27.2.10
  +++ XMLRenderer.java  25 Feb 2003 14:58:50 -  1.27.2.11
  @@ -1,21 +1,62 @@
   /*
* $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
  + *[EMAIL PROTECTED]
  + * 
  + * 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 [EMAIL PROTECTED]. For more information on the Apache
  + * Software Foundation, please see http://www.apache.org/.
  + */ 
   package org.apache.fop.render.xml;
   
   // FOP
   import org.apache.fop.svg.*;
   import org.apache.fop.render.Renderer;
  -import org.apache.fop.render.AbstractRenderer;
   import org.apache.fop.image.FopImage;
   import org.apache.fop.image.ImageArea;
   import org.apache.fop.layout.*;
   import org.apache.fop.layout.inline.*;
  -import org.apache.fop.pdf.*;
   import org.apache.fop.fo.properties.LeaderPattern;
   import org.apache.fop.apps.FOPException;
   
  @@ -462,7 +503,7 @@
   end.render(this);
   }
   if (body != null) {
  - body.render(this);
  +body.render(this);
   }
   writeEndTag(/Page);
   }
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2003-02-13 Thread jeremias
jeremias2003/02/13 07:59:20

  Modified:src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Page body wasn't rendered to XML. Why did nobody find out before?
  Submitted by: Diwan, Shridhar [EMAIL PROTECTED]
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.27.2.9  +13 -6 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.27.2.8
  retrieving revision 1.27.2.9
  diff -u -r1.27.2.8 -r1.27.2.9
  --- XMLRenderer.java  28 Nov 2002 16:06:39 -  1.27.2.8
  +++ XMLRenderer.java  13 Feb 2003 15:59:20 -  1.27.2.9
  @@ -1,6 +1,6 @@
   /*
* $Id$
  - * Copyright (C) 2001-2002 The Apache Software Foundation. All rights reserved.
  + * 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.
*/
  @@ -449,14 +449,21 @@
   after = page.getAfter();
   start = page.getStart();
   end = page.getEnd();
  -if (before != null)
  +if (before != null) {
   before.render(this);
  -if (after != null)
  +}
  +if (after != null) {
   after.render(this);
  -if (start != null)
  +}
  +if (start != null) {
   start.render(this);
  -if (end != null)
  +}
  +if (end != null) {
   end.render(this);
  +}
  +if (body != null) {
  + body.render(this);
  +}
   writeEndTag(/Page);
   }
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2002-11-28 Thread jeremias
jeremias2002/11/28 08:06:39

  Modified:src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Avoid NPE when options aren't set on the XMLRenderer (Bug 14768)
  Submitted by: Matthias Brunner [EMAIL PROTECTED]
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.27.2.8  +10 -2 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.27.2.7
  retrieving revision 1.27.2.8
  diff -u -r1.27.2.7 -r1.27.2.8
  --- XMLRenderer.java  8 Nov 2002 10:25:29 -   1.27.2.7
  +++ XMLRenderer.java  28 Nov 2002 16:06:39 -  1.27.2.8
  @@ -495,7 +495,15 @@
   }
   
   private boolean isCoarseXml() {
  -return ((Boolean)options.get(fineDetail)).booleanValue();
  +if (options == null) {
  +return false;
  +}
  +Boolean b = (Boolean)options.get(fineDetail);
  +if (b != null) {
  +return b.booleanValue();
  +} else {
  +return false;
  +}
   }
   
   /**
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2002-07-16 Thread pietsch

pietsch 2002/07/16 12:13:26

  Modified:src/org/apache/fop/fo/pagination Tag: fop-0_20_2-maintain
RegionAfter.java RegionBefore.java RegionEnd.java
RegionStart.java SimplePageMaster.java
   src/org/apache/fop/layout Tag: fop-0_20_2-maintain
AreaContainer.java RegionArea.java
   src/org/apache/fop/render Tag: fop-0_20_2-maintain
AbstractRenderer.java Renderer.java
   src/org/apache/fop/render/awt Tag: fop-0_20_2-maintain
AWTRenderer.java
   src/org/apache/fop/render/mif Tag: fop-0_20_2-maintain
MIFRenderer.java
   src/org/apache/fop/render/pcl Tag: fop-0_20_2-maintain
PCLRenderer.java
   src/org/apache/fop/render/pdf Tag: fop-0_20_2-maintain
PDFRenderer.java
   src/org/apache/fop/render/ps Tag: fop-0_20_2-maintain
PSRenderer.java
   src/org/apache/fop/render/svg Tag: fop-0_20_2-maintain
SVGRenderer.java
   src/org/apache/fop/render/txt Tag: fop-0_20_2-maintain
TXTRenderer.java
   src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Implementes background properties for all regions and precedence
  of regions (lr-tb writing mode only)
  Submitted by: Oleg Tkachenko [EMAIL PROTECTED]
  Reviewed by:  J.Pietschmann
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.9.2.2   +18 -1 xml-fop/src/org/apache/fop/fo/pagination/RegionAfter.java
  
  Index: RegionAfter.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/pagination/RegionAfter.java,v
  retrieving revision 1.9.2.1
  retrieving revision 1.9.2.2
  diff -u -r1.9.2.1 -r1.9.2.2
  --- RegionAfter.java  23 Apr 2002 22:25:25 -  1.9.2.1
  +++ RegionAfter.java  16 Jul 2002 19:13:23 -  1.9.2.2
  @@ -65,6 +65,20 @@
return area;
   }
   
  +RegionArea makeRegionArea(int allocationRectangleXPosition,
  +  int allocationRectangleYPosition,
  +  int allocationRectangleWidth,
  +  int allocationRectangleHeight,
  +  int startExtent, int endExtent) {
  +if (getPrecedence() == false) {
  +allocationRectangleXPosition += startExtent;
  +allocationRectangleWidth -= startExtent + endExtent;
  +}
  +return makeRegionArea(allocationRectangleXPosition,
  +  allocationRectangleYPosition,
  +  allocationRectangleWidth,
  +  allocationRectangleHeight);
  +}
   
   protected String getDefaultRegionName() {
   return xsl-region-after;
  @@ -82,4 +96,7 @@
   return (precedence == Precedence.TRUE ? true : false);
   }
   
  +public int getExtent() {
  +return properties.get(extent).getLength().mvalue();
  +}
   }
  
  
  
  1.9.2.2   +18 -1 xml-fop/src/org/apache/fop/fo/pagination/RegionBefore.java
  
  Index: RegionBefore.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/pagination/RegionBefore.java,v
  retrieving revision 1.9.2.1
  retrieving revision 1.9.2.2
  diff -u -r1.9.2.1 -r1.9.2.2
  --- RegionBefore.java 23 Apr 2002 22:25:25 -  1.9.2.1
  +++ RegionBefore.java 16 Jul 2002 19:13:23 -  1.9.2.2
  @@ -65,6 +65,20 @@
return area;
   }
   
  +RegionArea makeRegionArea(int allocationRectangleXPosition,
  +  int allocationRectangleYPosition,
  +  int allocationRectangleWidth,
  +  int allocationRectangleHeight,
  +  int startExtent, int endExtent) {
  +if (getPrecedence() == false) {
  +allocationRectangleXPosition += startExtent;
  +allocationRectangleWidth -= startExtent + endExtent;
  +}
  +return makeRegionArea(allocationRectangleXPosition,
  +  allocationRectangleYPosition,
  +  allocationRectangleWidth,
  +  allocationRectangleHeight);
  +}
   
   protected String getDefaultRegionName() {
   return xsl-region-before;
  @@ -82,4 +96,7 @@
   return (precedence == Precedence.TRUE ? true : false);
   }
   
  +public int getExtent() {
  +return properties.get(extent).getLength().mvalue();
  +}
   }
  
  
  
  1.3.2.2   +9 -6  xml-fop/src/org/apache/fop/fo/pagination/RegionEnd.java
  
  Index: 

cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2002-07-15 Thread pietsch

pietsch 2002/07/15 12:28:08

  Modified:src/org/apache/fop/render Tag: fop-0_20_2-maintain
Renderer.java
   src/org/apache/fop/render/awt Tag: fop-0_20_2-maintain
AWTRenderer.java
   src/org/apache/fop/render/mif Tag: fop-0_20_2-maintain
MIFRenderer.java
   src/org/apache/fop/render/pcl Tag: fop-0_20_2-maintain
PCLRenderer.java
   src/org/apache/fop/render/pdf Tag: fop-0_20_2-maintain
PDFRenderer.java
   src/org/apache/fop/render/ps Tag: fop-0_20_2-maintain
PSRenderer.java
   src/org/apache/fop/render/svg Tag: fop-0_20_2-maintain
SVGRenderer.java
   src/org/apache/fop/render/txt Tag: fop-0_20_2-maintain
TXTRenderer.java
   src/org/apache/fop/render/xml Tag: fop-0_20_2-maintain
XMLRenderer.java
  Log:
  Replaced options Hashtable by HashMap
  Reproted by: Oleg Tkachenko
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.19.2.3  +2 -2  xml-fop/src/org/apache/fop/render/Renderer.java
  
  Index: Renderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/Renderer.java,v
  retrieving revision 1.19.2.2
  retrieving revision 1.19.2.3
  diff -u -r1.19.2.2 -r1.19.2.3
  --- Renderer.java 11 Jun 2002 00:01:14 -  1.19.2.2
  +++ Renderer.java 15 Jul 2002 19:28:06 -  1.19.2.3
  @@ -41,7 +41,7 @@
   /**
* set up renderer options
*/
  -public void setOptions(java.util.Hashtable options);
  +public void setOptions(java.util.HashMap options);
   
   /**
* set the producer of the rendering
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.38.2.5  +3 -3  xml-fop/src/org/apache/fop/render/awt/AWTRenderer.java
  
  Index: AWTRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/awt/AWTRenderer.java,v
  retrieving revision 1.38.2.4
  retrieving revision 1.38.2.5
  diff -u -r1.38.2.4 -r1.38.2.5
  --- AWTRenderer.java  11 Jun 2002 00:01:14 -  1.38.2.4
  +++ AWTRenderer.java  15 Jul 2002 19:28:07 -  1.38.2.5
  @@ -115,12 +115,12 @@
   /**
* options
*/
  -protected Hashtable options;
  +protected java.util.HashMap options;
   
   /**
* set up renderer options
*/
  -public void setOptions(Hashtable options) {
  +public void setOptions(java.util.HashMap options) {
   this.options = options;
   }
   
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.11.2.2  +3 -3  xml-fop/src/org/apache/fop/render/mif/Attic/MIFRenderer.java
  
  Index: MIFRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/mif/Attic/MIFRenderer.java,v
  retrieving revision 1.11.2.1
  retrieving revision 1.11.2.2
  diff -u -r1.11.2.1 -r1.11.2.2
  --- MIFRenderer.java  23 Apr 2002 22:33:39 -  1.11.2.1
  +++ MIFRenderer.java  15 Jul 2002 19:28:07 -  1.11.2.2
  @@ -80,7 +80,7 @@
   /**
* options
*/
  -protected Hashtable options;
  +protected java.util.HashMap options;
   
   /**
* create the MIF renderer
  @@ -92,7 +92,7 @@
   /**
* set up renderer options
*/
  -public void setOptions(Hashtable options) {
  +public void setOptions(java.util.HashMap options) {
   this.options = options;
   }
   
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.13.2.2  +3 -3  xml-fop/src/org/apache/fop/render/pcl/PCLRenderer.java
  
  Index: PCLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/pcl/PCLRenderer.java,v
  retrieving revision 1.13.2.1
  retrieving revision 1.13.2.2
  diff -u -r1.13.2.1 -r1.13.2.2
  --- PCLRenderer.java  23 Apr 2002 22:33:39 -  1.13.2.1
  +++ PCLRenderer.java  15 Jul 2002 19:28:07 -  1.13.2.2
  @@ -58,7 +58,7 @@
   private int xoffset =
   -180;   // X Offset to allow for PCL implicit 1/4 left 
margin.
   
  -private java.util.Hashtable options;
  +private java.util.HashMap options;
   
   /**
* Create the PCL renderer
  @@ -68,7 +68,7 @@
   /**
* set up renderer options
*/
  -public void setOptions(java.util.Hashtable options) {
  +public void setOptions(java.util.HashMap options) {
   this.options = options;
   }
   
  
  
  
  No   revision
  
  
  No 

cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2002-02-08 Thread keiron

keiron  02/02/08 00:25:08

  Modified:src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  renders word are to xml
  
  Revision  ChangesPath
  1.33  +11 -1 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -r1.32 -r1.33
  --- XMLRenderer.java  9 Nov 2001 22:15:45 -   1.32
  +++ XMLRenderer.java  8 Feb 2002 08:25:08 -   1.33
  @@ -1,5 +1,5 @@
   /*
  - * $Id: XMLRenderer.java,v 1.32 2001/11/09 22:15:45 klease Exp $
  + * $Id: XMLRenderer.java,v 1.33 2002/02/08 08:25:08 keiron Exp $
* 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.
  @@ -336,6 +336,16 @@
   
   public void renderInlineSpace(Space space) {
   writeElement(space width=\ + space.getWidth() + \/);
  +}
  +
  +public void renderWord(Word word) {
  +String prop = ;
  +List list = word.getPropertyList();
  +if (list != null) {
  +prop =  props=\ + getPropString(list) + \;
  +}
  +writeElement(word + prop +  + word.getWord() + /word);
  +super.renderWord(word);
   }
   
   public void renderLeader(Leader area) {
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-11-09 Thread klease

klease  01/11/09 14:15:45

  Modified:src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  Rename Region to RegionReference in package area
  
  Revision  ChangesPath
  1.32  +7 -7  xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- XMLRenderer.java  2001/11/09 11:32:42 1.31
  +++ XMLRenderer.java  2001/11/09 22:15:45 1.32
  @@ -1,5 +1,5 @@
   /*
  - * $Id: XMLRenderer.java,v 1.31 2001/11/09 11:32:42 keiron Exp $
  + * $Id: XMLRenderer.java,v 1.32 2001/11/09 22:15:45 klease Exp $
* 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.
  @@ -212,24 +212,24 @@
   if (port != null) {
   writeStartTag(regionViewport rect=\ +
 createString(port.getViewArea()) + \);
  -Region region = port.getRegion();
  -if (region.getRegionClass() == Region.BEFORE) {
  +RegionReference region = port.getRegion();
  +if (region.getRegionClass() == RegionReference.BEFORE) {
   writeStartTag(regionBefore);
   renderRegion(region);
   writeEndTag(/regionBefore);
  -} else if (region.getRegionClass() == Region.START) {
  +} else if (region.getRegionClass() == RegionReference.START) {
   writeStartTag(regionStart);
   renderRegion(region);
   writeEndTag(/regionStart);
  -} else if (region.getRegionClass() == Region.BODY) {
  +} else if (region.getRegionClass() == RegionReference.BODY) {
   writeStartTag(regionBody);
   renderBodyRegion((BodyRegion) region);
   writeEndTag(/regionBody);
  -} else if (region.getRegionClass() == Region.END) {
  +} else if (region.getRegionClass() == RegionReference.END) {
   writeStartTag(regionEnd);
   renderRegion(region);
   writeEndTag(/regionEnd);
  -} else if (region.getRegionClass() == Region.AFTER) {
  +} else if (region.getRegionClass() == RegionReference.AFTER) {
   writeStartTag(regionAfter);
   renderRegion(region);
   writeEndTag(/regionAfter);
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




FW: cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-09-17 Thread Art Welch

Keiron,

I wonder if NULLing _source, _stream, and _reader in Driver.reset() is such
a good idea. For my own use with the PCLRenderer I take advantage of the
stream staying open to concatenate multiple invocations into one output. I
suppose that the desired things could be saved off before calling reset
(since thankfully you do not call close() or anything) and then put them
back after. But this seems like a bit of a nuisance. But maybe I am the only
one that does this. I know that for most of the other renderers it is not
currently possible to concatenate multiple invocations in FOP. Just a
though.

Art

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 9:30 AM
To: [EMAIL PROTECTED]
Subject: cvs commit: xml-fop/src/org/apache/fop/render/xml
XMLRenderer.java


keiron  01/09/17 06:29:53

  Modified:src/org/apache/fop/apps AWTStarter.java
CommandLineOptions.java Driver.java
   src/org/apache/fop/render AbstractRenderer.java
PrintRenderer.java
   src/org/apache/fop/render/awt AWTRenderer.java
   src/org/apache/fop/render/mif MIFRenderer.java
   src/org/apache/fop/render/ps PSRenderer.java
   src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  fixed a few awt render problems and a bit more render refactoring
  
...
  
  Index: Driver.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/apps/Driver.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- Driver.java   2001/08/22 08:29:17 1.34
  +++ Driver.java   2001/09/17 13:29:52 1.35
  @@ -1,5 +1,5 @@
   /*
  - * $Id: Driver.java,v 1.34 2001/08/22 08:29:17 keiron Exp $
  + * $Id: Driver.java,v 1.35 2001/09/17 13:29:52 keiron Exp $
* 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.
  @@ -230,6 +230,9 @@
*/
   public synchronized void reset() {
   _areaTree = null;
  +_source = null;
  +_stream = null;
  +_reader = null;
   _treeBuilder.reset();
   }
   

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-07-26 Thread arved

arved   01/07/26 17:18:27

  Modified:src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  AHS: changed signatures
  
  Revision  ChangesPath
  1.20  +43 -6 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- XMLRenderer.java  2001/07/17 03:16:29 1.19
  +++ XMLRenderer.java  2001/07/27 00:18:27 1.20
  @@ -1,4 +1,4 @@
  -/* $Id: XMLRenderer.java,v 1.19 2001/07/17 03:16:29 arved Exp $
  +/* $Id: XMLRenderer.java,v 1.20 2001/07/27 00:18:27 arved Exp $
* 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.
  @@ -197,11 +197,11 @@
StringBuffer baText = new StringBuffer();
baText.append(BlockArea start-indent=\ + area.getStartIndent() + 
\);
baText.append( end-indent=\ + area.getEndIndent() + \);
  - baText.append(\nis-first=\ + area.isFirst + \);
  - baText.append( is-last=\ + area.isLast + \);
  - if (null != area.generatedBy)
  - baText.append( generated-by=\ + area.generatedBy.getName() +
  - // + area.generatedBy + \);
  + baText.append(\nis-first=\ + area.isFirst() + \);
  + baText.append( is-last=\ + area.isLast() + \);
  + if (null != area.getGeneratedBy())
  + baText.append( generated-by=\ + 
area.getGeneratedBy().getName() +
  + // + area.getGeneratedBy() + \);
baText.append();
   writeStartTag(baText.toString());

  @@ -231,6 +231,43 @@
   writeEndTag(/BlockArea);
   }
   
  + public void renderInlineArea(InlineArea area) {
  + StringBuffer iaText = new StringBuffer();
  + iaText.append(InlineArea);
  + iaText.append(\nis-first=\ + area.isFirst() + \);
  + iaText.append( is-last=\ + area.isLast() + \);
  + if (null != area.getGeneratedBy())
  + iaText.append( generated-by=\ + 
area.getGeneratedBy().getName() +
  + // + area.getGeneratedBy() + \);
  + iaText.append();
  +writeStartTag(iaText.toString());
  + 
  + // write out marker info
  + java.util.Vector markers = area.getMarkers();
  + if (!markers.isEmpty()) {
  + writeStartTag(Markers);
  + for (int m = 0; m  markers.size(); m++) {
  + org.apache.fop.fo.flow.Marker marker =
  + 
(org.apache.fop.fo.flow.Marker)markers.elementAt(m);
  + StringBuffer maText = new StringBuffer();
  + maText.append(Marker marker-class-name=\ +
  + marker.getMarkerClassName() + \);
  + maText.append( RegisteredArea=\ +
  + marker.getRegistryArea() + \);
  + maText.append(/);
  + writeEmptyElementTag(maText.toString());
  + }
  + writeEndTag(/Markers);
  + }
  + 
  +Enumeration e = area.getChildren().elements();
  +while (e.hasMoreElements()) {
  +Box b = (Box) e.nextElement();
  +b.render(this);
  +}
  +writeEndTag(/InlineArea);
  + }
  + 
   /**
* render a display space to XML
*
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-07-16 Thread arved

arved   01/07/16 20:16:29

  Modified:src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  AHS: improving area information
  
  Revision  ChangesPath
  1.19  +32 -6 xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- XMLRenderer.java  2001/06/05 12:51:53 1.18
  +++ XMLRenderer.java  2001/07/17 03:16:29 1.19
  @@ -1,4 +1,4 @@
  -/* $Id: XMLRenderer.java,v 1.18 2001/06/05 12:51:53 keiron Exp $
  +/* $Id: XMLRenderer.java,v 1.19 2001/07/17 03:16:29 arved Exp $
* 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.
  @@ -149,7 +149,7 @@
* @param area the area container to render
*/
   public void renderAreaContainer(AreaContainer area) {
  -writeStartTag(AreaContainer);
  +writeStartTag(AreaContainer name=\ + area.getAreaName() + \);
   Enumeration e = area.getChildren().elements();
   while (e.hasMoreElements()) {
   Box b = (Box) e.nextElement();
  @@ -194,9 +194,35 @@
* @param area the block area to render
*/
   public void renderBlockArea(BlockArea area) {
  -writeStartTag(BlockArea start-indent=\ +
  -  area.getStartIndent() + \ end-indent=\ +
  -  area.getEndIndent() + \);
  + StringBuffer baText = new StringBuffer();
  + baText.append(BlockArea start-indent=\ + area.getStartIndent() + 
\);
  + baText.append( end-indent=\ + area.getEndIndent() + \);
  + baText.append(\nis-first=\ + area.isFirst + \);
  + baText.append( is-last=\ + area.isLast + \);
  + if (null != area.generatedBy)
  + baText.append( generated-by=\ + area.generatedBy.getName() +
  + // + area.generatedBy + \);
  + baText.append();
  +writeStartTag(baText.toString());
  + 
  + // write out marker info
  + java.util.Vector markers = area.getMarkers();
  + if (!markers.isEmpty()) {
  + writeStartTag(Markers);
  + for (int m = 0; m  markers.size(); m++) {
  + org.apache.fop.fo.flow.Marker marker =
  + 
(org.apache.fop.fo.flow.Marker)markers.elementAt(m);
  + StringBuffer maText = new StringBuffer();
  + maText.append(Marker marker-class-name=\ +
  + marker.getMarkerClassName() + \);
  + maText.append( RegisteredArea=\ +
  + marker.getRegistryArea() + \);
  + maText.append(/);
  + writeEmptyElementTag(maText.toString());
  + }
  + writeEndTag(/Markers);
  + }
  + 
   Enumeration e = area.getChildren().elements();
   while (e.hasMoreElements()) {
   Box b = (Box) e.nextElement();
  @@ -310,7 +336,7 @@
   public void renderPage(Page page) {
   BodyAreaContainer body;
   AreaContainer before, after;
  -writeStartTag(Page number=\ + page.getNumber() + \);
  +writeStartTag(Page number=\ + page.getFormattedNumber() + \);
   body = page.getBody();
   before = page.getBefore();
   after = page.getAfter();
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




cvs commit: xml-fop/src/org/apache/fop/render/xml XMLRenderer.java

2001-06-05 Thread keiron

keiron  01/06/05 05:51:56

  Modified:src/org/apache/fop/render/xml XMLRenderer.java
  Log:
  some cleanup and more consistent output
  
  Revision  ChangesPath
  1.18  +171 -218  xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java
  
  Index: XMLRenderer.java
  ===
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/xml/XMLRenderer.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- XMLRenderer.java  2001/05/20 23:56:49 1.17
  +++ XMLRenderer.java  2001/06/05 12:51:53 1.18
  @@ -1,53 +1,9 @@
  -/*-- $Id: XMLRenderer.java,v 1.17 2001/05/20 23:56:49 arved Exp $ -- 
  -
  - 
  -   The Apache Software License, Version 1.1
  - 
  - 
  -Copyright (C) 1999 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
  -[EMAIL PROTECTED]
  - 
  - 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 [EMAIL PROTECTED]. For more  information on the Apache 
  - Software Foundation, please see http://www.apache.org/.
  - 
  +/* $Id: XMLRenderer.java,v 1.18 2001/06/05 12:51:53 keiron Exp $
  + * 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.
*/
  +
   package org.apache.fop.render.xml;
   
   // FOP
  @@ -71,7 +27,7 @@
* Renderer that renders areas to XML for debugging purposes.
*/
   public class XMLRenderer implements Renderer {
  -
  +
   /** indentation to use for pretty-printing the XML */
   protected int indent = 0;
   
  @@ -80,25 +36,25 @@
   
   /** the writer used to output the XML */
   protected PrintWriter writer;
  +
  +/** options */
  +protected Hashtable options;
  +
  +public XMLRenderer() {
  +}
  +
  +/** set up renderer options */
  +public void setOptions(Hashtable options) {
  +this.options = options;
  +}
   
  - /** options */
  - protected Hashtable options;
  - 
  - public XMLRenderer() {
  - }
  -
  - /** set up renderer options */
  - public void setOptions(Hashtable options) {
  - this.options = options;
  - }
  - 
   /**
* set the document's producer
*
* @param producer string indicating application producing the XML
*/
   public void setProducer(String producer) {
  - this.producer = producer;
  +this.producer = producer;
   }
   
   /**
  @@