所以,我的问题是:当选择“周长”从JComboBox时,我会怎样做,使标签(JTabbedPane的内召开)将显示在最前面?并与区域或其他选项卡类似。将JTabbedPane中的选项卡放在前面?
private void jComboBox1ActionPerformed(java.awt.event.ActionEvent evt) {
String selectedItem = jComboBox1.getSelectedItem().toString();
if(selectedItem != null)
{
//if perimeter option selected, show the tab for it
if(selectedItem.equals("Perimeter"))
{
//bring the permeter tab to the front, all contained within a tabbedPane
}
if(selectedItem.equals("Area"))
{
//bring the area tab to the front, all contained within a tabbedPane
}
}
}