edu.stanford.hci.r3.paper.regions
Class CompoundRegion
java.lang.Object
edu.stanford.hci.r3.paper.Region
edu.stanford.hci.r3.paper.regions.CompoundRegion
public class CompoundRegion
- extends Region
Put more than one region together.
This software is distributed under the BSD License.
Methods inherited from class edu.stanford.hci.r3.paper.Region |
addEventHandler, getEventHandlers, getFillColor, getHeight, getIsActiveString, getName, getOpacity, getOriginX, getOriginY, getParentSheet, getScaleX, getScaleY, getShape, getStrokeColor, getUnits, getUnscaledBounds2D, getUnscaledBoundsHeight, getUnscaledBoundsWidth, getUnscaledShapeCopy, getWidth, isActive, isVisible, resetScale, scaleRegion, scaleRegionUniformly, setActive, setFillColor, setName, setOpacity, setParentSheet, setScale, setShape, setStrokeColor, setVisible |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
CompoundRegion
public CompoundRegion(java.lang.String name,
Units xOrigin,
Units yOrigin)
addChild
public void addChild(Region childRegion,
Coordinates relativeCoord)
- A compound region is made up of a bunch of regions and their coordinates relative to the
origin of the compound region.
TODO: Should renderers of this class respect the master scaling factor???
- Parameters:
childRegion
- a child regionrelativeCoord
-
getChildOffset
public Coordinates getChildOffset(Region child)
- Parameters:
child
-
- Returns:
getChildren
public java.util.Set<Region> getChildren()
- Returns:
getRenderer
public RegionRenderer getRenderer()
- Description copied from class:
Region
- Subclasses should override this, to customize rendering. Otherwise, you'll just get gray
boxes, which is what RegionRenderer does.
- Overrides:
getRenderer
in class Region
- Returns:
- the renderer for this region
- See Also:
Region.getRenderer()
toString
public java.lang.String toString()
- Description copied from class:
Region
- Please override for more interesting output. This will print the name of the class along with
all the segments of the shape.
- Overrides:
toString
in class Region
- Returns:
- the String representation of this Region
- See Also:
Region.toString()