att.grappa
Interface GrappaListener

All Known Implementing Classes:
GrappaAdapter

public interface GrappaListener

An interface for handling mouse-related activity that occurs on a graph.

Version:
1.2, 21 Aug 2005; Copyright 1996 - 2005 by AT&T Corp.
Author:
John Mocenigo, Research @ AT&T Labs

Method Summary
 void grappaClicked(Subgraph subg, Element elem, GrappaPoint pt, int modifiers, int clickCount, GrappaPanel panel)
          The method called when a single mouse click occurs on a displayed subgraph.
 void grappaDragged(Subgraph subg, GrappaPoint currentPt, int currentModifiers, Element pressedElem, GrappaPoint pressedPt, int pressedModifiers, GrappaBox outline, GrappaPanel panel)
          The method called when a mouse drag occurs on a displayed subgraph.
 void grappaPressed(Subgraph subg, Element elem, GrappaPoint pt, int modifiers, GrappaPanel panel)
          The method called when a mouse press occurs on a displayed subgraph.
 void grappaReleased(Subgraph subg, Element elem, GrappaPoint pt, int modifiers, Element pressedElem, GrappaPoint pressedPt, int pressedModifiers, GrappaBox outline, GrappaPanel panel)
          The method called when a mouse release occurs on a displayed subgraph.
 java.lang.String grappaTip(Subgraph subg, Element elem, GrappaPoint pt, int modifiers, GrappaPanel panel)
          The method called when a element tooltip is needed.
 

Method Detail

grappaClicked

void grappaClicked(Subgraph subg,
                   Element elem,
                   GrappaPoint pt,
                   int modifiers,
                   int clickCount,
                   GrappaPanel panel)
The method called when a single mouse click occurs on a displayed subgraph.

Parameters:
subg - displayed subgraph where action occurred
elem - subgraph element in which action occurred
pt - the point where the action occurred (graph coordinates)
modifiers - mouse modifiers in effect
panel - specific panel where the action occurred

grappaPressed

void grappaPressed(Subgraph subg,
                   Element elem,
                   GrappaPoint pt,
                   int modifiers,
                   GrappaPanel panel)
The method called when a mouse press occurs on a displayed subgraph.

Parameters:
subg - displayed subgraph where action occurred
elem - subgraph element in which action occurred
pt - the point where the action occurred (graph coordinates)
modifiers - mouse modifiers in effect
panel - specific panel where the action occurred

grappaReleased

void grappaReleased(Subgraph subg,
                    Element elem,
                    GrappaPoint pt,
                    int modifiers,
                    Element pressedElem,
                    GrappaPoint pressedPt,
                    int pressedModifiers,
                    GrappaBox outline,
                    GrappaPanel panel)
The method called when a mouse release occurs on a displayed subgraph.

Parameters:
subg - displayed subgraph where action occurred
elem - subgraph element in which action occurred
pt - the point where the action occurred (graph coordinates)
modifiers - mouse modifiers in effect
pressedElem - subgraph element in which the most recent mouse press occurred
pressedPt - the point where the most recent mouse press occurred (graph coordinates)
pressedModifiers - mouse modifiers in effect when the most recent mouse press occurred
outline - enclosing box specification from the previous drag position (for XOR reset purposes)
panel - specific panel where the action occurred

grappaDragged

void grappaDragged(Subgraph subg,
                   GrappaPoint currentPt,
                   int currentModifiers,
                   Element pressedElem,
                   GrappaPoint pressedPt,
                   int pressedModifiers,
                   GrappaBox outline,
                   GrappaPanel panel)
The method called when a mouse drag occurs on a displayed subgraph.

Parameters:
subg - displayed subgraph where action occurred
currentPt - the current drag point
currentModifiers - the current drag mouse modifiers
pressedElem - subgraph element in which the most recent mouse press occurred
pressedPt - the point where the most recent mouse press occurred (graph coordinates)
pressedModifiers - mouse modifiers in effect when the most recent mouse press occurred
outline - enclosing box specification from the previous drag position (for XOR reset purposes)
panel - specific panel where the action occurred

grappaTip

java.lang.String grappaTip(Subgraph subg,
                           Element elem,
                           GrappaPoint pt,
                           int modifiers,
                           GrappaPanel panel)
The method called when a element tooltip is needed.

Parameters:
subg - displayed subgraph where action occurred
elem - subgraph element in which action occurred
pt - the point where the action occurred (graph coordinates)
modifiers - mouse modifiers in effect
panel - specific panel where the action occurred
Returns:
the tip to be displayed or null