|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--java.awt.Window
|
+--javax.swing.JWindow
|
+--edu.umd.cs.jazz.util.ZBasicWindow
ZBasicWindow defines a simple top-level Swing frame-less (i.e., Window) for use by Jazz. It is intended to be full-screen mode, and small windows to be under complete control by the application since the window doesn't have any window dressing.
This defines basic event handlers for panning and zooming with the keyboard and mouse. It also defines the Escape key to close the window.
| Inner classes inherited from class javax.swing.JWindow |
javax.swing.JWindow.AccessibleJWindow |
| Field Summary | |
protected ZBasicComponent |
component
The component in the frame that Jazz renders onto. |
protected ZEventHandler |
keyEventHandler
The event handler that supports key events |
static int |
METAL_LAF
|
protected static java.lang.String |
metalClassName
|
static int |
MOTIF_LAF
|
protected static java.lang.String |
motifClassName
|
protected ZEventHandler |
panEventHandler
The event handler that supports panning |
protected java.awt.event.WindowListener |
windowListener
The window listener for the default basic frame that exits the application when the main window is closed. |
static int |
WINDOWS_LAF
|
protected static java.lang.String |
windowsClassName
|
protected ZEventHandler |
zoomEventHandler
The event handler that supports zooming |
| Fields inherited from class javax.swing.JWindow |
accessibleContext,
rootPane,
rootPaneCheckingEnabled |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
| Constructor Summary | |
ZBasicWindow()
Creates a new top-level frame-less window with a basic Jazz scenegraph in a component within the frame. |
|
ZBasicWindow(ZRootNode root,
ZNode layer)
Creates a new top-level frame-less window with a basic Jazz scenegraph in a component within the frame. |
|
| Method Summary | |
ZCamera |
getCamera()
Return the camera associated with the primary surface. |
ZBasicComponent |
getComponent()
Return the component that the surface is attached to. |
ZEventHandler |
getKeyEventHandler()
Return the key event handler. |
ZNode |
getLayer()
Return the "layer". |
ZEventHandler |
getPanEventHandler()
Return the pan event handler. |
ZRootNode |
getRoot()
Return the root of the scenegraph. |
ZSurface |
getSurface()
Return the surface. |
java.awt.event.WindowListener |
getWindowListener()
Returns the window listener for the default basic frame that exits the application when the main window is closed. |
ZEventHandler |
getZoomEventHandler()
Return the zoom event handler. |
static void |
main(java.lang.String[] s)
Simple test that creates a basic application and puts some text in the scenegraph. |
void |
setLookAndFeel(int laf)
Set the Swing look and feel. |
| Methods inherited from class javax.swing.JWindow |
addImpl,
createRootPane,
getAccessibleContext,
getContentPane,
getGlassPane,
getLayeredPane,
getRootPane,
isRootPaneCheckingEnabled,
paramString,
setContentPane,
setGlassPane,
setLayeredPane,
setLayout,
setRootPane,
setRootPaneCheckingEnabled,
windowInit |
| Methods inherited from class java.awt.Window |
addNotify,
addWindowListener,
applyResourceBundle,
applyResourceBundle,
dispose,
finalize,
getFocusOwner,
getInputContext,
getLocale,
getOwnedWindows,
getOwner,
getToolkit,
getWarningString,
isShowing,
pack,
postEvent,
processEvent,
processWindowEvent,
removeWindowListener,
show,
toBack,
toFront |
| Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
countComponents,
deliverEvent,
doLayout,
findComponentAt,
findComponentAt,
getAlignmentX,
getAlignmentY,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents,
getInsets,
getLayout,
getMaximumSize,
getMinimumSize,
getPreferredSize,
insets,
invalidate,
isAncestorOf,
layout,
list,
list,
locate,
minimumSize,
paint,
paintComponents,
preferredSize,
print,
printComponents,
processContainerEvent,
remove,
remove,
removeAll,
removeContainerListener,
removeNotify,
setFont,
update,
validate,
validateTree |
| Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
disable,
disableEvents,
dispatchEvent,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputMethodRequests,
getLocation,
getLocation,
getLocationOnScreen,
getName,
getParent,
getPeer,
getSize,
getSize,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
isDisplayable,
isDoubleBuffered,
isEnabled,
isFocusTraversable,
isLightweight,
isOpaque,
isValid,
isVisible,
keyDown,
keyUp,
list,
list,
list,
location,
lostFocus,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
prepareImage,
prepareImage,
printAll,
processComponentEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setEnabled,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
size,
toString,
transferFocus |
| Methods inherited from class java.lang.Object |
clone,
equals,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Field Detail |
public static final int WINDOWS_LAF
public static final int METAL_LAF
public static final int MOTIF_LAF
protected static java.lang.String windowsClassName
protected static java.lang.String metalClassName
protected static java.lang.String motifClassName
protected ZBasicComponent component
protected ZEventHandler panEventHandler
protected ZEventHandler zoomEventHandler
protected ZEventHandler keyEventHandler
protected java.awt.event.WindowListener windowListener
| Constructor Detail |
public ZBasicWindow()
getRoot(),
getSurface(),
getCamera(),
getLayer()
public ZBasicWindow(ZRootNode root,
ZNode layer)
To attach a new frame to an existing scenegraph, then specify the root and layer parameters. The root should be an existing scenegraph, and the layer should be an existing layer that should be seen on this frame. A new camera and surface will be created, and the camera will be set to look at the layer. If root and layer are specified as null, then a new scenegraph will be created.
root - Existing root of scenegraph, or null for nonelayer - Existing layer of scenegraph, or null for nonegetRoot(),
getSurface(),
getCamera(),
getLayer()| Method Detail |
public ZCamera getCamera()
public ZSurface getSurface()
public ZRootNode getRoot()
public ZNode getLayer()
public ZBasicComponent getComponent()
public java.awt.event.WindowListener getWindowListener()
public ZEventHandler getPanEventHandler()
public ZEventHandler getZoomEventHandler()
public ZEventHandler getKeyEventHandler()
public void setLookAndFeel(int laf)
laf - The look and feel, can be WINDOWs_LAF, METAL_LAF, or MOTIF_LAFpublic static void main(java.lang.String[] s)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||