freemind.view.mindmapview
public class MapView extends JPanel implements Printable
Nested Class Summary | |
---|---|
protected class | MapView.nodesDepthComparator This class sortes nodes by ascending depth of their paths to root. |
Constructor Summary | |
---|---|
MapView(MindMap model, Controller controller) |
Method Summary | |
---|---|
void | centerNode(NodeView node)
Problem: Before scrollRectToVisible is called, the node has the location (0,0), ie. the location first gets
calculated after the scrollpane is actually scrolled. |
protected void | collectLabels(NodeView source, HashMap labels) collect all existing labels in the current map. |
void | deselect(NodeView newSelected) |
MindMapArrowLink | detectCollision(Point p) |
Controller | getController() |
int | getMaxNodeWidth() |
MindMap | getModel() |
Dimension | getPreferredSize() |
protected NodeView | getRoot() |
NodeView | getSelected() |
ArrayList | getSelectedNodesSortedByY() |
LinkedList | getSelecteds() |
LinkedList | getSelectedsByDepth() |
ArrayList | getSelectedsSortedByY() |
int | getSiblingMaxLevel() |
float | getZoom() |
int | getZoomed(int number) |
void | initRoot() |
boolean | isPrinting() For nodes, they can ask, whether or not the width must be bigger to prevent the "..." at the output. |
boolean | isSelected(NodeView n) |
void | makeTheSelected(NodeView newSelected)
Add the node to the selection if it is not yet there, making it the focused selected node. |
void | move(KeyEvent e) |
void | moveToRoot() |
void | paintChildren(Graphics graphics)
P A I N T I N G **
|
protected void | paintClouds(NodeView source, Graphics graphics, int iterativeLevel) |
protected void | paintLinks(NodeView source, Graphics2D graphics, HashMap labels, HashSet LinkAlreadyVisited) |
int | print(Graphics graphics, PageFormat pageFormat, int pageIndex) |
void | scrollBy(int x, int y)
Scroll the viewport of the map to the south-west, i.e. scroll the map itself to the north-east. |
void | scrollNodeToVisible(NodeView node) |
void | scrollNodeToVisible(NodeView node, int extraWidth) |
void | selectAsTheOnlyOneSelected(NodeView newSelected)
Select the node, resulting in only that one being selected. |
void | selectBranch(NodeView newlySelectedNodeView, boolean extend)
Select the node and his descendants. |
boolean | selectContinuous(NodeView newSelected) |
void | setMoveCursor(boolean isHand) |
void | setSiblingMaxLevel(int level) |
void | setZoom(float zoom) |
void | toggleSelected(NodeView newSelected)
Add the node to the selection if it is not yet there, remove it otherwise. |
Returns: a LinkedList of NodeViews ordered by depth. nodes with greater depth occur first.
Parameters: iterativeLevel describes the n-th nested cloud that is to be painted.