]> gitweb.fperrin.net Git - Dictionary.git/blob - jars/icu4j-4_4_2-src/tools/misc/src/com/ibm/icu/dev/tool/ime/IMETest.java
go
[Dictionary.git] / jars / icu4j-4_4_2-src / tools / misc / src / com / ibm / icu / dev / tool / ime / IMETest.java
1 /*\r
2  *******************************************************************************\r
3  * Copyright (C) 2004-2010, International Business Machines Corporation and         *\r
4  * others. All Rights Reserved.                                                *\r
5  *******************************************************************************\r
6  */\r
7 \r
8 package com.ibm.icu.dev.tool.ime;\r
9 \r
10 import java.awt.Rectangle;\r
11 \r
12 import javax.swing.Box;\r
13 import javax.swing.JFrame;\r
14 import javax.swing.JTextField;\r
15 import javax.swing.WindowConstants;\r
16 \r
17 public class IMETest {\r
18     public static void main(String[] args) {\r
19     String sampleText = "This is a sample\nto put into the field.";\r
20     Rectangle loc = new Rectangle(100, 100, 300, 300);\r
21     for (int i = 0; i < 2; ++i) {\r
22         JFrame jf = new JFrame("Test Window " + i);\r
23         jf.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);\r
24         Box box = Box.createVerticalBox();\r
25         box.add(new JTextField(sampleText));\r
26         box.add(new JTextField(sampleText));\r
27         jf.getContentPane().add(box);\r
28         jf.setBounds(loc);\r
29         \r
30         jf.setVisible(true);\r
31         \r
32         loc.x += 50;\r
33         loc.y += 50;\r
34     }\r
35     }\r
36 }\r