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 ke...@apache.org on 2001/01/24 01:31:43 UTC

cvs commit: xml-fop/src/org/apache/fop/svg SVG.java

keiron      01/01/23 16:31:41

  Modified:    src/org/apache/fop/fo/flow InstreamForeignObject.java
                        Leader.java
               src/org/apache/fop/layout LineArea.java
               src/org/apache/fop/render Renderer.java
               src/org/apache/fop/render/pdf PDFRenderer.java
               src/org/apache/fop/render/awt AWTRenderer.java
               src/org/apache/fop/render/xml XMLRenderer.java
               src/org/apache/fop/svg SVG.java
  Log:
  changed inline references to layout.inline
  also renderers now render a word area
  
  Revision  Changes    Path
  1.6       +2 -1      xml-fop/src/org/apache/fop/fo/flow/InstreamForeignObject.java
  
  Index: InstreamForeignObject.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/flow/InstreamForeignObject.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- InstreamForeignObject.java	2000/09/15 00:17:29	1.5
  +++ InstreamForeignObject.java	2001/01/24 00:31:23	1.6
  @@ -1,4 +1,4 @@
  -/*-- $Id: InstreamForeignObject.java,v 1.5 2000/09/15 00:17:29 keiron Exp $ -- 
  +/*-- $Id: InstreamForeignObject.java,v 1.6 2001/01/24 00:31:23 keiron Exp $ -- 
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -55,6 +55,7 @@
   import org.apache.fop.fo.*;
   import org.apache.fop.fo.properties.*;
   import org.apache.fop.layout.*;
  +import org.apache.fop.layout.inline.*;
   import org.apache.fop.layout.BlockArea;
   import org.apache.fop.layout.FontState;
   import org.apache.fop.apps.FOPException;
  
  
  
  1.4       +2 -2      xml-fop/src/org/apache/fop/fo/flow/Leader.java
  
  Index: Leader.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/flow/Leader.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Leader.java	2000/12/20 18:20:16	1.3
  +++ Leader.java	2001/01/24 00:31:24	1.4
  @@ -1,4 +1,4 @@
  -/*-- $Id: Leader.java,v 1.3 2000/12/20 18:20:16 fotis Exp $ --
  +/*-- $Id: Leader.java,v 1.4 2001/01/24 00:31:24 keiron Exp $ --
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -56,7 +56,7 @@
   import org.apache.fop.datatypes.*;
   import org.apache.fop.layout.Area;
   import org.apache.fop.layout.BlockArea;
  -import org.apache.fop.layout.LeaderArea;
  +import org.apache.fop.layout.inline.LeaderArea;
   import org.apache.fop.layout.FontState;
   import org.apache.fop.apps.FOPException;
   import org.apache.fop.messaging.MessageHandler;
  
  
  
  1.29      +13 -13    xml-fop/src/org/apache/fop/layout/LineArea.java
  
  Index: LineArea.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/layout/LineArea.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -r1.28 -r1.29
  --- LineArea.java	2001/01/02 02:30:57	1.28
  +++ LineArea.java	2001/01/24 00:31:28	1.29
  @@ -1,4 +1,4 @@
  -/*-- $Id: LineArea.java,v 1.28 2001/01/02 02:30:57 keiron Exp $ --
  +/*-- $Id: LineArea.java,v 1.29 2001/01/24 00:31:28 keiron Exp $ --
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -54,7 +54,7 @@
   //fop
   import org.apache.fop.render.Renderer;
   import org.apache.fop.messaging.MessageHandler;
  -import org.apache.fop.layout.LeaderArea;
  +import org.apache.fop.layout.inline.*;
   import org.apache.fop.datatypes.IDNode;
   import org.apache.fop.fo.properties.WrapOption;
   import org.apache.fop.fo.properties.WhiteSpaceCollapse;
  @@ -289,7 +289,7 @@
                       // add the current word
   
                       if (wordLength > 0) {
  -                        InlineArea ia = new InlineArea(currentFontState,
  +                        WordArea ia = new WordArea(currentFontState,
                                                          this.red, this.green, this.blue,
                                                          new String(data, wordStart,
                                                                     wordLength), wordWidth);
  @@ -407,7 +407,7 @@
   
           if (prev == TEXT) {
   
  -            InlineArea pia = new InlineArea(currentFontState, this.red,
  +            WordArea pia = new WordArea(currentFontState, this.red,
                                               this.green, this.blue,
                                               new String(data, wordStart, wordLength), wordWidth);
   
  @@ -441,7 +441,7 @@
                             int leaderLengthOptimum, int leaderLengthMaximum,
                             int ruleStyle, int ruleThickness, int leaderPatternWidth,
                             int leaderAlignment) {
  -        InlineArea leaderPatternArea;
  +        WordArea leaderPatternArea;
           int leaderLength;
           int remainingWidth =
             this.getContentWidth() - this.getCurrentXPosition();
  @@ -504,7 +504,7 @@
                         new InlineSpace(leaderPatternWidth -
                                         this.currentFontState.width(46), false);
                       leaderPatternArea =
  -                      new InlineArea(currentFontState, this.red,
  +                      new WordArea(currentFontState, this.red,
                                        this.green, this.blue, new String ("."),
                                        this.currentFontState.width(46));
                       int dotsFactor = (int) Math.floor (
  @@ -697,8 +697,8 @@
           for (int i = 0; i < factor; i ++) {
               leaderChars[i] = fillChar;
           }
  -        InlineArea leaderPatternArea =
  -          new InlineArea(currentFontState, this.red, this.green,
  +        WordArea leaderPatternArea =
  +          new WordArea(currentFontState, this.red, this.green,
                            this.blue, new String (leaderChars), leaderLength);
           return leaderPatternArea;
       }
  @@ -861,7 +861,7 @@
   
       /** adds a single character to the line area tree*/ 
       public int addCharacter (char data, LinkSet ls, boolean ul) {
  -        InlineArea ia = null;
  +        WordArea ia = null;
           int remainingWidth =
             this.getContentWidth() - this.getCurrentXPosition();
           int width = this.currentFontState.width(data);
  @@ -874,7 +874,7 @@
               return org.apache.fop.fo.flow.Character.OK;
             }
             //create new InlineArea
  -          ia = new InlineArea(currentFontState,
  +          ia = new WordArea(currentFontState,
                                            this.red, this.green, this.blue,
                                            new Character(data).toString(),width);
             ia.setUnderlined(ul);
  @@ -894,18 +894,18 @@
       /** adds a InlineArea containing the String startChar+wordBuf to the line area children.  */
       private void addWord (char startChar, StringBuffer wordBuf) {
           String word = wordBuf.toString();
  -        InlineArea hia;
  +        WordArea hia;
           int startCharWidth = this.currentFontState.width(startChar);
           if (startChar == ' ') {
               this.addChild(new InlineSpace(startCharWidth));
           } else {
  -            hia = new InlineArea(currentFontState,
  +            hia = new WordArea(currentFontState,
                                    this.red, this.green, this.blue,
                                    new Character(startChar).toString(),1);
               this.addChild(hia);
           }
           int wordWidth = this.getWordWidth(word);
  -        hia = new InlineArea(currentFontState,
  +        hia = new WordArea(currentFontState,
                                    this.red, this.green, this.blue,
                                    word,word.length());
           this.addChild(hia);
  
  
  
  1.13      +3 -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.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- Renderer.java	2000/12/18 04:56:14	1.12
  +++ Renderer.java	2001/01/24 00:31:31	1.13
  @@ -1,4 +1,4 @@
  -/*-- $Id: Renderer.java,v 1.12 2000/12/18 04:56:14 kellyc Exp $ -- 
  +/*-- $Id: Renderer.java,v 1.13 2001/01/24 00:31:31 keiron Exp $ -- 
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -55,6 +55,7 @@
   import org.apache.fop.image.ImageArea;
   import org.apache.fop.apps.FOPException;
   import org.apache.fop.layout.*;
  +import org.apache.fop.layout.inline.*;
   
   // Java
   import java.io.OutputStream;
  @@ -102,7 +103,7 @@
       public void renderImageArea(ImageArea area);
   
       /** render the given inline area */
  -    public void renderInlineArea(InlineArea area);
  +    public void renderWordArea(WordArea area);
   
       /** render the given inline space */
       public void renderInlineSpace(InlineSpace space);
  
  
  
  1.46      +3 -2      xml-fop/src/org/apache/fop/render/pdf/PDFRenderer.java
  
  Index: PDFRenderer.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/render/pdf/PDFRenderer.java,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -r1.45 -r1.46
  --- PDFRenderer.java	2000/12/27 03:55:13	1.45
  +++ PDFRenderer.java	2001/01/24 00:31:33	1.46
  @@ -1,4 +1,4 @@
  -/*-- $Id: PDFRenderer.java,v 1.45 2000/12/27 03:55:13 arved Exp $ --
  +/*-- $Id: PDFRenderer.java,v 1.46 2001/01/24 00:31:33 keiron Exp $ --
   
    ============================================================================
   				   The Apache Software License, Version 1.1
  @@ -59,6 +59,7 @@
   import org.apache.fop.apps.FOPException;
   import org.apache.fop.fo.properties.*;
   import org.apache.fop.layout.*;
  +import org.apache.fop.layout.inline.*;
   import org.apache.fop.datatypes.*;
   import org.apache.fop.svg.PathPoint;
   import org.apache.fop.pdf.*;
  @@ -565,7 +566,7 @@
          *
          * @param area inline area to render
          */
  -    public void renderInlineArea(InlineArea area) {
  +    public void renderWordArea(WordArea area) {
           char ch;
           StringBuffer pdf = new StringBuffer();
   
  
  
  
  1.18      +2 -1      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.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- AWTRenderer.java	2000/12/22 02:04:44	1.17
  +++ AWTRenderer.java	2001/01/24 00:31:36	1.18
  @@ -10,6 +10,7 @@
    */
   
   import org.apache.fop.layout.*;
  +import org.apache.fop.layout.inline.*;
   import org.apache.fop.messaging.MessageHandler;
   import org.apache.fop.datatypes.*;
   import org.apache.fop.image.*;
  @@ -542,7 +543,7 @@
   
       }
   
  -    public void renderInlineArea(InlineArea area) {
  +    public void renderWordArea(WordArea area) {
           char ch;
           StringBuffer pdf = new StringBuffer();
   
  
  
  
  1.15      +3 -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.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- XMLRenderer.java	2000/12/18 04:56:16	1.14
  +++ XMLRenderer.java	2001/01/24 00:31:38	1.15
  @@ -1,4 +1,4 @@
  -/*-- $Id: XMLRenderer.java,v 1.14 2000/12/18 04:56:16 kellyc Exp $ -- 
  +/*-- $Id: XMLRenderer.java,v 1.15 2001/01/24 00:31:38 keiron Exp $ -- 
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -58,6 +58,7 @@
   import org.apache.fop.render.Renderer;
   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;
   
  @@ -279,7 +280,7 @@
        *
        * @param area the area to render
        */
  -    public void renderInlineArea(InlineArea area) {
  +    public void renderWordArea(WordArea area) {
   	String fontWeight = area.getFontState().getFontWeight();
   	StringBuffer sb = new StringBuffer();
   	String s = area.getText();
  
  
  
  1.17      +2 -2      xml-fop/src/org/apache/fop/svg/SVG.java
  
  Index: SVG.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/svg/SVG.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- SVG.java	2000/11/29 03:22:02	1.16
  +++ SVG.java	2001/01/24 00:31:39	1.17
  @@ -1,4 +1,4 @@
  -/*-- $Id: SVG.java,v 1.16 2000/11/29 03:22:02 keiron Exp $ --
  +/*-- $Id: SVG.java,v 1.17 2001/01/24 00:31:39 keiron Exp $ --
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -55,9 +55,9 @@
   import org.apache.fop.fo.*;
   import org.apache.fop.fo.properties.*;
   import org.apache.fop.layout.Area;
  -import org.apache.fop.layout.ForeignObjectArea;
   import org.apache.fop.layout.FontState;
   import org.apache.fop.apps.FOPException;
  +import org.apache.fop.layout.inline.*;
   
   import org.apache.fop.dom.svg.*;
   import org.w3c.dom.svg.*;