com.jgoodies.looks.plastic
public final class PlasticTreeUI extends BasicTreeUI
TreeUI
.
It provides two line styles: angled dashed lines, or no lines at all.
By default, lines are drawn.
You can change the line style by setting a client property. The property key and values are a subset of the values used by the Metal L&F tree. To hide lines use one of the following:
JTree tree1 = new JTree(); tree1.putClientProperty("JTree.lineStyle", "None"); JTree tree2 = new JTree(); tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY, Options.TREE_LINE_STYLE_NONE_VALUE);Although lines are shown by default, you could code:
JTree tree1 = new JTree(); tree1.putClientProperty("JTree.lineStyle", "Angled"); JTree tree2 = new JTree(); tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY, Options.TREE_LINE_STYLE_ANGLED_VALUE);
Version: $Revision: 1.5 $
Method Summary | |
---|---|
static ComponentUI | createUI(JComponent b) |
protected void | drawCentered(Component c, Graphics graphics, Icon icon, int x, int y) |
void | installUI(JComponent c) |
protected void | paintHorizontalLine(Graphics g, JComponent c, int y, int left, int right) |
protected void | paintVerticalLine(Graphics g, JComponent c, int x, int top, int bottom) |
void | uninstallUI(JComponent c) |