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 vh...@apache.org on 2008/07/24 11:37:16 UTC
svn commit: r679326 [29/33] - in /xmlgraphics/fop/trunk:
examples/embedding/java/embedding/ examples/embedding/java/embedding/events/
examples/embedding/java/embedding/intermediate/
examples/embedding/java/embedding/model/ examples/embedding/java/embed...
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/servlet/ServletContextURIResolver.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/servlet/ServletContextURIResolver.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/servlet/ServletContextURIResolver.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/servlet/ServletContextURIResolver.java Thu Jul 24 02:35:34 2008
@@ -37,9 +37,9 @@
/** The protocol name for the servlet context URIs. */
public static final String SERVLET_CONTEXT_PROTOCOL = "servlet-context:";
-
+
private ServletContext servletContext;
-
+
/**
* Main constructor
* @param servletContext the servlet context to access the resources through
@@ -47,14 +47,14 @@
public ServletContextURIResolver(ServletContext servletContext) {
this.servletContext = servletContext;
}
-
+
/** {@inheritDoc} */
public Source resolve(String href, String base) throws TransformerException {
if (href.startsWith(SERVLET_CONTEXT_PROTOCOL)) {
return resolveServletContextURI(href.substring(SERVLET_CONTEXT_PROTOCOL.length()));
} else {
- if (base != null
- && base.startsWith(SERVLET_CONTEXT_PROTOCOL)
+ if (base != null
+ && base.startsWith(SERVLET_CONTEXT_PROTOCOL)
&& (href.indexOf(':') < 0)) {
String abs = base + href;
return resolveServletContextURI(
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/ACIUtils.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/ACIUtils.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/ACIUtils.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/ACIUtils.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -44,7 +44,7 @@
Map.Entry entry = (Map.Entry)i.next();
if (entry.getValue() != null) {
System.out.println(entry.getKey() + ": " + entry.getValue());
- }
+ }
}
int start = aci.getBeginIndex();
System.out.print("AttrRuns: ");
@@ -54,7 +54,7 @@
aci.setIndex(end);
if (start == end) {
break;
- }
+ }
start = end;
}
System.out.println("");
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import org.apache.batik.bridge.UserAgent;
@@ -40,7 +40,7 @@
public abstract class AbstractFOPTranscoder extends SVGAbstractTranscoder {
/**
- * The key to specify whether to stroke text instead of using text
+ * The key to specify whether to stroke text instead of using text
* operations.
*/
public static final TranscodingHints.Key KEY_STROKE_TEXT = new BooleanKey();
@@ -69,7 +69,7 @@
hints.put(KEY_DOM_IMPLEMENTATION,
SVGDOMImplementation.getDOMImplementation());
}
-
+
/**
* Creates and returns the default user agent for this transcoder. Override
* this method if you need non-default behaviour.
@@ -78,7 +78,7 @@
protected UserAgent createUserAgent() {
return new FOPTranscoderUserAgent();
}
-
+
/**
* @param logger
*/
@@ -93,9 +93,9 @@
public void setEntityResolver(EntityResolver resolver) {
this.resolver = resolver;
}
-
+
/**
- * Returns the logger associated with this transcoder. It returns a
+ * Returns the logger associated with this transcoder. It returns a
* SimpleLog if no logger has been explicitly set.
* @return Logger the logger for the transcoder.
*/
@@ -106,7 +106,7 @@
}
return this.logger;
}
-
+
/**
* Creates a <tt>DocumentFactory</tt> that is used to create an SVG DOM
* tree. The specified DOM Implementation is ignored and the Batik
@@ -118,7 +118,7 @@
*/
protected DocumentFactory createDocumentFactory(DOMImplementation domImpl,
String parserClassname) {
- final FOPSAXSVGDocumentFactory factory
+ final FOPSAXSVGDocumentFactory factory
= new FOPSAXSVGDocumentFactory(parserClassname);
if (this.resolver != null) {
factory.setAdditionalEntityResolver(this.resolver);
@@ -141,18 +141,18 @@
}
return stroke;
}
-
+
// --------------------------------------------------------------------
// FOP's default error handler (for transcoders)
// --------------------------------------------------------------------
/**
* This is the default transcoder error handler for FOP. It logs error
- * to an Commons Logger instead of to System.out. The remaining behaviour
+ * to an Commons Logger instead of to System.out. The remaining behaviour
* is the same as Batik's DefaultErrorHandler.
- */
+ */
protected class FOPErrorHandler implements ErrorHandler {
-
+
/**
* {@inheritDoc}
*/
@@ -244,5 +244,5 @@
}
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/FOPSAXSVGDocumentFactory.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/FOPSAXSVGDocumentFactory.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/FOPSAXSVGDocumentFactory.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/FOPSAXSVGDocumentFactory.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.io.IOException;
@@ -41,7 +41,7 @@
public FOPSAXSVGDocumentFactory(String parser) {
super(parser);
}
-
+
/**
* Sets an additional entity resolver. It will be used before the default
* entity resolving.
@@ -50,9 +50,9 @@
public void setAdditionalEntityResolver(EntityResolver resolver) {
this.additionalResolver = resolver;
}
-
+
/**
- * {@inheritDoc}
+ * {@inheritDoc}
*/
public InputSource resolveEntity(String publicId, String systemId)
throws SAXException {
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/GraphicsConfiguration.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/GraphicsConfiguration.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/GraphicsConfiguration.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/GraphicsConfiguration.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
@@ -27,8 +27,8 @@
* compilation errors.
* The version for JDK 1.4 needs to add an override for the abstract
* createCompatibleVolatileImage() method. It can't be overidden
- * for JDK 1.3 because there is no VolatileImage there.
- *
+ * for JDK 1.3 because there is no VolatileImage there.
+ *
*/
abstract public class GraphicsConfiguration extends java.awt.GraphicsConfiguration {
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFAElementBridge.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFAElementBridge.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFAElementBridge.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFAElementBridge.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.geom.AffineTransform;
@@ -55,7 +55,7 @@
public AffineTransform getCurrentTransform() {
return this.transform;
}
-
+
/**
* Returns 'a'.
* @return the name of this node
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFANode.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFANode.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFANode.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFANode.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import org.apache.batik.gvt.CompositeGraphicsNode;
@@ -102,7 +102,7 @@
}
}
} catch (Exception e) {
- //TODO Move this to setDestination() and throw an IllegalArgumentException
+ //TODO Move this to setDestination() and throw an IllegalArgumentException
e.printStackTrace();
}
Rectangle2D destRect = new Rectangle2D.Float(x, y, width, height);
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBatikFlowTextElementBridge.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBatikFlowTextElementBridge.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBatikFlowTextElementBridge.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBatikFlowTextElementBridge.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -32,7 +32,7 @@
public class PDFBatikFlowTextElementBridge extends BatikFlowTextElementBridge {
private PDFTextPainter textPainter;
-
+
/**
* Main Constructor.
* @param fontInfo the font directory
@@ -40,7 +40,7 @@
public PDFBatikFlowTextElementBridge(FontInfo fontInfo) {
this.textPainter = new PDFFlowExtTextPainter(fontInfo);
}
-
+
/** {@inheritDoc} */
protected GraphicsNode instantiateGraphicsNode() {
GraphicsNode node = super.instantiateGraphicsNode();
@@ -58,5 +58,5 @@
public TextPainter getTextPainter() {
return this.textPainter;
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBridgeContext.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBridgeContext.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBridgeContext.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFBridgeContext.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -36,7 +36,7 @@
* BridgeContext which registers the custom bridges for PDF output.
*/
public class PDFBridgeContext extends BridgeContext {
-
+
/** The font list. */
private final FontInfo fontInfo;
@@ -44,7 +44,7 @@
private final ImageSessionContext imageSessionContext;
private AffineTransform linkTransform;
-
+
/**
* Constructs a new bridge context.
* @param userAgent the user agent
@@ -75,8 +75,8 @@
* @param linkTransform AffineTransform to properly place links,
* may be null
*/
- public PDFBridgeContext(UserAgent userAgent,
- FontInfo fontInfo,
+ public PDFBridgeContext(UserAgent userAgent,
+ FontInfo fontInfo,
ImageManager imageManager,
ImageSessionContext imageSessionContext,
AffineTransform linkTransform) {
@@ -115,12 +115,12 @@
public ImageSessionContext getImageSessionContext() {
return this.imageSessionContext;
}
-
+
private void putPDFElementBridgeConditional(String className, String testFor) {
try {
Class.forName(testFor);
//if we get here the test class is available
-
+
Class clazz = Class.forName(className);
Constructor constructor = clazz.getConstructor(new Class[] {FontInfo.class});
putBridge((Bridge)constructor.newInstance(new Object[] {fontInfo}));
@@ -128,7 +128,7 @@
//simply ignore (bridges instantiated over this method are optional)
}
}
-
+
/** {@inheritDoc} */
public void registerSVGBridges() {
super.registerSVGBridges();
@@ -136,7 +136,7 @@
if (fontInfo != null) {
PDFTextElementBridge textElementBridge = new PDFTextElementBridge(fontInfo);
putBridge(textElementBridge);
-
+
//Batik flow text extension (may not always be available)
//putBridge(new PDFBatikFlowTextElementBridge(fontInfo);
putPDFElementBridgeConditional(
@@ -148,7 +148,7 @@
putPDFElementBridgeConditional(
"org.apache.fop.svg.PDFSVG12TextElementBridge",
"org.apache.batik.bridge.svg12.SVG12TextElementBridge");
-
+
//putBridge(new PDFSVGFlowRootElementBridge(fontInfo));
putPDFElementBridgeConditional(
"org.apache.fop.svg.PDFSVGFlowRootElementBridge",
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFContext.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFContext.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFContext.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFContext.java Thu Jul 24 02:35:34 2008
@@ -31,7 +31,7 @@
/** number of pages generated */
private int pagecount;
-
+
/** @return true if a page is set up for painting. */
public boolean isPagePending() {
return this.currentPage != null;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2DConfigurator.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2DConfigurator.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2DConfigurator.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2DConfigurator.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowExtTextPainter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowExtTextPainter.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowExtTextPainter.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowExtTextPainter.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -45,5 +45,5 @@
FlowExtTextPainter delegate = (FlowExtTextPainter)FlowExtTextPainter.getInstance();
return delegate.getTextRuns(node, aci);
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowTextPainter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowTextPainter.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowTextPainter.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFFlowTextPainter.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -30,7 +30,7 @@
* Text Painter for SVG 1.2 (flow) text.
*/
public class PDFFlowTextPainter extends PDFTextPainter {
-
+
/**
* Main constructor
* @param fontInfo the font directory
@@ -45,5 +45,5 @@
FlowTextPainter delegate = (FlowTextPainter)FlowTextPainter.getInstance();
return delegate.getTextRuns(node, aci);
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphics2D.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphics2D.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphics2D.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphics2D.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsConfiguration.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsConfiguration.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsConfiguration.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsConfiguration.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.Rectangle;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsDevice.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsDevice.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsDevice.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFGraphicsDevice.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.GraphicsDevice;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFImageElementBridge.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFImageElementBridge.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFImageElementBridge.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFImageElementBridge.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.Graphics2D;
@@ -72,13 +72,13 @@
protected GraphicsNode createImageGraphicsNode
(BridgeContext ctx, Element imageElement, ParsedURL purl) {
PDFBridgeContext pdfCtx = (PDFBridgeContext)ctx;
-
+
ImageManager manager = pdfCtx.getImageManager();
ImageSessionContext sessionContext = pdfCtx.getImageSessionContext();
try {
ImageInfo info = manager.getImageInfo(purl.toString(), sessionContext);
Image image = manager.getImage(info, supportedFlavors, sessionContext);
-
+
//TODO color profile overrides aren't handled, yet!
//ICCColorSpaceExt colorspaceOverride = extractColorSpace(e, ctx);
AbstractGraphicsNode specializedNode = null;
@@ -104,7 +104,7 @@
ctx.getUserAgent().displayError(
new ImageException("Cannot convert an image to a usable format: " + purl));
}
-
+
Rectangle2D imgBounds = getImageBounds(ctx, imageElement);
Rectangle2D bounds = specializedNode.getPrimitiveBounds();
float [] vb = new float[4];
@@ -113,14 +113,14 @@
vb[2] = (float) bounds.getWidth(); // width
vb[3] = (float) bounds.getHeight(); // height
- // handles the 'preserveAspectRatio', 'overflow' and 'clip'
+ // handles the 'preserveAspectRatio', 'overflow' and 'clip'
// and sets the appropriate AffineTransform to the image node
initializeViewport(ctx, imageElement, specializedNode, vb, imgBounds);
return specializedNode;
} catch (Exception e) {
ctx.getUserAgent().displayError(e);
}
-
+
return superCreateGraphicsNode(ctx, imageElement, purl);
}
@@ -144,13 +144,13 @@
* the PDFGraphics2D.
*/
public class LoaderImageNode extends AbstractGraphicsNode {
-
+
private Image image;
private BridgeContext ctx;
private Element imageElement;
private ParsedURL purl;
private GraphicsNode origGraphicsNode = null;
-
+
/**
* Create a new image node for drawing natively handled images
* into PDF graphics.
@@ -159,7 +159,7 @@
* @param imageElement the SVG image element
* @param purl the URL to the image
*/
- public LoaderImageNode(Image image, BridgeContext ctx,
+ public LoaderImageNode(Image image, BridgeContext ctx,
Element imageElement, ParsedURL purl) {
this.image = image;
this.ctx = ctx;
@@ -191,7 +191,7 @@
if (origGraphicsNode == null) {
// Haven't constructed baseclass Graphics Node,
// so do so now.
- origGraphicsNode
+ origGraphicsNode
= PDFImageElementBridge.this.superCreateGraphicsNode
(ctx, imageElement, purl);
}
@@ -223,9 +223,9 @@
* A node that holds a Graphics2D image.
*/
public class Graphics2DNode extends AbstractGraphicsNode {
-
+
private ImageGraphics2D image;
-
+
/**
* Create a new Graphics2D node.
* @param g2d the Graphics2D image
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFSVGFlowRootElementBridge.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFSVGFlowRootElementBridge.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFSVGFlowRootElementBridge.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFSVGFlowRootElementBridge.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -32,7 +32,7 @@
public class PDFSVGFlowRootElementBridge extends SVGFlowRootElementBridge {
private PDFTextPainter textPainter;
-
+
/**
* Main Constructor.
* @param fontInfo the font directory
@@ -40,7 +40,7 @@
public PDFSVGFlowRootElementBridge(FontInfo fontInfo) {
this.textPainter = new PDFFlowTextPainter(fontInfo);
}
-
+
/** {@inheritDoc} */
protected GraphicsNode instantiateGraphicsNode() {
GraphicsNode node = super.instantiateGraphicsNode();
@@ -58,5 +58,5 @@
public TextPainter getTextPainter() {
return this.textPainter;
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextElementBridge.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextElementBridge.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextElementBridge.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextElementBridge.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -35,7 +35,7 @@
* @author <a href="mailto:keiron@aftexsw.com">Keiron Liddle</a>
*/
public class PDFTextElementBridge extends SVGTextElementBridge {
-
+
private PDFTextPainter pdfTextPainter;
/**
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextPainter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextPainter.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextPainter.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextPainter.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -62,7 +62,7 @@
public class PDFTextPainter extends StrokingTextPainter {
private static final boolean DEBUG = false;
-
+
private boolean strokeText = false;
private FontInfo fontInfo;
@@ -102,7 +102,7 @@
if ((tpi != null) && (tpi.composite != null)) {
g2d.setComposite(tpi.composite);
}
-
+
//------------------------------------
TextSpanLayout layout = textRun.getLayout();
if (DEBUG) {
@@ -110,7 +110,7 @@
System.out.println("================================================");
System.out.println("New text run:");
System.out.println("char count: " + charCount);
- System.out.println("range: "
+ System.out.println("range: "
+ runaci.getBeginIndex() + " - " + runaci.getEndIndex());
System.out.println("glyph count: " + layout.getGlyphCount()); //=getNumGlyphs()
}
@@ -125,26 +125,26 @@
System.out.println("Text: " + chars);
pdf.currentStream.write("%Text: " + chars + "\n");
}
-
+
GeneralPath debugShapes = null;
if (DEBUG) {
debugShapes = new GeneralPath();
}
-
+
Font[] fonts = findFonts(runaci);
if (fonts == null || fonts.length == 0) {
//Draw using Java2D
textRun.getLayout().draw(g2d);
continue;
}
-
+
textUtil.saveGraphicsState();
textUtil.concatMatrix(g2d.getTransform());
Shape imclip = g2d.getClip();
pdf.writeClip(imclip);
-
+
applyColorAndPaint(tpi, pdf);
-
+
textUtil.beginTextObject();
textUtil.setFonts(fonts);
textUtil.setTextRenderingMode(tpi.fillPaint != null, tpi.strokePaint != null, false);
@@ -158,7 +158,7 @@
boolean visibleChar = gv.isGlyphVisible(index)
|| (CharUtilities.isAnySpace(ch) && !CharUtilities.isZeroWidthSpace(ch));
if (DEBUG) {
- System.out.println("glyph " + index
+ System.out.println("glyph " + index
+ " -> " + layout.getGlyphIndex(index) + " => " + ch);
if (CharUtilities.isAnySpace(ch) && ch != 32) {
System.out.println("Space found: " + Integer.toHexString(ch));
@@ -198,9 +198,9 @@
localTransform.concatenate(glyphTransform);
}
localTransform.scale(1, -1);
-
- boolean yPosChanged = (prevPos == null
- || prevPos.getY() != p.getY()
+
+ boolean yPosChanged = (prevPos == null
+ || prevPos.getY() != p.getY()
|| glyphTransform != null);
if (yPosChanged) {
if (index > 0) {
@@ -218,7 +218,7 @@
textUtil.adjustGlyphTJ(adjust * 1000);
}
if (DEBUG) {
- System.out.println("==> x diff: " + xdiff + ", " + effxdiff
+ System.out.println("==> x diff: " + xdiff + ", " + effxdiff
+ ", charWidth: " + cw);
}
}
@@ -231,7 +231,7 @@
}
char paintChar = (CharUtilities.isAnySpace(ch) ? ' ' : ch);
textUtil.writeTJChar(paintChar);
-
+
//Update last position
prevPos = p;
prevVisibleCharWidth = textUtil.getCurrentFont().getCharWidth(chars.charAt(index));
@@ -268,7 +268,7 @@
}
pdf.applyAlpha(fillAlpha, PDFGraphics2D.OPAQUE);
}
-
+
private Font[] findFonts(AttributedCharacterIterator aci) {
List fonts = new java.util.ArrayList();
List gvtFonts = (List) aci.getAttribute(
@@ -343,5 +343,5 @@
}
return (Font[])fonts.toArray(new Font[fonts.size()]);
}
-
+
}
\ No newline at end of file
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextUtil.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextUtil.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextUtil.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTextUtil.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -32,7 +32,7 @@
private FontInfo fontInfo;
private Font[] fonts;
private Font font;
-
+
/**
* Main constructor.
* @param fontInfo the font catalog
@@ -41,13 +41,13 @@
super();
this.fontInfo = fontInfo;
}
-
+
/** {@inheritDoc} */
protected void initValues() {
super.initValues();
this.font = null;
}
-
+
/**
* Sets the current fonts for the text object. For every character, the suitable font will
* be selected.
@@ -56,7 +56,7 @@
public void setFonts(Font[] fonts) {
this.fonts = fonts;
}
-
+
/**
* Sets the current font for the text object.
* @param font the new font
@@ -64,7 +64,7 @@
public void setFont(Font font) {
setFonts(new Font[] {font});
}
-
+
/**
* Returns the current font in use.
* @return the current font or null if no font is currently active.
@@ -72,7 +72,7 @@
public Font getCurrentFont() {
return this.font;
}
-
+
/**
* Sets the current font.
* @param f the new font to use
@@ -80,7 +80,7 @@
public void setCurrentFont(Font f) {
this.font = f;
}
-
+
/**
* Determines whether the font with the given name is a multi-byte font.
* @param name the name of the font
@@ -114,7 +114,7 @@
}
return fonts[0]; //TODO Maybe fall back to painting with shapes
}
-
+
/**
* Writes a char to the "TJ-Buffer".
* @param ch the unmapped character
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTranscoder.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTranscoder.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTranscoder.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFTranscoder.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -78,7 +78,7 @@
* <tt>KEY_USER_STYLESHEET_URI</tt> to fix the URI of a user
* stylesheet, and <tt>KEY_PIXEL_TO_MM</tt> to specify the pixel to
* millimeter conversion factor.
- *
+ *
* <p><tt>KEY_AUTO_FONTS</tt> to disable the auto-detection of fonts installed in the system.
* The PDF Transcoder cannot use AWT's font subsystem and that's why the fonts have to be
* configured differently. By default, font auto-detection is enabled to match the behaviour
@@ -93,25 +93,25 @@
/**
* The key is used to specify the resolution for on-the-fly images generated
- * due to complex effects like gradients and filters.
+ * due to complex effects like gradients and filters.
*/
public static final TranscodingHints.Key KEY_DEVICE_RESOLUTION = new FloatKey();
/**
* The key is used to specify whether the available fonts should be automatically
* detected. The alternative is to configure the transcoder manually using a configuration
- * file.
+ * file.
*/
public static final TranscodingHints.Key KEY_AUTO_FONTS = new BooleanKey();
private Configuration cfg = null;
-
+
/** Graphics2D instance that is used to paint to */
protected PDFDocumentGraphics2D graphics = null;
private ImageManager imageManager;
private ImageSessionContext imageSessionContext;
-
+
/**
* Constructs a new <tt>PDFTranscoder</tt>.
*/
@@ -132,7 +132,7 @@
}
};
}
-
+
/** {@inheritDoc} */
public void configure(Configuration cfg) throws ConfigurationException {
this.cfg = cfg;
@@ -147,21 +147,21 @@
* @exception TranscoderException if an error occured while transcoding
*/
protected void transcode(Document document, String uri,
- TranscoderOutput output)
+ TranscoderOutput output)
throws TranscoderException {
graphics = new PDFDocumentGraphics2D(isTextStroked());
- graphics.getPDFDocument().getInfo().setProducer("Apache FOP Version "
- + Version.getVersion()
+ graphics.getPDFDocument().getInfo().setProducer("Apache FOP Version "
+ + Version.getVersion()
+ ": PDF Transcoder for Batik");
if (hints.containsKey(KEY_DEVICE_RESOLUTION)) {
graphics.setDeviceDPI(((Float)hints.get(KEY_DEVICE_RESOLUTION)).floatValue());
}
-
+
setupImageInfrastructure(uri);
-
+
try {
- Configuration effCfg = this.cfg;
+ Configuration effCfg = this.cfg;
if (effCfg == null) {
//By default, enable font auto-detection if no cfg is given
boolean autoFonts = true;
@@ -177,7 +177,7 @@
effCfg = c;
}
}
-
+
if (effCfg != null) {
PDFDocumentGraphics2DConfigurator configurator
= new PDFDocumentGraphics2DConfigurator();
@@ -195,14 +195,14 @@
if (getLogger().isTraceEnabled()) {
getLogger().trace("document size: " + width + " x " + height);
}
-
+
// prepare the image to be painted
- UnitProcessor.Context uctx = UnitProcessor.createContext(ctx,
+ UnitProcessor.Context uctx = UnitProcessor.createContext(ctx,
document.getDocumentElement());
- float widthInPt = UnitProcessor.userSpaceToSVG(width, SVGLength.SVG_LENGTHTYPE_PT,
+ float widthInPt = UnitProcessor.userSpaceToSVG(width, SVGLength.SVG_LENGTHTYPE_PT,
UnitProcessor.HORIZONTAL_LENGTH, uctx);
int w = (int)(widthInPt + 0.5);
- float heightInPt = UnitProcessor.userSpaceToSVG(height, SVGLength.SVG_LENGTHTYPE_PT,
+ float heightInPt = UnitProcessor.userSpaceToSVG(height, SVGLength.SVG_LENGTHTYPE_PT,
UnitProcessor.HORIZONTAL_LENGTH, uctx);
int h = (int)(heightInPt + 0.5);
if (getLogger().isTraceEnabled()) {
@@ -271,7 +271,7 @@
return null;
}
}
-
+
};
}
@@ -291,5 +291,5 @@
this.imageManager, this.imageSessionContext);
return ctx;
}
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGEventProducer.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGEventProducer.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGEventProducer.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGEventProducer.java Thu Jul 24 02:35:34 2008
@@ -31,7 +31,7 @@
* Provider class for the event producer.
*/
class Provider {
-
+
/**
* Returns an event producer.
* @param broadcaster the event broadcaster to use
@@ -51,7 +51,7 @@
* @event.severity ERROR
*/
void error(Object source, String message, Exception e);
-
+
/**
* Alert during SVG processing.
* @param source the event source
@@ -59,7 +59,7 @@
* @event.severity WARN
*/
void alert(Object source, String message);
-
+
/**
* Info during SVG processing.
* @param source the event source
@@ -67,7 +67,7 @@
* @event.severity INFO
*/
void info(Object source, String message);
-
+
/**
* SVG graphic could not be built due to an exception.
* @param source the event source
@@ -76,7 +76,7 @@
* @event.severity ERROR
*/
void svgNotBuilt(Object source, Exception e, String uri);
-
+
/**
* SVG graphic could not be rendered due to an exception.
* @param source the event source
@@ -85,5 +85,5 @@
* @event.severity ERROR
*/
void svgRenderingError(Object source, Exception e, String uri);
-
+
}
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUserAgent.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUserAgent.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUserAgent.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUserAgent.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.geom.AffineTransform;
@@ -27,7 +27,7 @@
* The SVG user agent. This is an implementation of the Batik SVG user agent.
*/
public class SVGUserAgent extends SimpleSVGUserAgent {
-
+
private SVGEventProducer eventProducer;
private Exception lastException;
@@ -48,7 +48,7 @@
public SVGUserAgent(FOUserAgent foUserAgent) {
this(foUserAgent, new AffineTransform());
}
-
+
/**
* Returns the last exception sent to the {@link #displayError(Exception)} method.
* @return the last exception or null if no exception occurred
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUtilities.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUtilities.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUtilities.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SVGUtilities.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SimpleSVGUserAgent.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SimpleSVGUserAgent.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SimpleSVGUserAgent.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/SimpleSVGUserAgent.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.svg;
import java.awt.Dimension;
@@ -33,7 +33,7 @@
* by Batik.
*/
public class SimpleSVGUserAgent extends UserAgentAdapter {
-
+
private AffineTransform currentTransform = null;
private float pixelUnitToMillimeter = 0.0f;
@@ -46,7 +46,7 @@
pixelUnitToMillimeter = pixelUnitToMM;
currentTransform = at;
}
-
+
/**
* Returns a customized the pixel to mm factor.
* @return the pixel unit to millimeter conversion factor
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakStatus.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakStatus.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakStatus.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakStatus.java Thu Jul 24 02:35:34 2008
@@ -1,13 +1,13 @@
-/*
+/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -48,8 +48,8 @@
public LineBreakStatus() {
reset();
}
-
-
+
+
/**
* Reset the status.
* This method will reset the status to the initial state. It is meant
@@ -63,44 +63,44 @@
/**
* Check whether a line break may happen according to the rules described in
* the <a href="http://unicode.org/reports/tr14/#Algorithm">Unicode Line Breaking Algorithm</a>.
- * The function returns the line breaking status of the point <em>before</em> the given character.
- * The algorithm is the table-driven algorithm, as described in
+ * The function returns the line breaking status of the point <em>before</em> the given character.
+ * The algorithm is the table-driven algorithm, as described in
* <a href="http://unicode.org/reports/tr14/#PairBasedImplementation">
* Unicode Technical Report #14</a>.
* The pair table is taken from {@link LineBreakUtils}.
- *
+ *
* TODO: Better handling for AI, SA, SG and XX line break classes.
- *
+ *
* @param c the character to check
* @return the break action to be taken
- * one of: {@link #DIRECT_BREAK},
- * {@link #INDIRECT_BREAK},
- * {@link #COMBINING_INDIRECT_BREAK},
+ * one of: {@link #DIRECT_BREAK},
+ * {@link #INDIRECT_BREAK},
+ * {@link #COMBINING_INDIRECT_BREAK},
* {@link #COMBINING_PROHIBITED_BREAK},
* {@link #PROHIBITED_BREAK},
* {@link #EXPLICIT_BREAK}
*/
public byte nextChar(char c) {
-
+
byte currentClass = LineBreakUtils.getLineBreakProperty(c);
-
+
/* Initial conversions */
switch (currentClass) {
case LineBreakUtils.LINE_BREAK_PROPERTY_AI:
case LineBreakUtils.LINE_BREAK_PROPERTY_SG:
case LineBreakUtils.LINE_BREAK_PROPERTY_XX:
- // LB 1: Resolve AI, ... SG and XX into other line breaking classes
+ // LB 1: Resolve AI, ... SG and XX into other line breaking classes
// depending on criteria outside the scope of this algorithm.
- // In the absence of such criteria, it is recommended that
+ // In the absence of such criteria, it is recommended that
// classes AI, ... SG and XX be resolved to AL
currentClass = LineBreakUtils.LINE_BREAK_PROPERTY_AL;
break;
-
+
case LineBreakUtils.LINE_BREAK_PROPERTY_SA:
- // LB 1: Resolve ... SA ... into other line breaking classes
+ // LB 1: Resolve ... SA ... into other line breaking classes
// depending on criteria outside the scope of this algorithm.
- // In the absence of such criteria, it is recommended that
- // ... SA be resolved to AL, except that characters of
+ // In the absence of such criteria, it is recommended that
+ // ... SA be resolved to AL, except that characters of
// class SA that have General_Category Mn or Mc be resolved to CM
switch (Character.getType(c)) {
case Character.COMBINING_SPACING_MARK: //General_Category "Mc"
@@ -110,11 +110,11 @@
default:
currentClass = LineBreakUtils.LINE_BREAK_PROPERTY_AL;
}
-
+
default:
//nop
}
-
+
/* Check 1: First character or initial character after a reset/mandatory break? */
switch (leftClass) {
case -1:
@@ -126,7 +126,7 @@
}
// LB 2: Never break at the start of text
return PROHIBITED_BREAK;
-
+
case LineBreakUtils.LINE_BREAK_PROPERTY_BK:
case LineBreakUtils.LINE_BREAK_PROPERTY_LF:
case LineBreakUtils.LINE_BREAK_PROPERTY_NL:
@@ -136,9 +136,9 @@
reset();
leftClass = currentClass;
return EXPLICIT_BREAK;
-
+
case LineBreakUtils.LINE_BREAK_PROPERTY_CR:
- //first character after a carriage return:
+ //first character after a carriage return:
// LB 5: Treat CR followed by LF, as well as CR ... as hard line breaks
// If current is LF, then fall through to Check 2 (see below),
// and the hard break will be signaled for the character after LF (see above)
@@ -147,11 +147,11 @@
leftClass = currentClass;
return EXPLICIT_BREAK;
}
-
+
default:
//nop
}
-
+
/* Check 2: current is a mandatory break or space? */
switch (currentClass) {
case LineBreakUtils.LINE_BREAK_PROPERTY_BK:
@@ -161,17 +161,17 @@
// LB 6: Do not break before a hard break
leftClass = currentClass;
return PROHIBITED_BREAK;
-
+
case LineBreakUtils.LINE_BREAK_PROPERTY_SP:
// LB 7: Do not break before spaces ...
// Zero-width spaces are in the pair-table (see below)
hadSpace = true;
return PROHIBITED_BREAK;
-
+
default:
//nop
}
-
+
/* Normal treatment, if the first two checks did not return */
boolean savedHadSpace = hadSpace;
hadSpace = false;
@@ -181,7 +181,7 @@
case DIRECT_BREAK:
leftClass = currentClass;
return breakAction;
-
+
case INDIRECT_BREAK:
leftClass = currentClass;
if (savedHadSpace) {
@@ -189,7 +189,7 @@
} else {
return PROHIBITED_BREAK;
}
-
+
case COMBINING_INDIRECT_BREAK:
if (savedHadSpace) {
leftClass = currentClass;
@@ -197,19 +197,19 @@
} else {
return PROHIBITED_BREAK;
}
-
+
case COMBINING_PROHIBITED_BREAK:
if (savedHadSpace) {
leftClass = currentClass;
}
return COMBINING_PROHIBITED_BREAK;
-
+
default:
assert false;
return breakAction;
}
}
-
+
/**
* for debugging only
*/
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakUtils.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakUtils.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakUtils.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/text/linebreak/LineBreakUtils.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -19,10 +19,10 @@
package org.apache.fop.text.linebreak;
-/*
- * !!! THIS IS A GENERATED FILE !!!
+/*
+ * !!! THIS IS A GENERATED FILE !!!
* If updates to the source are needed, then:
- * - apply the necessary modifications to
+ * - apply the necessary modifications to
* 'src/codegen/unicode/java/org/apache/fop/text/linebreak/GenerateLineBreakUtils.java'
* - run 'ant codegen-unicode', which will generate a new LineBreakUtils.java
* in 'src/java/org/apache/fop/text/linebreak'
@@ -45,41 +45,41 @@
public static final byte EXPLICIT_BREAK = 5;
private static final byte PAIR_TABLE[][] = {
- {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
- {0, 1, 0, 1, 0, 0, 0, 4, 2, 0, 4, 1, 0, 0, 1, 0, 1, 4, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 4, 4, 0, 4},
- {0, 0, 4, 1, 0, 0, 0, 4, 2, 0, 4, 1, 0, 0, 1, 0, 0, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 4, 4, 0, 4},
- {0, 0, 0, 1, 0, 0, 0, 4, 2, 0, 4, 1, 0, 0, 1, 0, 0, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 4, 4, 0, 4},
- {0, 1, 1, 1, 1, 0, 0, 4, 2, 0, 4, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 4, 4, 0, 4},
- {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
- {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
- {0, 1, 0, 1, 0, 0, 0, 4, 2, 0, 4, 1, 0, 0, 1, 0, 0, 4, 0,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 1, 0, 0, 4, 2, 0, 4, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 0, 0, 1, 1, 4, 1, 1, 1, 0, 0, 0, 4, 4, 0, 4},
+ {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
+ {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
+ {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
+ {0, 0, 0, 1, 0, 0, 0, 4, 2, 0, 4, 1, 0, 0, 1, 0, 0, 4, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 4, 4, 0, 4},
+ {0, 1, 1, 1, 1, 0, 0, 4, 2, 0, 4, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 4, 4, 0, 4},
+ {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4}};
private static byte lineBreakProperties[][] = new byte[512][];
@@ -680,8 +680,8 @@
/** Linebreak property constant */
public static final byte LINE_BREAK_PROPERTY_ZW = 36;
- private static String lineBreakPropertyShortNames[] = {"AI", "AL", "B2", "BA", "BB", "BK", "CB", "CL", "CM", "CR", "EX",
- "GL", "H2", "H3", "HY", "ID", "IN", "IS", "JL", "JT", "JV", "LF", "NL", "NS", "NU", "OP", "PO", "PR", "QU", "SA", "SG", "SP",
+ private static String lineBreakPropertyShortNames[] = {"AI", "AL", "B2", "BA", "BB", "BK", "CB", "CL", "CM", "CR", "EX",
+ "GL", "H2", "H3", "HY", "ID", "IN", "IS", "JL", "JT", "JV", "LF", "NL", "NS", "NU", "OP", "PO", "PR", "QU", "SA", "SG", "SP",
"SY", "WJ", "XX", "ZW"};
private static String lineBreakPropertyLongNames[] = {"Ambiguous","Alphabetic","Break_Both","Break_After","Break_Before",
@@ -691,7 +691,7 @@
"Surrogate","Space","Break_Symbols","Word_Joiner","Unknown","ZWSpace"};
/**
- * Return the short name for the linebreak property corresponding
+ * Return the short name for the linebreak property corresponding
* to the given symbolic constant.
*
* @param i the numeric value of the linebreak property
@@ -706,7 +706,7 @@
}
/**
- * Return the long name for the linebreak property corresponding
+ * Return the long name for the linebreak property corresponding
* to the given symbolic constant.
*
* @param i the numeric value of the linebreak property
@@ -731,7 +731,7 @@
}
/**
- * Return the break class constant for the given pair of linebreak
+ * Return the break class constant for the given pair of linebreak
* property constants.
*
* @param lineBreakPropertyBefore the linebreak property for the first character
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/TestConverter.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/TestConverter.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/TestConverter.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/TestConverter.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.tools;
import java.io.File;
@@ -48,10 +48,10 @@
* pdf rendering.
*/
public class TestConverter {
-
+
// configure fopFactory as desired
private FopFactory fopFactory = FopFactory.newInstance();
-
+
private boolean failOnly = false;
private String outputFormat = MimeConstants.MIME_FOP_AREA_TREE;
private File destdir;
@@ -126,7 +126,7 @@
}
/**
- * Controls whether to process only the tests which are specified as fail
+ * Controls whether to process only the tests which are specified as fail
* in the test results.
* @param fail True if only fail tests should be processed
*/
@@ -262,7 +262,7 @@
if (xslNode != null) {
xsl = xslNode.getNodeValue();
}
- logger.debug("converting xml:" + xml + " and xsl:"
+ logger.debug("converting xml:" + xml + " and xsl:"
+ xsl + " to area tree");
String res = xml;
@@ -299,7 +299,7 @@
if (outname.endsWith(".xml") || outname.endsWith(".pdf")) {
outname = outname.substring(0, outname.length() - 4);
}
- File outputFile = new File(destdir,
+ File outputFile = new File(destdir,
outname + makeResultExtension());
outputFile.getParentFile().mkdirs();
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/FileCompare.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/FileCompare.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/FileCompare.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/FileCompare.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.tools.anttasks;
import java.util.Date;
@@ -37,7 +37,7 @@
*/
public class FileCompare {
-
+
private String referenceDirectory, testDirectory;
private String[] filenameList;
private String filenames;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/RunTest.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/RunTest.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/RunTest.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/RunTest.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.tools.anttasks;
// Ant
@@ -42,7 +42,7 @@
* to run the tests and check the results.
*/
public class RunTest extends Task {
-
+
private String basedir;
private String testsuite = "";
private String referenceJar = "";
@@ -218,7 +218,7 @@
}
/**
- * Return a list of URL's with the specified URL first and followed
+ * Return a list of URL's with the specified URL first and followed
* by all the jar files from lib/.
* @return a list of urls to the runtime jar files.
*/
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/SerializeHyphPattern.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/SerializeHyphPattern.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/SerializeHyphPattern.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/tools/anttasks/SerializeHyphPattern.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.tools.anttasks;
// Java
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BlockProps.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BlockProps.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BlockProps.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BlockProps.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.traits;
import org.apache.fop.datatypes.Length;
@@ -26,7 +26,7 @@
* Public "structure" allows direct member access.
*/
public class BlockProps {
-
+
public Length firstIndent; // text-indent
public int lastIndent; // last-line-indent
public int textAlign;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BorderProps.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BorderProps.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BorderProps.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/BorderProps.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.traits;
import java.awt.Color;
@@ -33,14 +33,14 @@
* Class to store border trait propties for the area tree.
*/
public class BorderProps implements Serializable {
-
+
/** Separate border model */
public static final int SEPARATE = 0;
/** Collapsing border model, for borders inside a table */
public static final int COLLAPSE_INNER = 1;
/** Collapsing border model, for borders at the table's outer border */
public static final int COLLAPSE_OUTER = 2;
-
+
/** Border style (one of EN_*) */
public int style; // Enum for border style
/** Border color */
@@ -86,7 +86,7 @@
return 0;
}
}
-
+
private String getStyleString() {
switch (style) {
case Constants.EN_NONE: return "none";
@@ -102,7 +102,7 @@
default: throw new IllegalStateException("Illegal border style: " + style);
}
}
-
+
private static int getConstantForStyle(String style) {
if ("none".equalsIgnoreCase(style)) {
return Constants.EN_NONE;
@@ -128,7 +128,7 @@
throw new IllegalStateException("Illegal border style: " + style);
}
}
-
+
/** {@inheritDoc} */
public int hashCode() {
return toString().hashCode();
@@ -144,7 +144,7 @@
if (obj instanceof BorderProps) {
BorderProps other = (BorderProps)obj;
return (style == other.style)
- && color.equals(other.color)
+ && color.equals(other.color)
&& width == other.width
&& mode == other.mode;
}
@@ -153,7 +153,7 @@
}
/**
- * Returns a BorderProps represtation of a string of the format as written by
+ * Returns a BorderProps represtation of a string of the format as written by
* BorderProps.toString().
* @param foUserAgent FOP user agent caching ICC profiles
* @param s the string
@@ -180,8 +180,8 @@
c = ColorUtil.parseColorString(foUserAgent, color);
} catch (PropertyException e) {
throw new IllegalArgumentException(e.getMessage());
- }
-
+ }
+
return new BorderProps(style, width, c, mode);
} else {
throw new IllegalArgumentException("BorderProps must be surrounded by parentheses");
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/InlineProps.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/InlineProps.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/InlineProps.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/InlineProps.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.traits;
/**
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/LayoutProps.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/LayoutProps.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/LayoutProps.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/LayoutProps.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.traits;
import org.apache.fop.datatypes.KeepValue;
Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/MinOptMax.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/MinOptMax.java?rev=679326&r1=679325&r2=679326&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/MinOptMax.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/traits/MinOptMax.java Thu Jul 24 02:35:34 2008
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,7 +16,7 @@
*/
/* $Id$ */
-
+
package org.apache.fop.traits;
/**
@@ -163,7 +163,7 @@
opt -= op.opt;
max -= op.min;
}
-
+
/** @return true if this instance represents a zero-width length (min=opt=max=0) */
public boolean isNonZero() {
return (min != 0 || max != 0);
@@ -173,7 +173,7 @@
public boolean isElastic() {
return (min != opt || opt != max);
}
-
+
/** {@inheritDoc} */
public String toString() {
StringBuffer sb = new StringBuffer();
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-commits-help@xmlgraphics.apache.org