greenrd 01/03/25 16:17:12
Modified: . changes.xml
src/org/apache/cocoon cocoon.properties
src/org/apache/cocoon/formatter FO2PDFFormatter.java
Log:
backing out stupid change to fop driver
Revision Changes Path
1.224 +1 -4 xml-cocoon/changes.xml
Index: changes.xml
===================================================================
RCS file: /home/cvs/xml-cocoon/changes.xml,v
retrieving revision 1.223
retrieving revision 1.224
diff -u -r1.223 -r1.224
--- changes.xml 2001/03/25 16:23:22 1.223
+++ changes.xml 2001/03/26 00:17:10 1.224
@@ -4,7 +4,7 @@
<!--
History of Cocoon changes
- $Id: changes.xml,v 1.223 2001/03/25 16:23:22 greenrd Exp $
+ $Id: changes.xml,v 1.224 2001/03/26 00:17:10 greenrd Exp $
-->
<changes title="History of Changes">
@@ -18,9 +18,6 @@
</devs>
<release version="@version@" date="@date@">
- <action dev="RDG" type="fix">
- Workaround for encoding in FOP > 0.15
- </action>
<action dev="RDG" type="fix" due-to="Krzysztof Zielinski"
due-to-email="[EMAIL PROTECTED]">
Non-default encodings in logicsheets should now work.
1.55 +0 -4 xml-cocoon/src/org/apache/cocoon/cocoon.properties
Index: cocoon.properties
===================================================================
RCS file: /home/cvs/xml-cocoon/src/org/apache/cocoon/cocoon.properties,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -r1.54 -r1.55
--- cocoon.properties 2001/03/25 16:30:31 1.54
+++ cocoon.properties 2001/03/26 00:17:10 1.55
@@ -278,10 +278,6 @@
formatter.text/xhtml.doctype-public = -//W3C//DTD XHTML 1.0 Strict//EN
formatter.text/xhtml.doctype-system = xhtml1-strict.dtd
-# FOP
-# Try changing this to true if you have problems with encoding
-formatter.text/xslfo.encoding.hack = false
-
# WML 1.1
formatter.text/wml.doctype-public = -//WAPFORUM//DTD WML 1.1//EN
formatter.text/wml.doctype-system = http://www.wapforum.org/DTD/wml_1.1.xml
1.14 +4 -19
xml-cocoon/src/org/apache/cocoon/formatter/FO2PDFFormatter.java
Index: FO2PDFFormatter.java
===================================================================
RCS file:
/home/cvs/xml-cocoon/src/org/apache/cocoon/formatter/FO2PDFFormatter.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- FO2PDFFormatter.java 2001/03/25 16:32:00 1.13
+++ FO2PDFFormatter.java 2001/03/26 00:17:11 1.14
@@ -1,4 +1,4 @@
-/*-- $Id: FO2PDFFormatter.java,v 1.13 2001/03/25 16:32:00 greenrd Exp $ --
+/*-- $Id: FO2PDFFormatter.java,v 1.14 2001/03/26 00:17:11 greenrd Exp $ --
============================================================================
The Apache Software License, Version 1.1
@@ -65,7 +65,7 @@
*
* @author <a href="mailto:[EMAIL PROTECTED]">Stefano Mazzocchi</a>
* @author <a href="mailto:[EMAIL PROTECTED]">Robin Green</a>
- * @version $Revision: 1.13 $ $Date: 2001/03/25 16:32:00 $
+ * @version $Revision: 1.14 $ $Date: 2001/03/26 00:17:11 $
*/
public class FO2PDFFormatter extends AbstractFormatter implements Actor {
@@ -106,8 +106,6 @@
protected Formatter xmlFormatter;
protected Parser parser;
- protected boolean encodingHackEnabled;
-
public FO2PDFFormatter() {
super.MIMEtype = "application/pdf";
super.statusMessage = FOP_VERSION + " formatter (note: version
number is often wildly inaccurate)";
@@ -115,7 +113,6 @@
public void init(Configurations conf) {
super.init(conf);
- encodingHackEnabled = "true".equals (conf.get ("encoding.hack"));
}
public void init(Director director) {
@@ -131,23 +128,16 @@
}
}
- public void format(Document document, OutputStream stream, Dictionary
parameters) throws Exception {
+ public void format(Document document, OutputStream outStream, Dictionary
parameters)
+ throws Exception {
Driver driver = new Driver();
driver.setRenderer("org.apache.fop.render.pdf.PDFRenderer",
FOP_VERSION);
driver.addElementMapping("org.apache.fop.fo.StandardElementMapping");
driver.addElementMapping("org.apache.fop.svg.SVGElementMapping");
- OutputStream outStream;
if (STREAM_MODE) {
- if (encodingHackEnabled) {
- outStream = new ByteArrayOutputStream ();
- }
- else {
- outStream = stream;
- }
-
// We use reflection here to avoid compile-time errors
// This translates at runtime to
//driver.setOutputStream (outStream);
@@ -187,10 +177,5 @@
}
driver.format();
driver.render();
-
- if (STREAM_MODE && encodingHackEnabled) {
- if (encoding == null) encoding = "UTF-8";
- stream.write (new String (outputStream.toByteArray (),
encoding).getBytes ());
- }
}
}
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]