Test case:
import javax.swing.*;
import java.awt.*;
public class testlist
{
public static void main(String[] args)
{
JFrame f = new JFrame();
DefaultListModel v = new DefaultListModel();
v.addElement("alsdkfj");
v.addElement("lasdkfj");
v.addElement("owieur");
v.addElement("weoiru");
v.addElement("lskdfj");
v.addElement("zcxvn");
v.addElement("zxcvlkzvm");
JList a = new JList(v);
a.setVisibleRowCount(2);
JScrollPane p = new JScrollPane(a);
a.setLayoutOrientation(JList.HORIZONTAL_WRAP);
f.getContentPane().add(p);
f.pack();
f.show();
}
}
The items in the list should be wrapped vertically, not horizontally.
--
Summary: JList not respecting LayoutOrientation
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: SWING
AssignedTo: graydon at redhat dot com
ReportedBy: kho at redhat dot com
CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20707