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 ge...@locus.apache.org on 2000/06/16 21:24:13 UTC

cvs commit: xml-fop/src/org/apache/fop/fo/flow StaticContent.java

gears       00/06/16 12:24:11

  Modified:    src/org/apache/fop/fo/flow StaticContent.java
  Log:
  This is Jordan Naftolin's patch to allow you to have links in the
  xsl-before and xsl-after regions.
  
  Revision  Changes    Path
  1.7       +12 -1     xml-fop/src/org/apache/fop/fo/flow/StaticContent.java
  
  Index: StaticContent.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/flow/StaticContent.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- StaticContent.java	1999/11/25 17:33:12	1.6
  +++ StaticContent.java	2000/06/16 19:24:01	1.7
  @@ -1,4 +1,4 @@
  -/*-- $Id: StaticContent.java,v 1.6 1999/11/25 17:33:12 jtauber Exp $ -- 
  +/*-- $Id: StaticContent.java,v 1.7 2000/06/16 19:24:01 gears Exp $ -- 
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -94,6 +94,17 @@
       
       public Status layout(Area area) throws FOPException {
   	int numChildren = this.children.size();
  +	// Set area absolute height so that link rectangles will be drawn correctly in xsl-before and xsl-after
  +	String flowName = this.properties.get("flow-name").getString();
  +	if(flowName.equals("xsl-before"))
  +	{
  +		area.setAbsoluteHeight(-area.getMaxHeight());
  +	}
  +	else if(flowName.equals("xsl-after"))
  +	{
  +		area.setAbsoluteHeight(area.getPage().getBody().getMaxHeight());
  +	}
  +       
   	for (int i = 0; i < numChildren; i++) {
   	    FObj fo = (FObj) children.elementAt(i);
   	    fo.layout(area);