-
Bug
-
Resolution: Fixed
-
P3
-
1.4.0
-
hopper
-
generic
-
generic
Name: jk109818 Date: 12/10/2001
java version "1.4.0-beta3"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta3-b84)
Java HotSpot(TM) Client VM (build 1.4.0-beta3-b84, mixed mode)
The JFileChooser details view does not consider the font size in
determining row height, for both Metal and Windows L&Fs. For large
fonts, the text will be chopped off and unreadable. On my system,
the top of the file icon is chopped off at any font size.
Example code follows.
import javax.swing.*;
import java.util.Enumeration;
import java.awt.Font;
import javax.swing.plaf.FontUIResource;
public class JFileChooserBug {
public static void main(String args[]) {
setFonts();
JFileChooser fc = new JFileChooser();
fc.showOpenDialog(null);
}
public static void setFonts() {
UIDefaults defaults = UIManager.getDefaults();
Enumeration keys = defaults.keys();
while(keys.hasMoreElements()) {
Object key = keys.nextElement();
if(defaults.get(key) instanceof Font)
UIManager.put(key, new FontUIResource(new Font("Courier",
Font.BOLD, 30)));
}
}
}
(Review ID: 136635)
======================================================================
- relates to
-
JDK-4825411 JFileChooser issues in details view
-
- Resolved
-