view
Class ColoredShape

java.lang.Object
  extended by view.ShapeContainer
      extended by view.ColoredShape
All Implemented Interfaces:
Paint, Shape, Transparency

public class ColoredShape
extends ShapeContainer
implements Paint

A class that comprises a shape and a paint object. Implements both interfaces.


Field Summary
private  Paint color
          The paint the paint interface delegates to.
 
Fields inherited from interface java.awt.Transparency
BITMASK, OPAQUE, TRANSLUCENT
 
Constructor Summary
ColoredShape(Shape draw, Paint paint)
          Constructs a new colored shape defining the shape and the paint object.
 
Method Summary
 PaintContext createContext(ColorModel cm, Rectangle deviceBounds, Rectangle2D userBounds, AffineTransform xform, RenderingHints hints)
           
 int getTransparency()
           
 
Methods inherited from class view.ShapeContainer
contains, contains, contains, contains, getBounds, getBounds2D, getPathIterator, getPathIterator, intersects, intersects
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

color

private Paint color
The paint the paint interface delegates to.

Constructor Detail

ColoredShape

public ColoredShape(Shape draw,
                    Paint paint)
Constructs a new colored shape defining the shape and the paint object.

Method Detail

getTransparency

public int getTransparency()
Specified by:
getTransparency in interface Transparency

createContext

public PaintContext createContext(ColorModel cm,
                                  Rectangle deviceBounds,
                                  Rectangle2D userBounds,
                                  AffineTransform xform,
                                  RenderingHints hints)
Specified by:
createContext in interface Paint