CH.ifa.draw.applet
Class DrawApplet
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- java.awt.Panel
-
- java.applet.Applet
-
- javax.swing.JApplet
-
- CH.ifa.draw.applet.DrawApplet
-
- All Implemented Interfaces:
- DrawingEditor, PaletteListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible, javax.swing.RootPaneContainer
- Direct Known Subclasses:
- JavaDrawApplet, NothingApplet, PertApplet
public class DrawApplet extends javax.swing.JApplet implements DrawingEditor, PaletteListener
DrawApplication defines a standard presentation for a drawing editor that is run as an applet. The presentation is customized in subclasses.Supported applet parameters:
DRAWINGS: a blank separated list of drawing names that is shown in the drawings choice.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.StringIMAGES
-
Constructor Summary
Constructors Constructor and Description DrawApplet()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description Drawingdrawing()Gets the current drawing.voidinit()Initializes the applet and creates its contents.voidpaletteUserOver(PaletteButton button, boolean inside)Handles when the mouse enters or leaves a palette button.voidpaletteUserSelected(PaletteButton button)Handles a user selection in the palette.voidselectionChanged(DrawingView view)Handles a change of the current selection.Tooltool()Gets the current tool.voidtoolDone()Sets the default tool of the editor.DrawingViewview()Gets the current drawing view.-
Methods inherited from class javax.swing.JApplet
getAccessibleContext, getContentPane, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, remove, repaint, setContentPane, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setTransferHandler, update
-
Methods inherited from class java.applet.Applet
destroy, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, isValidateRoot, newAudioClip, play, play, resize, resize, setStub, showStatus, start, stop
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, dispatchEvent, enable, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocusInWindow, reshape, revalidate, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface CH.ifa.draw.framework.DrawingEditor
showStatus
-
-
-
-
Field Detail
-
IMAGES
public static final java.lang.String IMAGES
- See Also:
- Constant Field Values
-
-
Method Detail
-
init
public void init()
Initializes the applet and creates its contents.- Overrides:
initin classjava.applet.Applet
-
paletteUserSelected
public void paletteUserSelected(PaletteButton button)
Handles a user selection in the palette.- Specified by:
paletteUserSelectedin interfacePaletteListener- See Also:
PaletteListener
-
paletteUserOver
public void paletteUserOver(PaletteButton button, boolean inside)
Handles when the mouse enters or leaves a palette button.- Specified by:
paletteUserOverin interfacePaletteListener- See Also:
PaletteListener
-
drawing
public Drawing drawing()
Gets the current drawing.- Specified by:
drawingin interfaceDrawingEditor- See Also:
DrawingEditor
-
tool
public Tool tool()
Gets the current tool.- Specified by:
toolin interfaceDrawingEditor- See Also:
DrawingEditor
-
view
public DrawingView view()
Gets the current drawing view.- Specified by:
viewin interfaceDrawingEditor- See Also:
DrawingEditor
-
toolDone
public void toolDone()
Sets the default tool of the editor.- Specified by:
toolDonein interfaceDrawingEditor- See Also:
DrawingEditor
-
selectionChanged
public void selectionChanged(DrawingView view)
Handles a change of the current selection. Updates all menu items that are selection sensitive.- Specified by:
selectionChangedin interfaceDrawingEditor- See Also:
DrawingEditor
-
-
DataMelt 3.0 © DataMelt by jWork.ORG