org.problets.lib.conceptmap.view.userbuilt
Class TempUserBuiltNodeView
java.lang.Object
org.problets.lib.conceptmap.view.NodeView
org.problets.lib.conceptmap.view.userbuilt.UserBuiltNodeView
org.problets.lib.conceptmap.view.userbuilt.TempUserBuiltNodeView
public class TempUserBuiltNodeView
- extends UserBuiltNodeView
Derived from UserBuiltNodeView. Adds to the functionality
of user-built node view in order to handle a temporary
user-built node view.
- Author:
- Adrian Maries
Method Summary |
static void |
main(java.lang.String[] args)
|
void |
setArbitraryCoord(int xPos,
int yPos,
int cellWidth,
int cellHeight)
Sets the current x-coordinates and y-coordinates (start and end)
of the temporary node view using the coordinates of the mouse cursor
and the width and height of the cell as arguments. |
Methods inherited from class org.problets.lib.conceptmap.view.NodeView |
draw, findNode, getChildLink, getChildNode, getCurrentXEnd, getCurrentXStart, getCurrentYEnd, getCurrentYStart, getIndex, getIsExpanded, getIsHighlighted, getIsVisible, getMaxHeightOfDescendants, getMaxWidthOfDescendants, getMouseoverVisible, getMouseoverVisibleNode, getNodeModel, getNumChildren, getParent, handleMouseClicked, handleMouseDragged, handleMouseMoved, handleMousePressed, handleMouseReleased, isOnNode, layout, paintMouseover, setCoord, setExpandedUpToDepth, setIsHighlighted, setIsHighlightedAncestorPath, setIsLastPressed, setIsVisible, setLinksVisible, setMouseoverVisible, setParent, setTextFont |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TempUserBuiltNodeView
public TempUserBuiltNodeView(UserBuiltNodeView parent,
UserBuiltNodeModel nodeModel)
- Creates a TempUserBuiltNodeView object using the parent node
view and the corresponding model as arguments.
- Parameters:
parent
- this node view's parentnodeModel
- the model representing this node view
setArbitraryCoord
public void setArbitraryCoord(int xPos,
int yPos,
int cellWidth,
int cellHeight)
- Sets the current x-coordinates and y-coordinates (start and end)
of the temporary node view using the coordinates of the mouse cursor
and the width and height of the cell as arguments. The width and
height of the cell are used (not the ones of the node) because we
want the temporary nodes to be larger than the other nodes.
- Parameters:
xPos
- the x-coordinate of the center of the node viewyPos
- the y-coordinate of the center of the node viewcellWidth
- the width of a cell in the gridcellHeight
- the height of a cell in the grid
main
public static void main(java.lang.String[] args)