|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfr.inria.zvtm.engine.View
fr.inria.zvtm.engine.EView
public class EView
An external view (EView) is wrapped in a JFrame window and can be composed of one or several cameras superimposed. Double buffering is implemented manually, so as to enable offscreen buffer modifications after rendering but before painting on screen, such as when magnifying a region with a Lens.
| Field Summary |
|---|
| Fields inherited from class fr.inria.zvtm.engine.View |
|---|
activeRepaintTimer, ANONYMOUS, mouse, name, OPENGL_VIEW, STD_VIEW |
| Constructor Summary | |
|---|---|
protected |
EView(String viewType,
Vector<Camera> v,
String t,
int w,
int h,
boolean visible,
boolean decorated)
|
protected |
EView(String viewType,
Vector<Camera> v,
String t,
int w,
int h,
boolean bar,
boolean visible,
boolean decorated,
JMenuBar mnb)
|
| Method Summary | |
|---|---|
void |
destroyView()
Destroy this view. |
Component |
getFrame()
Get the java.awt.Component for this View. |
boolean |
isSelected()
|
void |
keyPressed(KeyEvent e)
|
void |
keyReleased(KeyEvent e)
|
void |
keyTyped(KeyEvent e)
|
void |
setLocation(int x,
int y)
Moves this component to a new location. |
void |
setResizable(boolean resizable)
Sets whether this View is resizable by the user. |
void |
setSize(int width,
int height)
Resizes this component so that it has width width and height height. |
void |
setTitle(String t)
Sets the title for this frame to the specified string. |
void |
setVisible(boolean b)
Shows or hides this View depending on the value of parameter b. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected EView(String viewType,
Vector<Camera> v,
String t,
int w,
int h,
boolean visible,
boolean decorated)
viewType - one of View.STD_VIEW, View.OPENGL_VIEW - determines the type of view and acceleration method. The use of OPENGL_VIEW requires the following Java property: -Dsun.java2d.opengl=truev - list of cameras that will constitue the layers of this View.t - view name/title.w - width of window in pixelsh - height of window in pixelsvisible - should the view be made visible automatically or notdecorated - should the view be decorated with the underlying window manager's window frame or not
protected EView(String viewType,
Vector<Camera> v,
String t,
int w,
int h,
boolean bar,
boolean visible,
boolean decorated,
JMenuBar mnb)
viewType - one of View.STD_VIEW, View.OPENGL_VIEW - determines the type of view and acceleration method. The use of OPENGL_VIEW requires the following Java property: -Dsun.java2d.opengl=truev - list of camerast - view namew - width of window in pixelsh - height of window in pixelsbar - true -> add a status bar to this view (below main panel)visible - should the view be made visible automatically or notdecorated - should the view be decorated with the underlying window manager's window frame or notmnb - a menu bar, already configured with actionListeners already attached to items (it is just added to the view). No effect if null.| Method Detail |
|---|
public Component getFrame()
View
getFrame in class Viewpublic boolean isSelected()
isSelected in class View
public void setLocation(int x,
int y)
View
setLocation in class Viewx - the x-coordinate of the new location's top-left corner in the parent's coordinate spacey - the y-coordinate of the new location's top-left corner in the parent's coordinate spacepublic void setTitle(String t)
View
setTitle in class Viewt - - the title to be displayed in the frame's border. A null value is treated as an empty string, "".
public void setSize(int width,
int height)
View
setSize in class Viewwidth - - the new width of this component in pixelsheight - - the new height of this component in pixelspublic void setResizable(boolean resizable)
View
setResizable in class Viewresizable - - true if this frame is resizable; false otherwise.public void setVisible(boolean b)
View
setVisible in class Viewpublic void destroyView()
View
destroyView in class Viewpublic void keyTyped(KeyEvent e)
keyTyped in interface KeyListenerpublic void keyPressed(KeyEvent e)
keyPressed in interface KeyListenerpublic void keyReleased(KeyEvent e)
keyReleased in interface KeyListener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||