-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
1.4.1
-
x86
-
windows_2000
Name: jk109818 Date: 07/31/2002
FULL PRODUCT VERSION :
java version "1.4.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-b92)
Java HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode)
FULL OPERATING SYSTEM VERSION :
Microsoft Windows 2000
5.00.2195
Service Pack 2
A DESCRIPTION OF THE PROBLEM :
When I use JTable.setIntercellSpacing to change the margin
of the cells, it also affects the header. There is a gap
between the column headers.
It works fine with jdk1.3.1_01, so it seems to be a new bug
introduced in jdk1.4.0.
Try the source code with both 1.3 and 1.4 to see the
difference with the table header.
REGRESSION. Last worked in version 1.3.1
EXPECTED VERSUS ACTUAL BEHAVIOR :
Between the labels that are used to display the column
names, there is a gap of the same size as the cell margins.
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import java.awt.*;
import javax.swing.*;
public class Test extends JFrame {
public Test() {
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
JTable table = new JTable(new Object[0][],
new String[] { "column1", "column2", "column3" });
table.setIntercellSpacing(new Dimension(5, 5));
JScrollPane pane = new JScrollPane(table);
getContentPane().add(pane);
pack();
setVisible(true);
}
public static void main(String[] args) {
new Test();
}
}
---------- END SOURCE ----------
Release Regression From : 1.3.1
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: 145515)
======================================================================
- duplicates
-
JDK-4723012 1.4.0 REGRESSION: JTable column header is not properly centered.
- Closed