xmlgraphics-fop-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arved Sandstrom <Arved...@chebucto.ns.ca>
Subject Re: AWTRenderer complex body regions
Date Thu, 21 Dec 2000 02:54:44 GMT
Hi, Daniel

Point taken. I put in the empty methods just so AWTRenderer would compile, a 
couple of days ago, and I really should have followed up by now with pretty 
much what you have.

Unless Someone Beats Me To It (should be a FOP acronym...USBMTI), I'll 
review your patches and get stuff up into CVS within 24 hours.

Thank you.

Arved

P.S. No faux-pas at all. You or anyone, you see something that can be done 
better, hit us with the suggestions and patches, and piss us off a bit with 
repeated posts until we pay attention. We committers don't own the project 
or the code, we just guide it.

At 01:44 PM 12/21/00 +1100, Daniel Bradby wrote:
>
>I've been using the AWTRenderer quite happily in 0.15 until I got a cvs
>update and it stopped working all together. Is there any other way to
>embed FOP into my app so I can print the rendered result?
>
>It looks like some empty methods were created to suppot complex body
>areas. So taking straight from the PDFRenderer is the additional methods
>in a patch (this is my first commit to this sort of project so pls
>forgive any faux-pas). I ran some of the samples over it and it seemed
>to work ok.
>
>I haven't looked in detail at the architecture but this sort of code
>copy doesn't feel very clean.
>
>btw I'm very happy now table-header is working :)
>
>---
>Daniel Bradby
>daniel@bjs.com.auIndex: AWTRenderer.java
>===================================================================
>RCS file:
/home/cvspublic/xml-fop/src/org/apache/fop/render/awt/AWTRenderer.java,v
>retrieving revision 1.16
>diff -u -r1.16 AWTRenderer.java
>--- AWTRenderer.java	2000/12/18 04:56:15	1.16
>+++ AWTRenderer.java	2000/12/21 02:19:01
>@@ -357,11 +357,27 @@
>         }
>     }
> 
>-	// empty for now
>-  	public void renderBodyAreaContainer(BodyAreaContainer area) {}
>+	public void renderBodyAreaContainer(BodyAreaContainer area) {
>+  		renderAreaContainer(area.getBeforeFloatReferenceArea());
>+  		renderAreaContainer(area.getFootnoteReferenceArea());
> 
>-	// empty for now
>-	public void renderSpanArea(SpanArea area) {}
>+		// main reference area
>+		Enumeration e = area.getMainReferenceArea().getChildren().elements();
>+		while (e.hasMoreElements()) {
>+            org.apache.fop.layout.Box b =
>+              (org.apache.fop.layout.Box) e.nextElement();
>+			b.render(this);	// span areas
>+		}
>+	}
>+
>+	public void renderSpanArea(SpanArea area) {
>+		Enumeration e = area.getChildren().elements();
>+		while (e.hasMoreElements()) {
>+            org.apache.fop.layout.Box b =
>+              (org.apache.fop.layout.Box) e.nextElement();
>+			b.render(this);	// column areas
>+		}
>+	}
> 
>     private void doFrame(org.apache.fop.layout.Area area) {
>         int w, h;
>
Fairly Senior Software Type
e-plicity (http://www.e-plicity.com)
Wireless * B2B * J2EE * XML --- Halifax, Nova Scotia


Mime
View raw message