|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jgraph.graph.BasicMarqueeHandler
uk.ac.essex.ia.graph.jgraph.IAMarqueeHandler
public class IAMarqueeHandler
The margue handler manages most of the events that are fired by the graph.
Date: 11-Jul-2002
Adapted from code by A. Gaudenz see JGrpah
You should have received a copy of GNU public license with this code.
If not please visit this site
Field Summary | |
---|---|
protected java.awt.Point |
current
|
protected com.jgraph.graph.PortView |
firstPort
|
protected com.jgraph.graph.PortView |
port
|
protected java.awt.Point |
start
|
Fields inherited from class com.jgraph.graph.BasicMarqueeHandler |
---|
currentPoint, lastVisibleRect, marqueeBounds, previousCursor, startPoint |
Constructor Summary | |
---|---|
IAMarqueeHandler(IAJGraph graph)
|
Method Summary | |
---|---|
com.jgraph.graph.PortView |
getSourcePortAt(java.awt.Point point)
|
protected com.jgraph.graph.PortView |
getTargetPortAt(java.awt.Point point)
Find a Cell at point and Return its first Port as a PortView |
boolean |
isForceMarqueeEvent(java.awt.event.MouseEvent e)
Override to Gain Control (for PopupMenu and ConnectMode) |
void |
mouseDragged(java.awt.event.MouseEvent e)
Find Port under Mouse and Repaint Connector |
void |
mouseMoved(java.awt.event.MouseEvent e)
Show Special Cursor if Over Port |
void |
mousePressed(java.awt.event.MouseEvent e)
Display PopupMenu or Remember Start Location and First Port |
void |
mouseReleased(java.awt.event.MouseEvent e)
Connect the First Port and the Current Port in the Graph or Repaint |
protected void |
paintConnector(java.awt.Color fg,
java.awt.Color bg,
java.awt.Graphics g)
Use Xor-Mode on Graphics to Paint Connector |
protected void |
paintPort(java.awt.Graphics g)
Use the Preview Flag to Draw a Highlighted Port |
Methods inherited from class com.jgraph.graph.BasicMarqueeHandler |
---|
overlay, paint |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.awt.Point start
protected java.awt.Point current
protected com.jgraph.graph.PortView port
protected com.jgraph.graph.PortView firstPort
Constructor Detail |
---|
public IAMarqueeHandler(IAJGraph graph)
Method Detail |
---|
public boolean isForceMarqueeEvent(java.awt.event.MouseEvent e)
isForceMarqueeEvent
in class com.jgraph.graph.BasicMarqueeHandler
e
-
public void mousePressed(java.awt.event.MouseEvent e)
mousePressed
in class com.jgraph.graph.BasicMarqueeHandler
e
- public void mouseDragged(java.awt.event.MouseEvent e)
mouseDragged
in class com.jgraph.graph.BasicMarqueeHandler
e
- public com.jgraph.graph.PortView getSourcePortAt(java.awt.Point point)
protected com.jgraph.graph.PortView getTargetPortAt(java.awt.Point point)
point
-
public void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased
in class com.jgraph.graph.BasicMarqueeHandler
e
- public void mouseMoved(java.awt.event.MouseEvent e)
mouseMoved
in class com.jgraph.graph.BasicMarqueeHandler
e
- protected void paintConnector(java.awt.Color fg, java.awt.Color bg, java.awt.Graphics g)
fg
- bg
- g
- protected void paintPort(java.awt.Graphics g)
g
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |