diff options
author | Mark Wielaard <mark@klomp.org> | 2005-10-30 22:43:29 +0000 |
---|---|---|
committer | Mark Wielaard <mark@klomp.org> | 2005-10-30 22:43:29 +0000 |
commit | cf8721ee20060a0db284cda3f37f020ac27f1644 (patch) | |
tree | b779913feb9ca9245b96ea1cf000ff987001bc23 | |
parent | 6ac5fb31d31416d0cd4ad6ee47fa062b8cd1447b (diff) | |
download | classpath-cf8721ee20060a0db284cda3f37f020ac27f1644.tar.gz |
* examples/gnu/classpath/examples/swing/Demo.java (static): Set look
and feel before showing dialog. Clean up message text.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | examples/gnu/classpath/examples/swing/Demo.java | 28 |
2 files changed, 21 insertions, 12 deletions
@@ -1,5 +1,10 @@ 2005-10-30 Mark Wielaard <mark@klomp.org> + * examples/gnu/classpath/examples/swing/Demo.java (static): Set look + and feel before showing dialog. Clean up message text. + +2005-10-30 Mark Wielaard <mark@klomp.org> + * javax/swing/text/PlainView.java (determineMaxLineLength): Get correct lenght of text. (drawLine): Throw AssertionError on unexpected bad location. diff --git a/examples/gnu/classpath/examples/swing/Demo.java b/examples/gnu/classpath/examples/swing/Demo.java index ddaa344c5..6eec946a6 100644 --- a/examples/gnu/classpath/examples/swing/Demo.java +++ b/examples/gnu/classpath/examples/swing/Demo.java @@ -42,17 +42,23 @@ public class Demo { if (System.getProperty("swing.defaultlaf") == null) { + UIManager.setLookAndFeel(new GNULookAndFeel()); + StringBuffer text = new StringBuffer(); - text.append("\tYou may change the Look and Feel of this\n"); - text.append("\tDemo by setting the system property\n"); - text.append("\t-Dswing.defaultlaf=<LAFClassName>\n\n"); - text.append("\tPossible values for <LAFClassName> are:\n"); - text.append("\t * javax.swing.plaf.metal.MetalLookAndFeel\n"); - text.append("\t\tthe default Java L&F\n"); - text.append("\t * gnu.classpath.examples.swing.GNULookAndFeel\n"); - text.append("\tthe GNU Look and Feel\n"); - text.append("\t(derived from javax.swing.plaf.basic.BasicLookAndFeel\n\n"); - text.append("\tthe default is gnu.classpath.examples.swing.GNULookAndFeel\n"); + text.append("You may change the Look and Feel of this\n"); + text.append("Demo by setting the system property\n"); + text.append("-Dswing.defaultlaf=<LAFClassName>\n"); + text.append("\n"); + text.append("Possible values for <LAFClassName> are:\n"); + text.append("\n"); + text.append("* javax.swing.plaf.metal.MetalLookAndFeel\n"); + text.append(" the default GNU Classpath L&F\n"); + text.append("\n"); + text.append("* gnu.classpath.examples.swing.GNULookAndFeel\n"); + text.append(" the GNU Look and Feel\n"); + text.append(" (derived from javax.swing.plaf.basic.BasicLookAndFeel)\n"); + text.append("\n"); + text.append("the default is gnu.classpath.examples.swing.GNULookAndFeel\n"); JEditorPane textPane = new JEditorPane(); // temporary hack, preferred size should be computed by the // component @@ -61,8 +67,6 @@ public class Demo JOptionPane.showMessageDialog(null, textPane, "Look and Feel notice", JOptionPane.INFORMATION_MESSAGE); - - UIManager.setLookAndFeel(new GNULookAndFeel()); } } catch (UnsupportedLookAndFeelException e) |