fop 0.94

org.apache.fop.layoutmgr.table
Class TableContentLayoutManager

java.lang.Object
  extended by org.apache.fop.layoutmgr.table.TableContentLayoutManager
All Implemented Interfaces:
PercentBaseContext

public class TableContentLayoutManager
extends java.lang.Object
implements PercentBaseContext

Layout manager for table contents, particularly managing the creation of combined element lists.


Constructor Summary
TableContentLayoutManager(TableLayoutManager parent)
          Main constructor
 
Method Summary
 void addAreas(PositionIterator parentIter, LayoutContext layoutContext)
          Adds the areas generated by this layout manager to the area tree.
 void addRowBackgroundArea(TableRow row, int bpd, int ipd, int yoffset)
          Adds the area for the row background if any.
 int getBaseLength(int lengthBase, FObj fobj)
          Returns the base length for the given length base.
 ColumnSetup getColumns()
           
protected  java.util.LinkedList getFooterElements()
           
protected  int getFooterNetHeight()
           
protected  java.util.LinkedList getHeaderElements()
           
protected  int getHeaderNetHeight()
           
 java.util.LinkedList getNextKnuthElements(LayoutContext context, int alignment)
           
 Block getRowArea(TableRow row)
          Get the area for a row for background.
 TableLayoutManager getTableLM()
           
 int getUsedBPD()
           
protected  int getXOffsetOfGridUnit(GridUnit gu)
          Retuns the X offset of the given grid unit.
 void setStartXOffset(int startXOffset)
          Sets the overall starting x-offset.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TableContentLayoutManager

public TableContentLayoutManager(TableLayoutManager parent)
Main constructor

Parameters:
parent - Parent layout manager
Method Detail

getTableLM

public TableLayoutManager getTableLM()
Returns:
the table layout manager

getColumns

public ColumnSetup getColumns()
Returns:
the column setup of this table

getHeaderNetHeight

protected int getHeaderNetHeight()
Returns:
the net header height

getFooterNetHeight

protected int getFooterNetHeight()
Returns:
the net footer height

getHeaderElements

protected java.util.LinkedList getHeaderElements()
Returns:
the header element list

getFooterElements

protected java.util.LinkedList getFooterElements()
Returns:
the footer element list

getNextKnuthElements

public java.util.LinkedList getNextKnuthElements(LayoutContext context,
                                                 int alignment)
See Also:
LayoutManager

getXOffsetOfGridUnit

protected int getXOffsetOfGridUnit(GridUnit gu)
Retuns the X offset of the given grid unit.

Parameters:
gu - the grid unit
Returns:
the requested X offset

addAreas

public void addAreas(PositionIterator parentIter,
                     LayoutContext layoutContext)
Adds the areas generated by this layout manager to the area tree.

Parameters:
parentIter - the position iterator
layoutContext - the layout context for adding areas

getRowArea

public Block getRowArea(TableRow row)
Get the area for a row for background.

Parameters:
row - the table-row object or null
Returns:
the row area or null if there's no background to paint

addRowBackgroundArea

public void addRowBackgroundArea(TableRow row,
                                 int bpd,
                                 int ipd,
                                 int yoffset)
Adds the area for the row background if any.

Parameters:
row - row for which to generate the background
bpd - block-progression-dimension of the row
ipd - inline-progression-dimension of the row
yoffset - Y offset at which to paint

setStartXOffset

public void setStartXOffset(int startXOffset)
Sets the overall starting x-offset. Used for proper placement of cells.

Parameters:
startXOffset - starting x-offset (table's start-indent)

getUsedBPD

public int getUsedBPD()
Returns:
the amount of block-progression-dimension used by the content

getBaseLength

public int getBaseLength(int lengthBase,
                         FObj fobj)
Description copied from interface: PercentBaseContext
Returns the base length for the given length base. Length base should be one of the constants defined in LengthBase.

Specified by:
getBaseLength in interface PercentBaseContext
Parameters:
lengthBase - Indicates which type of the base length value is to be returned
fobj - The FO object against which the percentage should be evaluated
Returns:
The base length value of the given kind
See Also:
PercentBaseContext.getBaseLength(int, FObj)

fop 0.94

Copyright 1999-2007 The Apache Software Foundation. All Rights Reserved.