-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFL1.java
More file actions
20 lines (20 loc) · 724 Bytes
/
FL1.java
File metadata and controls
20 lines (20 loc) · 724 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package cse558;
import javax.swing.*;
import java.awt.*;
public class FL1 {
public static void main(String[] args) {
JFrame frame = new JFrame("FlowLayout Example");
frame.setLayout(new FlowLayout());
frame.add(new JButton("Sunday"));
frame.add(new JButton("Monday"));
frame.add(new JButton("Tuesday"));
frame.add(new JButton("Wednesday"));
frame.add(new JButton("Thursday"));
frame.add(new JButton("Friday"));
frame.add(new JButton("Saturday"));
frame.pack();
frame.setSize(200,200);
frame.setVisible(true);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
}