Package org.abego.treelayout.demo.swing
Class SwingDemo
java.lang.Object
org.abego.treelayout.demo.swing.SwingDemo
Demonstrates how to use the
TreeLayout
to render a tree in a Swing
application.
Intentionally the sample code is kept simple. I.e. it does not include stuff like anti-aliasing and other stuff one would add to make the output look nice.
Screenshot:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static TreeForTreeLayout
<TextInBox> getSampleTree
(String treeName) static void
Shows a dialog with a tree in a layout created byTreeLayout
, using the Swing componentTextInBoxTreePane
.private static void
showInDialog
(JComponent panel)
-
Constructor Details
-
SwingDemo
public SwingDemo()
-
-
Method Details
-
showInDialog
-
getSampleTree
-
main
Shows a dialog with a tree in a layout created byTreeLayout
, using the Swing componentTextInBoxTreePane
.- Parameters:
args
- args[0]: treeName (default="")
-