hsun
September 26, 2019, 3:53am
1
I placed a JTabbedPane inside the InstallationNodeView, but it showed no border.
If placed JPanel like this,
JPanel panel_5 = new JPanel();
panel_5.setBorder(new TitledBorder(null, “Group1”, TitledBorder.LEADING, TitledBorder.TOP, null, null));
JPanel is no border too.
This works for me:
JPanel panel = new JPanel();
TitledBorder border = new TitledBorder("test");
border.setBorder(BorderFactory.createLineBorder(Color.GRAY));
panel.setBorder(border);
I think the thing is that borders are set to white in respect to the Basic UI Design. Changing a Titled Borders border color does the trick.
The LookAndFeel
for the e-series doesn’t give a TitledBorder
a LineBorder
by default, so as you pointed out you have to give it a line border separately. The LookAndFeel
for the CB3 does give a TitledBorder
a LineBorder
by default.
hsun
September 27, 2019, 1:49am
4
After add color to the border, It works now, thanks.