The javax.swing.JTable.set/getGridColor() javadoc states that default color is
"Color.gray". This is not true for Metal L&F, for example.
The statement about default color should be removed since it's look
and feel dependent.
Test example:
import java.awt.*;
import javax.swing.*;
import javax.swing.table.*;
public class jtable {
public static void main (String [] args) {
JTable t = new JTable();
System.out.println(UIManager.getLookAndFeel());
System.out.println(t.getGridColor());
System.out.println(Color.gray);
}
}
Test output under jdk1.4:
bash-2.00$ /usr/local/java/jdk1.4/solsparc/bin/java jtable
[The Java(tm) Look and Feel - javax.swing.plaf.metal.MetalLookAndFeel]
javax.swing.plaf.ColorUIResource[r=153,g=153,b=153]
java.awt.Color[r=128,g=128,b=128]
"Color.gray". This is not true for Metal L&F, for example.
The statement about default color should be removed since it's look
and feel dependent.
Test example:
import java.awt.*;
import javax.swing.*;
import javax.swing.table.*;
public class jtable {
public static void main (String [] args) {
JTable t = new JTable();
System.out.println(UIManager.getLookAndFeel());
System.out.println(t.getGridColor());
System.out.println(Color.gray);
}
}
Test output under jdk1.4:
bash-2.00$ /usr/local/java/jdk1.4/solsparc/bin/java jtable
[The Java(tm) Look and Feel - javax.swing.plaf.metal.MetalLookAndFeel]
javax.swing.plaf.ColorUIResource[r=153,g=153,b=153]
java.awt.Color[r=128,g=128,b=128]