org.jfree.layouting.modules.output.graphics

Class LogicalPageDrawable

public class LogicalPageDrawable extends Object implements PageDrawable

The page drawable is the content provider for the Graphics2DOutputTarget. This component is responsible for rendering the current page to a Graphics2D object.

Author: Thomas Morgner

Constructor Summary
LogicalPageDrawable(LogicalPageBox rootBox)
Method Summary
voiddraw(Graphics2D g2, Rectangle2D area)
Draws the object.
voiddrawBox(Graphics2D g2, RenderBox box, int level)
PageFormatgetPageFormat()
DimensiongetPreferredSize()
Returns the preferred size of the drawable.
static StringglpyhToString(Glyph g)
booleanisPreserveAspectRatio()
Returns true, if this drawable will preserve an aspect ratio during the drawing.

Constructor Detail

LogicalPageDrawable

public LogicalPageDrawable(LogicalPageBox rootBox)

Method Detail

draw

public void draw(Graphics2D g2, Rectangle2D area)
Draws the object.

Parameters: g2 the graphics device. area the area inside which the object should be drawn.

drawBox

public void drawBox(Graphics2D g2, RenderBox box, int level)

getPageFormat

public PageFormat getPageFormat()

getPreferredSize

public Dimension getPreferredSize()
Returns the preferred size of the drawable. If the drawable is aspect ratio aware, these bounds should be used to compute the preferred aspect ratio for this drawable.

Returns: the preferred size.

glpyhToString

public static String glpyhToString(Glyph g)

isPreserveAspectRatio

public boolean isPreserveAspectRatio()
Returns true, if this drawable will preserve an aspect ratio during the drawing.

Returns: true, if an aspect ratio is preserved, false otherwise.