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 gm...@apache.org on 2004/06/15 08:26:57 UTC
cvs commit: xml-fop/src/java/org/apache/fop/render/xml XMLRenderer.java
gmazza 2004/06/14 23:26:57
Modified: src/java/org/apache/fop/apps Document.java Driver.java
src/java/org/apache/fop/fo FOInputHandler.java FONode.java
FOTreeBuilder.java FOTreeHandler.java FObj.java
FObjMixed.java PropertyManager.java
src/java/org/apache/fop/fo/flow BasicLink.java Block.java
ExternalGraphic.java Footnote.java
FootnoteBody.java Inline.java Leader.java
ListBlock.java ListItem.java ListItemLabel.java
PageNumber.java PageNumberCitation.java Table.java
TableBody.java TableCell.java TableColumn.java
TableRow.java
src/java/org/apache/fop/fo/pagination Declarations.java
Flow.java PageSequence.java Root.java Title.java
src/java/org/apache/fop/layoutmgr BlockLayoutManager.java
src/java/org/apache/fop/render/awt AWTRenderer.java
src/java/org/apache/fop/render/ps PSRenderer.java
src/java/org/apache/fop/render/svg SVGRenderer.java
src/java/org/apache/fop/render/xml XMLRenderer.java
Removed: src/java/org/apache/fop/fo FOTreeControl.java
Log:
1.) Added restriction to fo:declarations that fo:color-profile is the only XSL namespace child element allowed.
2.) Switched from fo.FOTreeControl to apps.Document throughout app, to better clarify that it is the apps.Document object being accessed/used.
Revision Changes Path
1.20 +2 -3 xml-fop/src/java/org/apache/fop/apps/Document.java
Index: Document.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/apps/Document.java,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- Document.java 15 Jun 2004 00:30:43 -0000 1.19
+++ Document.java 15 Jun 2004 06:26:55 -0000 1.20
@@ -28,7 +28,6 @@
import org.apache.fop.area.AreaTreeModel;
import org.apache.fop.fo.FOInputHandler;
-import org.apache.fop.fo.FOTreeControl;
import org.apache.fop.fonts.FontInfo;
import org.apache.commons.logging.Log;
@@ -40,7 +39,7 @@
* Class storing information for the FOP Document being processed, and managing
* the processing of it.
*/
-public class Document implements FOTreeControl {
+public class Document {
/** The parent Driver object */
private Driver driver;
1.64 +2 -2 xml-fop/src/java/org/apache/fop/apps/Driver.java
Index: Driver.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/apps/Driver.java,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -r1.63 -r1.64
--- Driver.java 13 Jun 2004 01:21:17 -0000 1.63
+++ Driver.java 15 Jun 2004 06:26:55 -0000 1.64
@@ -511,7 +511,7 @@
foInputHandler.setLogger(getLogger());
treeBuilder.setFOInputHandler(foInputHandler);
- treeBuilder.setFOTreeControl(currentDocument);
+ treeBuilder.setDocument(currentDocument);
return new ProxyContentHandler(treeBuilder) {
1.17 +3 -3 xml-fop/src/java/org/apache/fop/fo/FOInputHandler.java
Index: FOInputHandler.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FOInputHandler.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- FOInputHandler.java 11 Jun 2004 17:18:51 -0000 1.16
+++ FOInputHandler.java 15 Jun 2004 06:26:55 -0000 1.17
@@ -94,8 +94,8 @@
}
/**
- * Returns the FOTreeControl object associated with this FOInputHandler.
- * @return the FOTreeControl object
+ * Returns the Document object associated with this FOInputHandler.
+ * @return the Document object
*/
public Document getDocument() {
return doc;
1.22 +6 -5 xml-fop/src/java/org/apache/fop/fo/FONode.java
Index: FONode.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FONode.java,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- FONode.java 15 Jun 2004 00:30:43 -0000 1.21
+++ FONode.java 15 Jun 2004 06:26:55 -0000 1.22
@@ -28,9 +28,10 @@
import org.apache.commons.logging.Log;
// FOP
+import org.apache.fop.apps.Document;
import org.apache.fop.apps.FOPException;
-import org.apache.fop.util.CharUtilities;
import org.apache.fop.apps.FOUserAgent;
+import org.apache.fop.util.CharUtilities;
import org.apache.fop.fo.extensions.ExtensionElementMapping;
import org.apache.fop.fo.extensions.svg.SVGElementMapping;
@@ -59,7 +60,7 @@
* @return FOUserAgent
*/
public FOUserAgent getUserAgent() {
- return getFOTreeControl().getDriver().getUserAgent();
+ return getDocument().getDriver().getUserAgent();
}
/**
@@ -67,7 +68,7 @@
* @return the logger
*/
public Log getLogger() {
- return getFOTreeControl().getDriver().getLogger();
+ return getDocument().getDriver().getLogger();
}
/**
@@ -183,8 +184,8 @@
* which returns the parent Document.
* @return the Document object that is the parent of this node.
*/
- public FOTreeControl getFOTreeControl() {
- return parent.getFOTreeControl();
+ public Document getDocument() {
+ return parent.getDocument();
}
/**
1.31 +8 -7 xml-fop/src/java/org/apache/fop/fo/FOTreeBuilder.java
Index: FOTreeBuilder.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FOTreeBuilder.java,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- FOTreeBuilder.java 15 Jun 2004 00:30:43 -0000 1.30
+++ FOTreeBuilder.java 15 Jun 2004 06:26:55 -0000 1.31
@@ -31,6 +31,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.apache.fop.apps.Document;
import org.apache.fop.apps.FOPException;
import org.apache.fop.fo.ElementMapping.Maker;
import org.apache.fop.fo.pagination.Root;
@@ -79,8 +80,8 @@
*/
private FOInputHandler foInputHandler;
- /** The FOTreeControl object managing the FO Tree that is being built */
- private FOTreeControl foTreeControl;
+ /** The Document object managing the FO Tree that is being built */
+ private Document document;
/** The SAX locator object managing the line and column counters */
private Locator locator;
@@ -93,11 +94,11 @@
}
/**
- * Sets the FO Tree Control for this object
- * @param fotc FOTreeControl instance
+ * Sets the apps.Document for this object
+ * @param doc Document instance
*/
- public void setFOTreeControl(FOTreeControl fotc) {
- this.foTreeControl = fotc;
+ public void setDocument(Document doc) {
+ this.document = doc;
}
/**
@@ -253,7 +254,7 @@
if (rootFObj == null) {
rootFObj = (Root) foNode;
- rootFObj.setFOTreeControl(foTreeControl);
+ rootFObj.setDocument(document);
} else {
currentFObj.addChild(foNode);
}
1.20 +3 -3 xml-fop/src/java/org/apache/fop/fo/FOTreeHandler.java
Index: FOTreeHandler.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FOTreeHandler.java,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- FOTreeHandler.java 15 Jun 2004 00:30:43 -0000 1.19
+++ FOTreeHandler.java 15 Jun 2004 06:26:55 -0000 1.20
@@ -98,7 +98,7 @@
/**
* Main constructor
- * @param foTreeControl the FOTreeControl implementation that governs this
+ * @param document the apps.Document implementation that governs this
* FO Tree
* @param store if true then use the store pages model and keep the
* area tree in memory
@@ -478,7 +478,7 @@
*
* @return the font information
*/
- public FOTreeControl getFontInfo() {
+ public Document getFontInfo() {
return doc;
}
1.44 +1 -1 xml-fop/src/java/org/apache/fop/fo/FObj.java
Index: FObj.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FObj.java,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -r1.43 -r1.44
--- FObj.java 15 Jun 2004 00:30:43 -0000 1.43
+++ FObj.java 15 Jun 2004 06:26:55 -0000 1.44
@@ -298,7 +298,7 @@
if (prop != null) {
String str = prop.getString();
if (str != null && !str.equals("")) {
- Set idrefs = getFOTreeControl().getIDReferences();
+ Set idrefs = getDocument().getIDReferences();
if (!idrefs.contains(str)) {
id = str;
idrefs.add(id);
1.24 +3 -3 xml-fop/src/java/org/apache/fop/fo/FObjMixed.java
Index: FObjMixed.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/FObjMixed.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- FObjMixed.java 4 Apr 2004 06:29:44 -0000 1.23
+++ FObjMixed.java 15 Jun 2004 06:26:55 -0000 1.24
@@ -46,8 +46,8 @@
if (textInfo == null) {
// Really only need one of these, but need to get fontInfo
// stored in propMgr for later use.
- propMgr.setFontInfo(getFOTreeControl());
- textInfo = propMgr.getTextLayoutProps(getFOTreeControl());
+ propMgr.setFontInfo(getDocument());
+ textInfo = propMgr.getTextLayoutProps(getDocument());
}
FOText ft = new FOText(data, start, length, textInfo, this);
@@ -55,7 +55,7 @@
ft.setName("text");
/* characters() processing empty for FOTreeHandler, not empty for RTF & MIFHandlers */
- getFOTreeControl().getFOInputHandler().characters(ft.ca, ft.startIndex, ft.endIndex);
+ getDocument().getFOInputHandler().characters(ft.ca, ft.startIndex, ft.endIndex);
addChild(ft);
}
1.29 +16 -15 xml-fop/src/java/org/apache/fop/fo/PropertyManager.java
Index: PropertyManager.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/PropertyManager.java,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -r1.28 -r1.29
--- PropertyManager.java 29 May 2004 08:50:46 -0000 1.28
+++ PropertyManager.java 15 Jun 2004 06:26:55 -0000 1.29
@@ -19,6 +19,7 @@
package org.apache.fop.fo;
// FOP
+import org.apache.fop.apps.Document;
import org.apache.fop.apps.FOPException;
import org.apache.fop.fonts.Font;
import org.apache.fop.fo.properties.Property;
@@ -44,7 +45,7 @@
public class PropertyManager implements Constants {
private PropertyList propertyList;
- private FOTreeControl foTreeControl = null;
+ private Document document = null;
private Font fontState = null;
private CommonBorderAndPadding borderAndPadding = null;
private CommonHyphenation hyphProps = null;
@@ -72,27 +73,27 @@
/**
* Sets the Document object telling the property manager which fonts are
* available.
- * @param foTreeControl foTreeControl implementation containing font
+ * @param document apps.Document implementation containing font
* information
*/
- public void setFontInfo(FOTreeControl foTreeControl) {
- this.foTreeControl = foTreeControl;
+ public void setFontInfo(Document document) {
+ this.document = document;
}
/**
* Constructs a FontState object. If it was constructed before it is
* reused.
- * @param foTreeControl FOTreeControl implementation containing the font
+ * @param document apps.Document implementation containing the font
* information
* @return a FontState object
*/
- public Font getFontState(FOTreeControl foTreeControl) {
+ public Font getFontState(Document document) {
if (fontState == null) {
- if (foTreeControl == null) {
- foTreeControl = this.foTreeControl;
- } else if (this.foTreeControl == null) {
- this.foTreeControl = foTreeControl;
+ if (document == null) {
+ document = this.document;
+ } else if (this.document == null) {
+ this.document = document;
}
/**@todo this is ugly. need to improve. */
@@ -121,9 +122,9 @@
// various kinds of keywords too
int fontSize = propertyList.get(PR_FONT_SIZE).getLength().getValue();
//int fontVariant = propertyList.get("font-variant").getEnum();
- String fname = foTreeControl.getFontInfo().fontLookup(fontFamily, fontStyle,
+ String fname = document.getFontInfo().fontLookup(fontFamily, fontStyle,
fontWeight);
- FontMetrics metrics = foTreeControl.getFontInfo().getMetricsFor(fname);
+ FontMetrics metrics = document.getFontInfo().getMetricsFor(fname);
fontState = new Font(fname, metrics, fontSize);
}
return fontState;
@@ -457,14 +458,14 @@
/**
* Constructs a TextInfo objects. If it was constructed before it is
* reused.
- * @param foTreeControl FOTreeControl implementation containing list of
+ * @param document apps.Document implementation containing list of
* available fonts
* @return a TextInfo object
*/
- public TextInfo getTextLayoutProps(FOTreeControl foTreeControl) {
+ public TextInfo getTextLayoutProps(Document document) {
if (textInfo == null) {
textInfo = new TextInfo();
- textInfo.fs = getFontState(foTreeControl);
+ textInfo.fs = getFontState(document);
textInfo.color = propertyList.get(PR_COLOR).getColorType();
textInfo.verticalAlign =
1.13 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/BasicLink.java
Index: BasicLink.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/BasicLink.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- BasicLink.java 12 Jun 2004 23:18:52 -0000 1.12
+++ BasicLink.java 15 Jun 2004 06:26:55 -0000 1.13
@@ -54,7 +54,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startLink(this);
+ getDocument().getFOInputHandler().startLink(this);
}
public void setup() {
@@ -143,7 +143,7 @@
public void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endLink();
+ getDocument().getFOInputHandler().endLink();
}
public String getName() {
1.18 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/Block.java
Index: Block.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/Block.java,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- Block.java 12 Jun 2004 23:18:52 -0000 1.17
+++ Block.java 15 Jun 2004 06:26:55 -0000 1.18
@@ -111,7 +111,7 @@
setupID();
- getFOTreeControl().getFOInputHandler().startBlock(this);
+ getDocument().getFOInputHandler().startBlock(this);
}
private void setup() {
@@ -238,7 +238,7 @@
*/
public void end() {
handleWhiteSpace();
- getFOTreeControl().getFOInputHandler().endBlock(this);
+ getDocument().getFOInputHandler().endBlock(this);
}
private void handleWhiteSpace() {
1.26 +1 -1 xml-fop/src/java/org/apache/fop/fo/flow/ExternalGraphic.java
Index: ExternalGraphic.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/ExternalGraphic.java,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- ExternalGraphic.java 12 Jun 2004 23:18:52 -0000 1.25
+++ ExternalGraphic.java 15 Jun 2004 06:26:55 -0000 1.26
@@ -63,7 +63,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().image(this);
+ getDocument().getFOInputHandler().image(this);
}
/**
1.10 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/Footnote.java
Index: Footnote.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/Footnote.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- Footnote.java 12 Jun 2004 23:18:52 -0000 1.9
+++ Footnote.java 15 Jun 2004 06:26:55 -0000 1.10
@@ -48,7 +48,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startFootnote(this);
+ getDocument().getFOInputHandler().startFootnote(this);
}
/**
@@ -79,7 +79,7 @@
protected void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endFootnote(this);
+ getDocument().getFOInputHandler().endFootnote(this);
}
public String getName() {
1.9 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/FootnoteBody.java
Index: FootnoteBody.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/FootnoteBody.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- FootnoteBody.java 12 Jun 2004 23:18:52 -0000 1.8
+++ FootnoteBody.java 15 Jun 2004 06:26:55 -0000 1.9
@@ -52,7 +52,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startFootnoteBody(this);
+ getDocument().getFOInputHandler().startFootnoteBody(this);
}
public void acceptVisitor(FOTreeVisitor fotv) {
@@ -62,7 +62,7 @@
protected void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endFootnoteBody(this);
+ getDocument().getFOInputHandler().endFootnoteBody(this);
}
public String getName() {
1.13 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/Inline.java
Index: Inline.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/Inline.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- Inline.java 12 Jun 2004 23:18:52 -0000 1.12
+++ Inline.java 15 Jun 2004 06:26:55 -0000 1.13
@@ -114,7 +114,7 @@
this.lineThrough = true;
}
- getFOTreeControl().getFOInputHandler().startInline(this);
+ getDocument().getFOInputHandler().startInline(this);
}
/**
@@ -139,7 +139,7 @@
* @see org.apache.fop.fo.FONode#end
*/
public void end() {
- getFOTreeControl().getFOInputHandler().endInline(this);
+ getDocument().getFOInputHandler().endInline(this);
}
public String getName() {
1.25 +1 -1 xml-fop/src/java/org/apache/fop/fo/flow/Leader.java
Index: Leader.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/Leader.java,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- Leader.java 12 Jun 2004 23:18:52 -0000 1.24
+++ Leader.java 15 Jun 2004 06:26:55 -0000 1.25
@@ -66,7 +66,7 @@
CommonBackground bProps = propMgr.getBackgroundProps();
// Common Font Properties
- this.fontState = propMgr.getFontState(getFOTreeControl());
+ this.fontState = propMgr.getFontState(getDocument());
// Common Margin Properties-Inline
CommonMarginInline mProps = propMgr.getMarginInlineProps();
1.13 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/ListBlock.java
Index: ListBlock.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/ListBlock.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- ListBlock.java 12 Jun 2004 23:18:52 -0000 1.12
+++ ListBlock.java 15 Jun 2004 06:26:55 -0000 1.13
@@ -64,7 +64,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startList(this);
+ getDocument().getFOInputHandler().startList(this);
}
private void setup() throws FOPException {
@@ -139,7 +139,7 @@
protected void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endList(this);
+ getDocument().getFOInputHandler().endList(this);
}
public String getName() {
1.14 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/ListItem.java
Index: ListItem.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/ListItem.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- ListItem.java 12 Jun 2004 23:18:52 -0000 1.13
+++ ListItem.java 15 Jun 2004 06:26:55 -0000 1.14
@@ -64,7 +64,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startListItem(this);
+ getDocument().getFOInputHandler().startListItem(this);
}
private void setup() {
@@ -148,7 +148,7 @@
protected void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endListItem(this);
+ getDocument().getFOInputHandler().endListItem(this);
}
public String getName() {
1.15 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/ListItemLabel.java
Index: ListItemLabel.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/ListItemLabel.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- ListItemLabel.java 12 Jun 2004 23:18:52 -0000 1.14
+++ ListItemLabel.java 15 Jun 2004 06:26:55 -0000 1.15
@@ -46,7 +46,7 @@
*/
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
- getFOTreeControl().getFOInputHandler().startListLabel();
+ getDocument().getFOInputHandler().startListLabel();
}
private void setup() {
@@ -86,7 +86,7 @@
protected void end() {
super.end();
- getFOTreeControl().getFOInputHandler().endListLabel();
+ getDocument().getFOInputHandler().endListLabel();
}
public String getName() {
1.22 +3 -3 xml-fop/src/java/org/apache/fop/fo/flow/PageNumber.java
Index: PageNumber.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/PageNumber.java,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- PageNumber.java 12 Jun 2004 23:18:52 -0000 1.21
+++ PageNumber.java 15 Jun 2004 06:26:55 -0000 1.22
@@ -61,7 +61,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
setup();
- getFOTreeControl().getFOInputHandler().startPageNumber(this);
+ getDocument().getFOInputHandler().startPageNumber(this);
}
public void setup() {
@@ -77,7 +77,7 @@
CommonBackground bProps = propMgr.getBackgroundProps();
// Common Font Properties
- this.fontState = propMgr.getFontState(getFOTreeControl());
+ this.fontState = propMgr.getFontState(getDocument());
// Common Margin Properties-Inline
CommonMarginInline mProps = propMgr.getMarginInlineProps();
@@ -129,7 +129,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endPageNumber(this);
+ getDocument().getFOInputHandler().endPageNumber(this);
}
public String getName() {
1.22 +1 -1 xml-fop/src/java/org/apache/fop/fo/flow/PageNumberCitation.java
Index: PageNumberCitation.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/PageNumberCitation.java,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- PageNumberCitation.java 12 Jun 2004 23:18:52 -0000 1.21
+++ PageNumberCitation.java 15 Jun 2004 06:26:55 -0000 1.22
@@ -82,7 +82,7 @@
CommonBackground bProps = propMgr.getBackgroundProps();
// Common Font Properties
- this.fontState = propMgr.getFontState(getFOTreeControl());
+ this.fontState = propMgr.getFontState(getDocument());
// Common Margin Properties-Inline
CommonMarginInline mProps = propMgr.getMarginInlineProps();
1.17 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/Table.java
Index: Table.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/Table.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- Table.java 12 Jun 2004 23:18:52 -0000 1.16
+++ Table.java 15 Jun 2004 06:26:55 -0000 1.17
@@ -81,7 +81,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
setupID();
- getFOTreeControl().getFOInputHandler().startTable(this);
+ getDocument().getFOInputHandler().startTable(this);
}
/**
@@ -203,7 +203,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endTable(this);
+ getDocument().getFOInputHandler().endTable(this);
}
public String getName() {
1.13 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/TableBody.java
Index: TableBody.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/TableBody.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- TableBody.java 12 Jun 2004 23:18:52 -0000 1.12
+++ TableBody.java 15 Jun 2004 06:26:55 -0000 1.13
@@ -57,7 +57,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
setupID();
- getFOTreeControl().getFOInputHandler().startBody(this);
+ getDocument().getFOInputHandler().startBody(this);
}
private void setup() throws FOPException {
@@ -104,7 +104,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endBody(this);
+ getDocument().getFOInputHandler().endBody(this);
}
public String getName() {
1.15 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/TableCell.java
Index: TableCell.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/TableCell.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- TableCell.java 12 Jun 2004 23:18:52 -0000 1.14
+++ TableCell.java 15 Jun 2004 06:26:55 -0000 1.15
@@ -123,7 +123,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
doSetup(); // init some basic property values
- getFOTreeControl().getFOInputHandler().startCell(this);
+ getDocument().getFOInputHandler().startCell(this);
}
/**
@@ -348,7 +348,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endCell(this);
+ getDocument().getFOInputHandler().endCell(this);
}
public String getName() {
1.18 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/TableColumn.java
Index: TableColumn.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/TableColumn.java,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- TableColumn.java 12 Jun 2004 23:18:52 -0000 1.17
+++ TableColumn.java 15 Jun 2004 06:26:55 -0000 1.18
@@ -60,7 +60,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
initialize(); // init some basic property values
- getFOTreeControl().getFOInputHandler().startColumn(this);
+ getDocument().getFOInputHandler().startColumn(this);
}
/**
@@ -124,7 +124,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endColumn(this);
+ getDocument().getFOInputHandler().endColumn(this);
}
public String getName() {
1.18 +2 -2 xml-fop/src/java/org/apache/fop/fo/flow/TableRow.java
Index: TableRow.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/flow/TableRow.java,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- TableRow.java 12 Jun 2004 23:18:52 -0000 1.17
+++ TableRow.java 15 Jun 2004 06:26:55 -0000 1.18
@@ -68,7 +68,7 @@
protected void addProperties(Attributes attlist) throws FOPException {
super.addProperties(attlist);
setupID();
- getFOTreeControl().getFOInputHandler().startRow(this);
+ getDocument().getFOInputHandler().startRow(this);
}
/**
@@ -145,7 +145,7 @@
}
protected void end() {
- getFOTreeControl().getFOInputHandler().endRow(this);
+ getDocument().getFOInputHandler().endRow(this);
}
public String getName() {
1.8 +16 -2 xml-fop/src/java/org/apache/fop/fo/pagination/Declarations.java
Index: Declarations.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/pagination/Declarations.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- Declarations.java 13 Jun 2004 19:58:58 -0000 1.7
+++ Declarations.java 15 Jun 2004 06:26:56 -0000 1.8
@@ -24,6 +24,7 @@
import java.util.Iterator;
// FOP
+import org.apache.fop.fo.FOElementMapping;
import org.apache.fop.fo.FONode;
import org.apache.fop.fo.FObj;
import org.apache.fop.fo.FOTreeVisitor;
@@ -51,6 +52,19 @@
}
/**
+ * @see org.apache.fop.fo.FONode#validateChildNode(String, String)
+ XSL 1.0: (color-profile)+ (and non-XSL NS nodes)
+ FOP (currently): (color-profile)* (and non-XSL NS nodes)
+ */
+ protected void validateChildNode(String nsURI, String localName) {
+ if (nsURI == FOElementMapping.URI) {
+ if (!localName.equals("color-profile")) {
+ invalidChildError(nsURI, localName);
+ }
+ } // anything outside of XSL namespace is OK.
+ }
+
+ /**
* At the end of this element sort out the child into
* a hashmap of color profiles and a list of external xml.
*/
@@ -79,7 +93,7 @@
}
external.add(node);
} else {
- getLogger().warn("invalid element " + node.getName() + "inside declarations");
+ getLogger().warn("invalid element " + node.getName() + " inside declarations");
}
}
}
1.11 +3 -3 xml-fop/src/java/org/apache/fop/fo/pagination/Flow.java
Index: Flow.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/pagination/Flow.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- Flow.java 12 Jun 2004 23:18:52 -0000 1.10
+++ Flow.java 15 Jun 2004 06:26:56 -0000 1.11
@@ -92,14 +92,14 @@
// Now done in addChild of page-sequence
//pageSequence.addFlow(this);
- getFOTreeControl().getFOInputHandler().startFlow(this);
+ getDocument().getFOInputHandler().startFlow(this);
}
/**
* Tell the StructureRenderer that we are at the end of the flow.
*/
public void end() {
- getFOTreeControl().getFOInputHandler().endFlow(this);
+ getDocument().getFOInputHandler().endFlow(this);
}
/**
1.24 +2 -2 xml-fop/src/java/org/apache/fop/fo/pagination/PageSequence.java
Index: PageSequence.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/pagination/PageSequence.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- PageSequence.java 12 Jun 2004 23:18:52 -0000 1.23
+++ PageSequence.java 15 Jun 2004 06:26:56 -0000 1.24
@@ -291,7 +291,7 @@
*/
private void startStructuredPageSequence() {
if (!sequenceStarted) {
- getFOTreeControl().getFOInputHandler().startPageSequence(this);
+ getDocument().getFOInputHandler().startPageSequence(this);
sequenceStarted = true;
}
}
@@ -303,7 +303,7 @@
*/
public void end() {
try {
- this.getFOTreeControl().getFOInputHandler().endPageSequence(this);
+ this.getDocument().getFOInputHandler().endPageSequence(this);
} catch (FOPException fopex) {
getLogger().error("Error in PageSequence.end(): "
+ fopex.getMessage(), fopex);
1.15 +11 -11 xml-fop/src/java/org/apache/fop/fo/pagination/Root.java
Index: Root.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/pagination/Root.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- Root.java 15 Jun 2004 00:30:43 -0000 1.14
+++ Root.java 15 Jun 2004 06:26:56 -0000 1.15
@@ -22,7 +22,7 @@
import java.util.List;
// FOP
-import org.apache.fop.fo.FOTreeControl;
+import org.apache.fop.apps.Document;
import org.apache.fop.fo.FONode;
import org.apache.fop.fo.FObj;
import org.apache.fop.fo.FOElementMapping;
@@ -47,7 +47,7 @@
*/
private int runningPageNumberCounter = 0;
- private FOTreeControl foTreeControl = null;
+ private Document document = null;
/**
* @see org.apache.fop.fo.FONode#FONode(FONode)
@@ -197,23 +197,23 @@
}
/**
- * Sets the FOTreeControl that this Root is attached to
- * @param foTreeControl the FOTreeControl implementation to which this Root
+ * Sets the Document that this Root is attached to
+ * @param document the apps.Document implementation to which this Root
* is attached
*/
- public void setFOTreeControl(FOTreeControl foTreeControl) {
- this.foTreeControl = foTreeControl;
+ public void setDocument(Document document) {
+ this.document = document;
}
/**
* This method overrides the FONode version. The FONode version calls the
* method by the same name for the parent object. Since Root is at the top
- * of the tree, it returns the actual foTreeControl object. Thus, any FONode
- * can use this chain to find which foTreeControl it is being built for.
- * @return the FOTreeControl implementation that this Root is attached to
+ * of the tree, it returns the actual apps.Document object. Thus, any FONode
+ * can use this chain to find which apps.Document it is being built for.
+ * @return the Document implementation that this Root is attached to
*/
- public FOTreeControl getFOTreeControl() {
- return foTreeControl;
+ public Document getDocument() {
+ return document;
}
/**
1.17 +2 -2 xml-fop/src/java/org/apache/fop/fo/pagination/Title.java
Index: Title.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/pagination/Title.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- Title.java 12 Jun 2004 23:18:53 -0000 1.16
+++ Title.java 15 Jun 2004 06:26:56 -0000 1.17
@@ -59,7 +59,7 @@
CommonBackground bProps = propMgr.getBackgroundProps();
// Common Font Properties
- Font fontState = propMgr.getFontState(getFOTreeControl());
+ Font fontState = propMgr.getFontState(getDocument());
// Common Margin Properties-Inline
CommonMarginInline mProps = propMgr.getMarginInlineProps();
1.21 +1 -1 xml-fop/src/java/org/apache/fop/layoutmgr/BlockLayoutManager.java
Index: BlockLayoutManager.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/layoutmgr/BlockLayoutManager.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- BlockLayoutManager.java 27 May 2004 10:52:33 -0000 1.20
+++ BlockLayoutManager.java 15 Jun 2004 06:26:56 -0000 1.21
@@ -74,7 +74,7 @@
childLMiter = new BlockLMiter(this, childLMiter);
userAgent = inBlock.getUserAgent();
setBlockTextInfo(inBlock.getPropertyManager().getTextLayoutProps(
- inBlock.getFOTreeControl()));
+ inBlock.getDocument()));
}
private void setBlockTextInfo(TextInfo ti) {
1.24 +1 -1 xml-fop/src/java/org/apache/fop/render/awt/AWTRenderer.java
Index: AWTRenderer.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/render/awt/AWTRenderer.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- AWTRenderer.java 12 May 2004 23:19:53 -0000 1.23
+++ AWTRenderer.java 15 Jun 2004 06:26:56 -0000 1.24
@@ -46,6 +46,7 @@
import java.util.Vector;
import org.apache.fop.fonts.FontInfo;
+import org.apache.fop.apps.Document;
import org.apache.fop.apps.FOPException;
import org.apache.fop.apps.InputHandler;
import org.apache.fop.area.Area;
@@ -55,7 +56,6 @@
import org.apache.fop.area.Trait;
import org.apache.fop.area.inline.TextArea;
import org.apache.fop.datatypes.ColorType;
-import org.apache.fop.fo.FOTreeControl;
import org.apache.fop.image.FopImage;
import org.apache.fop.image.ImageFactory;
import org.apache.fop.render.AbstractRenderer;
1.28 +1 -2 xml-fop/src/java/org/apache/fop/render/ps/PSRenderer.java
Index: PSRenderer.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/render/ps/PSRenderer.java,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -r1.27 -r1.28
--- PSRenderer.java 12 May 2004 23:19:53 -0000 1.27
+++ PSRenderer.java 15 Jun 2004 06:26:56 -0000 1.28
@@ -44,7 +44,6 @@
import org.apache.fop.fonts.FontInfo;
import org.apache.fop.render.AbstractRenderer;
import org.apache.fop.render.RendererContext;
-import org.apache.fop.fo.FOTreeControl;
import org.apache.fop.image.FopImage;
import org.apache.fop.image.ImageFactory;
@@ -226,7 +225,7 @@
/**
* Set up the font info
*
- * @param foTreeControl the font info object to set up
+ * @param inFontInfo the font info object to set up
*/
public void setupFontInfo(FontInfo inFontInfo) {
this.fontInfo = inFontInfo;
1.15 +2 -2 xml-fop/src/java/org/apache/fop/render/svg/SVGRenderer.java
Index: SVGRenderer.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/render/svg/SVGRenderer.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- SVGRenderer.java 22 Apr 2004 21:38:40 -0000 1.14
+++ SVGRenderer.java 15 Jun 2004 06:26:56 -0000 1.15
@@ -18,6 +18,7 @@
package org.apache.fop.render.svg;
+import org.apache.fop.apps.Document;
import org.apache.fop.apps.FOPException;
import org.apache.fop.area.PageViewport;
import org.apache.fop.area.Title;
@@ -27,7 +28,6 @@
import org.apache.fop.svg.SVGUtilities;
import org.apache.fop.fonts.FontInfo;
import org.apache.fop.apps.FOUserAgent;
-import org.apache.fop.fo.FOTreeControl;
import org.w3c.dom.Node;
import org.w3c.dom.svg.SVGSVGElement;
@@ -132,7 +132,7 @@
}
/**
- * @see org.apache.fop.render.Renderer#setupFontInfo(FOTreeControl)
+ * @see org.apache.fop.render.Renderer#setupFontInfo(FontInfo)
*/
public void setupFontInfo(FontInfo fontInfo) {
// create a temp Image to test font metrics on
1.22 +0 -1 xml-fop/src/java/org/apache/fop/render/xml/XMLRenderer.java
Index: XMLRenderer.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/render/xml/XMLRenderer.java,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- XMLRenderer.java 18 May 2004 10:12:38 -0000 1.21
+++ XMLRenderer.java 15 Jun 2004 06:26:56 -0000 1.22
@@ -59,7 +59,6 @@
import org.apache.fop.area.inline.TextArea;
import org.apache.fop.fonts.FontSetup;
import org.apache.fop.fonts.FontInfo;
-import org.apache.fop.fo.FOTreeControl;
import org.apache.fop.fo.pagination.Region;
/**
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-cvs-help@xml.apache.org