examples.shapemover_1
Class SMCanvas

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Canvas
              |
              +--examples.shapemover_1.SMCanvas

public class SMCanvas
extends Canvas
implements MouseListener, MouseMotionListener


Field Summary
 (package private) Rectanglearea
           
 (package private) BufferedImagebi
           
 (package private) Graphics2Dbig
           
 (package private) TexturePaintfillPolka
           
 (package private) booleanfirstTime
           
 (package private) intlast_x
           
 (package private) intlast_y
           
 (package private) booleanpressOut
           
 (package private) Rectanglerect
           
 (package private) TexturePaintstrokePolka
           

Fields inherited from class java.awt.Component
TOP_ALIGNMENT, CENTER_ALIGNMENT, BOTTOM_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT

Constructor Summary
SMCanvas()
           

Method Summary
 (package private) booleancheckRect()
           
 voidmouseClicked(MouseEvent e)
           
 voidmouseDragged(MouseEvent e)
           
 voidmouseEntered(MouseEvent e)
           
 voidmouseExited(MouseEvent e)
           
 voidmouseMoved(MouseEvent e)
           
 voidmousePressed(MouseEvent e)
           
 voidmouseReleased(MouseEvent e)
           
 voidpaint(Graphics g)
           
 voidupdate(Graphics g)
           
 voidupdateLocation(MouseEvent e)
           

Methods inherited from class java.awt.Canvas
addNotify, getAccessibleContext

Methods inherited from class java.awt.Component
getName, setName, getParent, getPeer, setDropTarget, getDropTarget, getGraphicsConfiguration, getTreeLock, getToolkit, isValid, isDisplayable, isVisible, isShowing, isEnabled, setEnabled, enable, enable, disable, isDoubleBuffered, enableInputMethods, setVisible, show, show, hide, getForeground, setForeground, getBackground, setBackground, getFont, setFont, getLocale, setLocale, getColorModel, getLocation, getLocationOnScreen, location, setLocation, move, setLocation, getSize, size, setSize, resize, setSize, resize, getBounds, bounds, setBounds, reshape, setBounds, getX, getY, getWidth, getHeight, getBounds, getSize, getLocation, isOpaque, isLightweight, getPreferredSize, preferredSize, getMinimumSize, minimumSize, getMaximumSize, getAlignmentX, getAlignmentY, doLayout, layout, validate, invalidate, getGraphics, getFontMetrics, setCursor, getCursor, paintAll, repaint, repaint, repaint, repaint, print, printAll, imageUpdate, createImage, createImage, prepareImage, prepareImage, checkImage, checkImage, contains, inside, contains, getComponentAt, locate, getComponentAt, deliverEvent, dispatchEvent, postEvent, addComponentListener, removeComponentListener, addFocusListener, removeFocusListener, addHierarchyListener, removeHierarchyListener, addHierarchyBoundsListener, removeHierarchyBoundsListener, addKeyListener, removeKeyListener, addMouseListener, removeMouseListener, addMouseMotionListener, removeMouseMotionListener, addInputMethodListener, removeInputMethodListener, getListeners, getInputMethodRequests, getInputContext, enableEvents, disableEvents, coalesceEvents, processEvent, processComponentEvent, processFocusEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processInputMethodEvent, processHierarchyEvent, processHierarchyBoundsEvent, handleEvent, mouseDown, mouseDrag, mouseUp, mouseMove, mouseEnter, mouseExit, keyDown, keyUp, action, removeNotify, gotFocus, lostFocus, isFocusTraversable, requestFocus, transferFocus, nextFocus, hasFocus, add, remove, paramString, toString, list, list, list, list, list, addPropertyChangeListener, removePropertyChangeListener, addPropertyChangeListener, removePropertyChangeListener, firePropertyChange, setComponentOrientation, getComponentOrientation

Methods inherited from class java.lang.Object
getClass, hashCode, equals, clone, notify, notifyAll, wait, wait, wait, finalize

Field Detail

area

Rectangle area

bi

BufferedImage bi

big

Graphics2D big

fillPolka

TexturePaint fillPolka

firstTime

boolean firstTime

last_x

int last_x

last_y

int last_y

pressOut

boolean pressOut

rect

Rectangle rect

strokePolka

TexturePaint strokePolka
Constructor Detail

SMCanvas

public SMCanvas()
Method Detail

checkRect

boolean checkRect()

mouseClicked

public void mouseClicked(MouseEvent e)

mouseDragged

public void mouseDragged(MouseEvent e)

mouseEntered

public void mouseEntered(MouseEvent e)

mouseExited

public void mouseExited(MouseEvent e)

mouseMoved

public void mouseMoved(MouseEvent e)

mousePressed

public void mousePressed(MouseEvent e)

mouseReleased

public void mouseReleased(MouseEvent e)

paint

public void paint(Graphics g)

update

public void update(Graphics g)

updateLocation

public void updateLocation(MouseEvent e)

Association Links

to Class java.awt.Rectangle

to Class java.awt.image.BufferedImage

to Class java.awt.Graphics2D

to Class java.awt.TexturePaint

to Class java.awt.Rectangle