use of org.freeplane.view.swing.map.NodeView in project freeplane by freeplane.
the class NodeSelector method selectSingleNode.
public void selectSingleNode(MouseEvent e) {
final NodeView nodeV = getRelatedNodeView(e);
final Controller controller = Controller.getCurrentController();
if (!((MapView) controller.getMapViewManager().getMapViewComponent()).isSelected(nodeV)) {
controller.getSelection().selectAsTheOnlyOneSelected(nodeV.getModel());
}
}
use of org.freeplane.view.swing.map.NodeView in project freeplane by freeplane.
the class Node method toggleSelected.
public void toggleSelected() {
final NodeView node = getNodeView();
node.getModel().setFolded(!node.getModel().isFolded());
}
use of org.freeplane.view.swing.map.NodeView in project freeplane by freeplane.
the class LatexExtension method setEquation.
public void setEquation(final String equation) {
this.equation = equation;
for (final NodeView nodeView : viewers) {
final LatexViewer comp = (LatexViewer) nodeView.getContent(LatexNodeHook.VIEWER_POSITION);
comp.setModel(this);
}
}
use of org.freeplane.view.swing.map.NodeView in project freeplane by freeplane.
the class LatexNodeHook method onViewRemoved.
public void onViewRemoved(final Container container) {
final NodeView nodeView = (NodeView) container;
final LatexExtension latexExtension = (LatexExtension) nodeView.getModel().getExtension(LatexExtension.class);
if (latexExtension == null) {
return;
}
deleteViewer(latexExtension, nodeView);
}
use of org.freeplane.view.swing.map.NodeView in project freeplane by freeplane.
the class LatexNodeHook method add.
@Override
public void add(final NodeModel node, final IExtension extension) {
final LatexExtension latexExtension = (LatexExtension) extension;
for (NodeModel nodeClone : node.clones()) {
for (final INodeView iNodeView : nodeClone.getViewers()) {
final NodeView view = (NodeView) iNodeView;
createViewer(latexExtension, view);
}
}
super.add(node, extension);
}
Aggregations