|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectlt.monarch.chart.chart2D.engine.Shape2D
public abstract class Shape2D extends java.lang.Object implements java.io.Serializable
Shape interface for drawing shapes in bar series.
| Modifier and Type | Class and Description |
|---|---|
protected static class |
Shape2D.Elipse
Class for storing ellipse coordinates |
protected class |
Shape2D.Line
Class for storing line coordinates |
protected class |
Shape2D.Polygon
Class for storing polygon coordinates |
protected static interface |
Shape2D.ProjectableShape
|
protected class |
Shape2D.Rectangle
Class for storing bar coordinates |
| Modifier and Type | Field and Description |
|---|---|
protected Rectangle2D |
bounds
Bounds of the shape |
protected java.util.ArrayList<Shape2D.ProjectableShape> |
shapeList
List of shapes to draw |
| Constructor and Description |
|---|
Shape2D()
|
| Modifier and Type | Method and Description |
|---|---|
void |
draw(int index,
AbstractGraphics g,
Projector projector,
PlaneMapper mapper,
Style style,
AbstractPaintTags tag,
PaintMode paintMode)
Draws the shape into the graphic context |
void |
draw(int index,
AbstractGraphics g,
Projector projector,
PlaneMapper mapper,
Style style,
PaintMode paintMode)
Draws the shape into the graphic context |
Rectangle2D |
getBounds()
Gets bounds of the shape |
java.awt.Shape |
getShape()
Gets the polygon |
protected abstract void |
initShape()
Initializes the shape and adds its points to the array |
protected Point2D |
projectPoint(Point2D point,
Projector projector)
Projects point to the real coordinates |
protected Point2D |
projectPointInplace(Point2D point,
Projector projector)
Projects point to the real coordinates |
protected void |
projectShape(Projector projector)
Calculates and return the polygon |
void |
setBounds(double x,
double y,
double width,
double height)
Sets bounds of the shape |
void |
transform(Transformation matrix)
Transforms the shape according to the transformation matrix |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.ArrayList<Shape2D.ProjectableShape> shapeList
protected Rectangle2D bounds
| Constructor Detail |
|---|
public Shape2D()
| Method Detail |
|---|
public void setBounds(double x,
double y,
double width,
double height)
x - x positiony - y positionwidth - shape widthheight - shape height
public void draw(int index,
AbstractGraphics g,
Projector projector,
PlaneMapper mapper,
Style style,
AbstractPaintTags tag,
PaintMode paintMode)
index - index of the bar in the seriesg - graphic contextprojector - projectormapper - mapperstyle - bar styletag - tagpaintMode - painting mode
public void draw(int index,
AbstractGraphics g,
Projector projector,
PlaneMapper mapper,
Style style,
PaintMode paintMode)
index - index of the bar in the seriesg - graphic contextprojector - projectormapper - mapperstyle - bar stylepaintMode - painting modepublic Rectangle2D getBounds()
protected void projectShape(Projector projector)
projector - projector
protected Point2D projectPoint(Point2D point,
Projector projector)
point - point to projectprojector - projector
protected Point2D projectPointInplace(Point2D point,
Projector projector)
point - point to projectprojector - projectorpublic java.awt.Shape getShape()
public void transform(Transformation matrix)
matrix - Transformation matrix.protected abstract void initShape()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||