|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectprefuse.controls.ControlAdapter
prefuse.controls.AbstractZoomControl
Abstract base class for zoom controls.
Field Summary | |
static double |
DEFAULT_MAX_SCALE
|
static double |
DEFAULT_MIN_SCALE
|
protected double |
m_maxScale
|
protected double |
m_minScale
|
protected boolean |
m_zoomOverItem
|
protected static int |
MAX_ZOOM
Indicates the maximum allowed zoom level has been reached. |
protected static int |
MIN_ZOOM
Indicates the minimum allowed zoom level has been reached. |
protected static int |
NO_ZOOM
Indicates no zooming can be performed. |
protected static int |
ZOOM
Indicates a zoom operation completed successfully. |
Fields inherited from interface prefuse.controls.Control |
LEFT_MOUSE_BUTTON, MIDDLE_MOUSE_BUTTON, RIGHT_MOUSE_BUTTON |
Constructor Summary | |
AbstractZoomControl()
|
Method Summary | |
double |
getMaxScale()
Gets the maximum scale value allowed by this zoom control |
double |
getMinScale()
Gets the minimum scale value allowed by this zoom control |
boolean |
isZoomOverItem()
Indicates if the zoom control will work while the mouse is over a VisualItem. |
void |
setMaxScale(double maxScale)
Sets the maximum scale value allowed by this zoom control |
void |
setMinScale(double minScale)
Sets the minimum scale value allowed by this zoom control |
void |
setZoomOverItem(boolean zoomOverItem)
Determines if the zoom control will work while the mouse is over a VisualItem |
protected int |
zoom(Display display,
java.awt.geom.Point2D p,
double zoom,
boolean abs)
Zoom the given display at the given point by the zoom factor, in either absolute (item-space) or screen co-ordinates. |
Methods inherited from class prefuse.controls.ControlAdapter |
isEnabled, itemClicked, itemDragged, itemEntered, itemExited, itemKeyPressed, itemKeyReleased, itemKeyTyped, itemMoved, itemPressed, itemReleased, itemWheelMoved, keyPressed, keyReleased, keyTyped, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, mouseWheelMoved, setEnabled |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final double DEFAULT_MIN_SCALE
public static final double DEFAULT_MAX_SCALE
protected static final int ZOOM
protected static final int MIN_ZOOM
protected static final int MAX_ZOOM
protected static final int NO_ZOOM
protected double m_minScale
protected double m_maxScale
protected boolean m_zoomOverItem
Constructor Detail |
public AbstractZoomControl()
Method Detail |
protected int zoom(Display display, java.awt.geom.Point2D p, double zoom, boolean abs)
display
- the Display to zoomp
- the point to center the zoom uponzoom
- the scale factor by which to zoomabs
- if true, the point p should be assumed to be in absolute
coordinates, otherwise it will be treated as scree (pixel) coordinates
ZOOM
, NO_ZOOM
, MIN_ZOOM
,
MAX_ZOOM
.public double getMaxScale()
public void setMaxScale(double maxScale)
public double getMinScale()
public void setMinScale(double minScale)
public boolean isZoomOverItem()
public void setZoomOverItem(boolean zoomOverItem)
zoomOverItem
- true to indicate the control operates
over VisualItems, false otherwise
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |