Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用本教程在 JavaFX 2 中创建了自己的 TreeView 。但是我想隐藏我的根节点。
现在的样子:
它应该看起来如何:
谢谢,穆基
隐藏根项目可以通过
treeView.setShowRoot(false);