Java by API/javax.swing/JWindow
Версия от 17:43, 31 мая 2010; (обсуждение)
Содержание
JWindow: setLocation(int x, int y)
import javax.swing.JWindow;
public class MainClass {
public static void main(String[] args) {
JWindow w = new JWindow( );
w.setSize(300, 300);
w.setLocation(500, 100);
w.setVisible(true);
}
}
JWindow: setSize(int w, int h)
import javax.swing.JWindow;
public class MainClass {
public static void main(String[] args) {
JWindow w = new JWindow( );
w.setSize(300, 300);
w.setLocation(500, 100);
w.setVisible(true);
}
}
JWindow: setVisible(boolean b)
import javax.swing.JFrame;
import javax.swing.JWindow;
public class Main {
public static void main(String[] args) {
JFrame f = new JFrame("The Frame");
f.setSize(300, 300);
f.setLocation(100, 100);
JWindow w = new JWindow();
w.setSize(300, 300);
w.setLocation(500, 100);
f.setVisible(true);
w.setVisible(true);
}
}
new JWindow()
import javax.swing.JWindow;
public class MainClass {
public static void main(String[] args) {
JWindow w = new JWindow( );
w.setSize(300, 300);
w.setLocation(500, 100);
w.setVisible(true);
}
}