Package PamView.zoomer
Class ZoomPolygon
java.lang.Object
PamView.zoomer.ZoomShape
PamView.zoomer.ZoomPolygon
A zoom polygon created by the zoomer.
- Author:
- Doug Gillespie
-
Constructor Summary
ConstructorDescriptionZoomPolygon
(Zoomer zoomer, Point startPoint, int coordinateType, double xStart, double yStart) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Shape is complete for whatever reason.boolean
containsPoint
(Component component, Point pt) Shape contains the point pt.Draw the shape using the given graphics handle on the given component.drawShapeOutline
(Graphics g, Component component) drawShapeSolid
(Graphics g, Component component) int
double
double[]
double
double
double[]
double
void
newPoint
(double x, double y) New point to add to the shape - or update old point if it's a rectangle.boolean
void
setCurrentMousePoint
(Point currentMousePoint) zoomShapeToOverlayMark
(OverlayMarker overlayMarker) Convert the obsolete zoom shapes into newer overlay marks.Methods inherited from class PamView.zoomer.ZoomShape
getCoordinateType, getZoomer, isClosed, setZoomShapeFill, setZoomShapeOutline
-
Constructor Details
-
ZoomPolygon
-
-
Method Details
-
drawShape
Description copied from class:ZoomShape
Draw the shape using the given graphics handle on the given component. -
drawShapeOutline
-
drawShapeSolid
-
getBounds
-
containsPoint
Description copied from class:ZoomShape
Shape contains the point pt.Note that these are in screen pixel coordinates.
- Specified by:
containsPoint
in classZoomShape
- Parameters:
pt
- point- Returns:
- true if the point is within the shape.
-
newPoint
public void newPoint(double x, double y) Description copied from class:ZoomShape
New point to add to the shape - or update old point if it's a rectangle. -
closeShape
public void closeShape()Description copied from class:ZoomShape
Shape is complete for whatever reason.- Overrides:
closeShape
in classZoomShape
-
removeOnZoom
public boolean removeOnZoom()- Specified by:
removeOnZoom
in classZoomShape
- Returns:
- true if the object should no longer be displayed after zooming
Basically true for rectangles, false for polygons.
-
setCurrentMousePoint
- Parameters:
currentMousePoint
- the currentMousePoint to set
-
getStartPoint
- Returns:
- the startPoint
-
getNumPoints
public int getNumPoints() -
getXLength
public double getXLength()- Specified by:
getXLength
in classZoomShape
- Returns:
- the difference between the minimum and maximum x values.
-
getXStart
public double getXStart() -
getYLength
public double getYLength()- Specified by:
getYLength
in classZoomShape
- Returns:
- the difference between the minimum and maximum y values.
-
getYStart
public double getYStart() -
getxPoints
public double[] getxPoints()- Returns:
- the xPoints
-
getyPoints
public double[] getyPoints()- Returns:
- the yPoints
-
zoomShapeToOverlayMark
Description copied from class:ZoomShape
Convert the obsolete zoom shapes into newer overlay marks.- Specified by:
zoomShapeToOverlayMark
in classZoomShape
- Returns:
-