-
Bug
-
Resolution: Fixed
-
P3
-
1.4.0
-
tiger
-
x86
-
windows_2000
Name: rmT116609 Date: 06/18/2002
FULL PRODUCT VERSION :
java version "1.4.0_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0_01-b03)
Java HotSpot(TM) Client VM (build 1.4.0_01-b03, mixed mode)
FULL OPERATING SYSTEM VERSION : Microsoft Windows 2000 [Version 5.00.2195]
DESCRIPTION OF THE PROBLEM :
The color of the JSplitPane divider is inconsistent when used within a JTabbedPane.
For exemple, if you put a JSplitPane which contains a JTree or a JTable on a JTabbedPane, the color of the divider changes when navigating between tab pages.
The color is ok when no node has been selected (or no row if it is a JTable)But as soon as a node has been selected, if you go from a tab page to another, the color of the divider turns purple instead of remaining grey.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1.Click on a leaf of the JTree on the left or a row of the JTable on the right
2.Click on the 2nd tab page
3.Click on the 1st tab page
The problem is not reproducible on Windows 2000 using JDK1.3.1_03.
EXPECTED VERSUS ACTUAL BEHAVIOR :
The color of the divider should remain grey. It now turns purple.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.awt.*;
public class TestSplit extends JFrame
{
private JTabbedPane mTabbedPane;
private JTree mTree;
private JTable mTable;
private JPanel mEmptyPanel;
private JSplitPane mSplitPane;
public TestSplit()
{
getContentPane().setLayout(new BorderLayout());
mTree = new JTree();
mTable = new JTable(new String[][]{{"This", "is"},{"a", "bug"}},new String[]
{"Column 1","Column 2"});
mEmptyPanel = new JPanel();
mSplitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, mTree,mTable);
mTabbedPane = new JTabbedPane();
mTabbedPane.addTab("Tab one", mSplitPane);
mTabbedPane.addTab("Tab two", mEmptyPanel);
getContentPane().add(mTabbedPane);
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setSize(600,400);
setVisible(true);
}
public static void main (String args[])
{
TestSplit lApplication = new TestSplit();
}
}
---------- END SOURCE ----------
Release Regression From : 1.3.1_03
The above release value was the last known release where this
bug was known to work. Since then there has been a regression.
(Review ID: 153737)
======================================================================
- relates to
-
JDK-6311648 Regression-test javax/swing/JTabbedPane/4703690/bug4703690.java fails
- Closed