use of org.freeplane.features.DashVariant in project freeplane by freeplane.
the class NodeStyleController method getBorderDash.
public DashVariant getBorderDash(NodeModel node) {
final MapModel map = node.getMap();
final LogicalStyleController styleController = LogicalStyleController.getController(modeController);
final Collection<IStyle> style = styleController.getStyles(node);
final DashVariant borderDash = getBorderDash(map, style);
return borderDash;
}
use of org.freeplane.features.DashVariant in project freeplane by freeplane.
the class NodeStyleController method getBorderDash.
private DashVariant getBorderDash(final MapModel map, final Collection<IStyle> styleKeys) {
final MapStyleModel model = MapStyleModel.getExtension(map);
for (IStyle styleKey : styleKeys) {
final NodeModel styleNode = model.getStyleNode(styleKey);
if (styleNode == null) {
continue;
}
final NodeBorderModel borderModel = NodeBorderModel.getModel(styleNode);
if (borderModel == null) {
continue;
}
final DashVariant borderDash = borderModel.getBorderDash();
if (borderDash == null) {
continue;
}
return borderDash;
}
return DashVariant.DEFAULT;
}
Aggregations