public void setTree(Tree root) {
if ( root!=null ) {
boolean useIdentity = true; // compare node identity
this.treeLayout =
new TreeLayout<Tree>(new TreeLayoutAdaptor(root),
new TreeViewer.VariableExtentProvide(this),
new DefaultConfiguration<Tree>(gapBetweenLevels,
gapBetweenNodes),
useIdentity);
// Let the UI display this new AST.
updatePreferredSize();
}
else {
this.treeLayout = null;
repaint();
}
}
TreeViewer.java 文件源码
java
阅读 28
收藏 0
点赞 0
评论 0
项目:Scratch-ApuC
作者:
评论列表
文章目录