Package org.apache.fop.layout

Examples of org.apache.fop.layout.AreaContainer


  SimplePageMaster simpleMaster = getCurrentSimplePageMaster();

  if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null && (currentPage.getBefore() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer beforeArea = currentPage.getBefore();
    beforeArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionBefore.REGION_CLASS),
            beforeArea);
      }
  }

  if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null && (currentPage.getAfter() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer afterArea = currentPage.getAfter();
    afterArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionAfter.REGION_CLASS),
            afterArea);
      }

  }
View Full Code Here


    private void layoutStaticContent(Flow flow, Region region,
             AreaContainer area)
  throws FOPException
    {
  if (flow instanceof StaticContent) {
      AreaContainer beforeArea = currentPage.getBefore();
      ((StaticContent)flow).layout(area, region);
  }
  else {
      MessageHandler.errorln("WARNING: "+region.getName()+" only supports static-content flows currently. Cannot use flow named '"+flow.getFlowName()+"'");
  }
View Full Code Here

        if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null
                && (currentPage.getBefore() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer beforeArea = currentPage.getBefore();
                beforeArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionBefore.REGION_CLASS),
                                    beforeArea);
            }
        }

        if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null
                && (currentPage.getAfter() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer afterArea = currentPage.getAfter();
                afterArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionAfter.REGION_CLASS),
                                    afterArea);
            }
        }

        if (simpleMaster.getRegion(RegionStart.REGION_CLASS) != null
                && (currentPage.getStart() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionStart.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer startArea = currentPage.getStart();
                startArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionStart.REGION_CLASS),
                                    startArea);
            }
        }

        if (simpleMaster.getRegion(RegionEnd.REGION_CLASS) != null
                && (currentPage.getEnd() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionEnd.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer endArea = currentPage.getEnd();
                endArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionEnd.REGION_CLASS),
                                    endArea);
            }
        }
View Full Code Here

    }

    private void layoutStaticContent(Flow flow, Region region,
                                     AreaContainer area) throws FOPException {
        if (flow instanceof StaticContent) {
            AreaContainer beforeArea = currentPage.getBefore();
            ((StaticContent)flow).layout(area, region);
        } else {
            MessageHandler.errorln("WARNING: " + region.getName()
                                   + " only supports static-content flows currently. Cannot use flow named '"
                                   + flow.getFlowName() + "'");
View Full Code Here

        if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null
                && (currentPage.getBefore() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer beforeArea = currentPage.getBefore();
                beforeArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionBefore.REGION_CLASS),
                                    beforeArea);
            }
        }

        if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null
                && (currentPage.getAfter() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer afterArea = currentPage.getAfter();
                afterArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionAfter.REGION_CLASS),
                                    afterArea);
            }
        }

        if (simpleMaster.getRegion(RegionStart.REGION_CLASS) != null
                && (currentPage.getStart() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionStart.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer startArea = currentPage.getStart();
                startArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionStart.REGION_CLASS),
                                    startArea);
            }
        }

        if (simpleMaster.getRegion(RegionEnd.REGION_CLASS) != null
                && (currentPage.getEnd() != null)) {
            Flow staticFlow =
                (Flow)_flowMap.get(simpleMaster.getRegion(RegionEnd.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer endArea = currentPage.getEnd();
                endArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionEnd.REGION_CLASS),
                                    endArea);
            }
        }
View Full Code Here

    }

    private void layoutStaticContent(Flow flow, Region region,
                                     AreaContainer area) throws FOPException {
        if (flow instanceof StaticContent) {
            AreaContainer beforeArea = currentPage.getBefore();
            ((StaticContent)flow).layout(area, region);
        } else {
            log.error("" + region.getName()
                                   + " only supports static-content flows currently. Cannot use flow named '"
                                   + flow.getFlowName() + "'");
View Full Code Here

  SimplePageMaster simpleMaster = getCurrentSimplePageMaster();

  if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null && (currentPage.getBefore() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer beforeArea = currentPage.getBefore();
    beforeArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionBefore.REGION_CLASS),
            beforeArea);
      }
  }

  if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null && (currentPage.getAfter() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer afterArea = currentPage.getAfter();
    afterArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionAfter.REGION_CLASS),
            afterArea);
      }
  }
 
  if (simpleMaster.getRegion(RegionStart.REGION_CLASS) != null && (currentPage.getStart() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionStart.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer startArea = currentPage.getStart();
    startArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionStart.REGION_CLASS),
      startArea);
      }
  }
 
  if (simpleMaster.getRegion(RegionEnd.REGION_CLASS) != null && (currentPage.getEnd() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionEnd.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer endArea = currentPage.getEnd();
    endArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionEnd.REGION_CLASS),
      endArea);
      }
  }
 
View Full Code Here

    private void layoutStaticContent(Flow flow, Region region,
             AreaContainer area)
  throws FOPException
    {
  if (flow instanceof StaticContent) {
      AreaContainer beforeArea = currentPage.getBefore();
      ((StaticContent)flow).layout(area, region);
  }
  else {
      MessageHandler.errorln("WARNING: "+region.getName()+" only supports static-content flows currently. Cannot use flow named '"+flow.getFlowName()+"'");
  }
View Full Code Here

        if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null
                && (page.getBefore() != null)) {
            StaticContent staticFlow =
                (StaticContent)flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer beforeArea = page.getBefore();
                beforeArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionBefore.REGION_CLASS),
                                    beforeArea);
            }
        }

        if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null
                && (page.getAfter() != null)) {
            StaticContent staticFlow =
                (StaticContent)flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer afterArea = page.getAfter();
                afterArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionAfter.REGION_CLASS),
                                    afterArea);
            }
        }

        if (simpleMaster.getRegion(RegionStart.REGION_CLASS) != null
                && (page.getStart() != null)) {
            StaticContent staticFlow =
                (StaticContent)flowMap.get(simpleMaster.getRegion(RegionStart.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer startArea = page.getStart();
                startArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionStart.REGION_CLASS),
                                    startArea);
            }
        }

        if (simpleMaster.getRegion(RegionEnd.REGION_CLASS) != null
                && (page.getEnd() != null)) {
            StaticContent staticFlow =
                (StaticContent)flowMap.get(simpleMaster.getRegion(RegionEnd.REGION_CLASS).getRegionName());
            if (staticFlow != null) {
                AreaContainer endArea = page.getEnd();
                endArea.setIDReferences(areaTree.getIDReferences());
                layoutStaticContent(staticFlow,
                                    simpleMaster.getRegion(RegionEnd.REGION_CLASS),
                                    endArea);
            }
        }
View Full Code Here

  SimplePageMaster simpleMaster = getCurrentSimplePageMaster();

  if (simpleMaster.getRegion(RegionBefore.REGION_CLASS) != null && (currentPage.getBefore() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionBefore.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer beforeArea = currentPage.getBefore();
    beforeArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionBefore.REGION_CLASS),
            beforeArea);
      }
  }

  if (simpleMaster.getRegion(RegionAfter.REGION_CLASS) != null && (currentPage.getAfter() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionAfter.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer afterArea = currentPage.getAfter();
    afterArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionAfter.REGION_CLASS),
            afterArea);
      }
  }
 
  if (simpleMaster.getRegion(RegionStart.REGION_CLASS) != null && (currentPage.getStart() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionStart.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer startArea = currentPage.getStart();
    startArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionStart.REGION_CLASS),
      startArea);
      }
  }
 
  if (simpleMaster.getRegion(RegionEnd.REGION_CLASS) != null && (currentPage.getEnd() != null)) {
      Flow staticFlow = (Flow)_flowMap.get(simpleMaster.getRegion(RegionEnd.REGION_CLASS).getRegionName());
      if (staticFlow != null) {
    AreaContainer endArea = currentPage.getEnd();
    endArea.setIDReferences(areaTree.getIDReferences());
    layoutStaticContent(staticFlow, simpleMaster.getRegion(RegionEnd.REGION_CLASS),
      endArea);
      }
  }
 
View Full Code Here

TOP

Related Classes of org.apache.fop.layout.AreaContainer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.