Class EDU.auburn.VGJ.gui.ViewportScroller
All Packages Class Hierarchy This Package Previous Next Index
Class EDU.auburn.VGJ.gui.ViewportScroller
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Canvas
|
+----EDU.auburn.VGJ.gui.ViewportScroller
- public class ViewportScroller
- extends Canvas
A ViewportScroller is a window used to scroll a window through a
larger area of content. The content is shown as a white rectangle, with
the window being represented by a black rectangle outline within it. A
SCROLL event is sent when the user drags the "window" with the mouse.
Here is the source.
-
DONE
-
-
SCROLL
- Event indicating the scroller has been moved.
-
ViewportScroller(int, int, double, double, double, double, double, double)
-
-
handleEvent(Event)
-
-
mouseDown(Event, int, int)
-
-
mouseDrag(Event, int, int)
-
-
mouseUp(Event, int, int)
-
-
paint(Graphics)
-
-
paintOver()
-
-
preferredSize()
-
-
removeNotify()
-
-
setContentSize(double, double)
-
-
setOffset(double, double)
-
-
setPortSize(double, double)
-
SCROLL
public static int SCROLL
- Event indicating the scroller has been moved.
DONE
public static int DONE
ViewportScroller
public ViewportScroller(int width,
int height,
double contentw,
double contenth,
double portw,
double porth,
double offsx,
double offsy)
paint
public synchronized void paint(Graphics graphics)
- Overrides:
- paint in class Canvas
setPortSize
public void setPortSize(double width,
double height)
setContentSize
public void setContentSize(double width,
double height)
setOffset
public void setOffset(double x,
double y)
preferredSize
public Dimension preferredSize()
- Overrides:
- preferredSize in class Component
paintOver
public synchronized void paintOver()
mouseDown
public boolean mouseDown(Event e,
int x,
int y)
- Overrides:
- mouseDown in class Component
mouseDrag
public boolean mouseDrag(Event e,
int x,
int y)
- Overrides:
- mouseDrag in class Component
mouseUp
public boolean mouseUp(Event e,
int x,
int y)
- Overrides:
- mouseUp in class Component
handleEvent
public boolean handleEvent(Event e)
- Overrides:
- handleEvent in class Component
removeNotify
public synchronized void removeNotify()
- Overrides:
- removeNotify in class Component
All Packages Class Hierarchy This Package Previous Next Index