I am running into one weird problem. I have a JtextPane
inside a JscrollPane
which is showing large string in term of distribution list and it is properly wrapping code when I am running the program using eclipse but when I am running the same program in using java webstart it stopped wrapping the text.
Here is my code:
private JScrollPane displayResults(String distributionList) {
// TODO Auto-generated method stub
JTextPane textArea = new JTextPane();
textArea.setText(distributionList);
textArea.setEditable(false);
JScrollPane scrollPane = new JScrollPane(textArea);
scrollPane.setPreferredSize( new Dimension( 500, 500 ) );
return scrollPane;
}
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…