|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Canvas
|
+--com.rolemodelsoft.drawlet.awt.DrawingCanvasComponent
This provides basic functionality necessary to provide a meaningful working version of a DrawingCanvas that can be tied to a Component in an AWT Application. It is expected that this would serve as the base for these sort of Components, but not required.
| Field Summary | |
protected DrawingCanvas |
canvas
The drawing canvas we are displaying/manipulating. |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
| Constructor Summary | |
DrawingCanvasComponent()
Create a default DrawingCanvasComponent. |
|
DrawingCanvasComponent(DrawingCanvas canvas)
Constructs a new DrawingCanvasComponent, associating
it with the given DrawingCanvas |
|
| Method Summary | |
DrawingCanvas |
getCanvas()
|
java.awt.Dimension |
getPreferredSize()
Gets the preferred size of the receiver. |
boolean |
isFocusTraversable()
Tell the AWT I am able to receive the focus. |
void |
paint(java.awt.Graphics g)
Paints the receiver. |
void |
repaint(java.awt.Rectangle rectangle)
Repaints part of the receiver. |
protected void |
setCanvas(DrawingCanvas canvas)
Set the DrawingCanvas the receiver is associated with. |
| Methods inherited from class java.awt.Canvas |
addNotify |
| 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,
deliverEvent,
disable,
disableEvents,
dispatchEvent,
doLayout,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getAlignmentX,
getAlignmentY,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentAt,
getComponentAt,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputContext,
getInputMethodRequests,
getLocale,
getLocation,
getLocation,
getLocationOnScreen,
getMaximumSize,
getMinimumSize,
getName,
getParent,
getPeer,
getSize,
getSize,
getToolkit,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
invalidate,
isDisplayable,
isDoubleBuffered,
isEnabled,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
layout,
list,
list,
list,
list,
list,
locate,
location,
lostFocus,
minimumSize,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
paramString,
postEvent,
preferredSize,
prepareImage,
prepareImage,
print,
printAll,
processComponentEvent,
processEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removeNotify,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setEnabled,
setFont,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus,
update,
validate |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Field Detail |
protected DrawingCanvas canvas
| Constructor Detail |
public DrawingCanvasComponent()
DrawingCanvasComponent.public DrawingCanvasComponent(DrawingCanvas canvas)
DrawingCanvasComponent, associating
it with the given DrawingCanvascanvas - the canvas this component will be associated with.| Method Detail |
public DrawingCanvas getCanvas()
public java.awt.Dimension getPreferredSize()
public boolean isFocusTraversable()
true if the
receiver is focus traversable;
false otherwise.public void paint(java.awt.Graphics g)
g - the specified Graphics windowpublic void repaint(java.awt.Rectangle rectangle)
rectangle - is the region to be repaintedprotected void setCanvas(DrawingCanvas canvas)
DrawingCanvas the receiver is associated with.canvas - the DrawingCanvas we should draw/manipulate
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||