uci.gef
Class ModeBroom

java.lang.Object
  |
  +--uci.gef.Mode
        |
        +--uci.gef.ModeBroom

public class ModeBroom
extends Mode

See Also:
Serialized Form

Field Summary
 int BROOM_WIDTH
           
 int DOWNWARD
           
 int EVEN_SPACE
           
 int FUDGE
           
 Font HINT_FONT
           
 int LEFTWARD
           
 int MAX_TOUCHED
           
 int ORIG
           
 int PACK
           
 int RIGHTWARD
           
 int SMALL_BROOM_WIDTH
           
 int SPREAD
           
 int UNDEFINED
           
 int UPWARD
           
 
Fields inherited from class uci.gef.Mode
_args, _editor
 
Constructor Summary
ModeBroom()
          Construct a new ModeBroom instance.
ModeBroom(Editor par)
          Construct a new ModeBroom with the given parent.
 
Method Summary
 void addNewItems()
           
 void doDistibute(boolean alignToGrid, boolean doCentering)
           
 String instructions()
          Reply a string of instructions that should be shown in the statusbar when this mode starts.
 void keyPressed(KeyEvent ke)
           
 void mouseDragged(MouseEvent me)
          On mouse dragging, stretch the selection rectangle.
 void mousePressed(MouseEvent me)
          Handle mouse down events by preparing for a drag.
 void mouseReleased(MouseEvent me)
          On mouse up, select or toggle the selection of items under the mouse or in the selection rectangle.
 void paint(Graphics g)
          Paint this mode by painting the selection rectangle if appropriate.
 Vector touching()
           
 
Methods inherited from class uci.gef.Mode
canExit, done, getArg, getArgs, getEditor, getInitialCursor, keyReleased, keyTyped, mouseClicked, mouseEntered, mouseExited, mouseMoved, print, setArg, setArgs, setCursor, setEditor, start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

UNDEFINED

public final int UNDEFINED

UPWARD

public final int UPWARD

DOWNWARD

public final int DOWNWARD

RIGHTWARD

public final int RIGHTWARD

LEFTWARD

public final int LEFTWARD

BROOM_WIDTH

public final int BROOM_WIDTH

SMALL_BROOM_WIDTH

public final int SMALL_BROOM_WIDTH

FUDGE

public final int FUDGE

MAX_TOUCHED

public final int MAX_TOUCHED

EVEN_SPACE

public final int EVEN_SPACE

PACK

public final int PACK

SPREAD

public final int SPREAD

ORIG

public final int ORIG

HINT_FONT

public final Font HINT_FONT
Constructor Detail

ModeBroom

public ModeBroom(Editor par)
Construct a new ModeBroom with the given parent.

ModeBroom

public ModeBroom()
Construct a new ModeBroom instance. Its parent must be set before this instance can be used.
Method Detail

mousePressed

public void mousePressed(MouseEvent me)
Handle mouse down events by preparing for a drag. If the mouse down event happens on a handle or an already selected object, and the shift key is not down, then go to ModeModify. If the mouse down event happens on a port, to to ModeCreateEdge.
Overrides:
mousePressed in class Mode

mouseDragged

public void mouseDragged(MouseEvent me)
On mouse dragging, stretch the selection rectangle.
Overrides:
mouseDragged in class Mode

mouseReleased

public void mouseReleased(MouseEvent me)
On mouse up, select or toggle the selection of items under the mouse or in the selection rectangle.
Overrides:
mouseReleased in class Mode

addNewItems

public void addNewItems()

keyPressed

public void keyPressed(KeyEvent ke)
Overrides:
keyPressed in class Mode

doDistibute

public void doDistibute(boolean alignToGrid,
                        boolean doCentering)

touching

public Vector touching()

instructions

public String instructions()
Reply a string of instructions that should be shown in the statusbar when this mode starts.
Overrides:
instructions in class Mode

paint

public void paint(Graphics g)
Paint this mode by painting the selection rectangle if appropriate.
Overrides:
paint in class Mode