diff options
author | Keiron Liddle <keiron@apache.org> | 2001-10-26 09:27:00 +0000 |
---|---|---|
committer | Keiron Liddle <keiron@apache.org> | 2001-10-26 09:27:00 +0000 |
commit | af113ef5a388ac87b4f1dac63e07ffc7160f8b14 (patch) | |
tree | d40d1802b6728e0e5819e2e2939ff4254da47ffa /src/org/apache/fop/area/AreaTree.java | |
parent | 3c34d76dfaa0908026069b0763558fa7d464ceb2 (diff) | |
download | xmlgraphics-fop-af113ef5a388ac87b4f1dac63e07ffc7160f8b14.tar.gz xmlgraphics-fop-af113ef5a388ac87b4f1dac63e07ffc7160f8b14.zip |
updates to area tree and reading/rendering with xml
added user agent, xml handlers
added inline level property
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194521 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/org/apache/fop/area/AreaTree.java')
-rw-r--r-- | src/org/apache/fop/area/AreaTree.java | 47 |
1 files changed, 33 insertions, 14 deletions
diff --git a/src/org/apache/fop/area/AreaTree.java b/src/org/apache/fop/area/AreaTree.java index 6f3157773..b8544878c 100644 --- a/src/org/apache/fop/area/AreaTree.java +++ b/src/org/apache/fop/area/AreaTree.java @@ -9,6 +9,24 @@ package org.apache.fop.area; import java.util.ArrayList; + +/** + * Area tree for formatting objects. + * + * Concepts: + * The area tree is to be as small as possible. With minimal classes + * and data to fully represent an area tree for formatting objects. + * The area tree needs to be simple to render and follow the spec + * closely. + * This area tree has the concept of page sequences. + * Where ever possible information is discarded or optimised to + * keep memory use low. The data is also organised to make it + * possible for renderers to minimise their output. + * A page can be saved if not fully resolved and once rendered + * a page contains only size and id reference information. + * The area tree pages are organised in a model that depends on the + * type of renderer. + */ public class AreaTree { // allows for different models to deal with adding/rendering // in different situations @@ -40,15 +58,6 @@ public class AreaTree { public abstract void addPage(PageViewport page); } - // this queues pages and will call the render listener - // when the page is ready to be rendered - // if the render supports out of order rendering - // then a ready page is rendered immediately - public static class RenderPagesModel extends AreaTreeModel { - public void startPageSequence(Area title) {} - public void addPage(PageViewport page) {} - } - // this class stores all the pages in the document // for interactive agents public static class StorePagesModel extends AreaTreeModel { @@ -89,10 +98,20 @@ public class AreaTree { return (PageViewport) sequence.get(count); } } -} -abstract class PageRenderListener { - public abstract void startPageSequence(Area title); - public abstract void preparePage(PageViewport page); - public abstract void renderPage(PageViewport page); + // this queues pages and will call the render listener + // when the page is ready to be rendered + // if the render supports out of order rendering + // then a ready page is rendered immediately + public static class RenderPagesModel extends StorePagesModel { + public void startPageSequence(Area title) {} + public void addPage(PageViewport page) {} + } + + public static abstract class PageRenderListener { + public abstract void renderPage(RenderPagesModel model, + int pageseq, int count); + } + } + |