All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class fi.helsinki.cs.MapDrawer.LayoutObject

java.lang.Object
   |
   +----fi.helsinki.cs.MapDrawer.LayoutObject

public abstract class LayoutObject
extends Object
implements ParseElement
MapDrawer's layout manager object -- an object which is constructed for every - pair. This interface should be implemented by all area objects which are able to scale RelPoints into their content.


Variable Index

 o loc
 o p

Constructor Index

 o LayoutObject()

Method Index

 o addChild(ParseElement)
This routine is not supported by non-combined layouts.
 o getBoundRect()
Get the bounding rectangle of this area.
 o getParent()
 o getProperty(MapDProp)
This routine is not supported by layouts.
 o scalePoint(RelPoint)
Scale a point according to this context.
 o setParent(ParseElement)
 o setProperty(MapDProp)
 o toPolygon()
Give the shape of this area as a Polygon.

Variables

 o p
 protected CombinedLayout p
 o loc
 protected int loc

Constructors

 o LayoutObject
 public LayoutObject()

Methods

 o scalePoint
 public RelPoint scalePoint(RelPoint orig)
Scale a point according to this context.

Parameters:
orig - the point to be scaled.
hint - how the point should be scaled (used by scalers that contain many areas). If hint is null, the whole of this scaler's area should be used.
Returns:
the coordinate of the point in this area.
 o toPolygon
 public abstract Vector toPolygon()
Give the shape of this area as a Polygon. Can be used, for example, to fill the area with a specific color.

Returns:
a vector of valid RelPoint endpoints.
 o getBoundRect
 public abstract RelRect getBoundRect()
Get the bounding rectangle of this area. This is useful because scalers should always scale a RelPoint so that it won't be outside their bounding rectangle if its original coordinates were in the MapDrawer range. Used for tracking mouse clicks.

 o setProperty
 public abstract int setProperty(MapDProp prop)
 o getParent
 public ParseElement getParent()
 o setParent
 public void setParent(ParseElement parent)
 o getProperty
 public int getProperty(MapDProp p)
This routine is not supported by layouts.

 o addChild
 public void addChild(ParseElement child)
This routine is not supported by non-combined layouts.


All Packages  Class Hierarchy  This Package  Previous  Next  Index