Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.awt.Font;
- import javax.swing.JFrame;
- import javax.swing.JLabel;
- import javax.swing.JPanel;
- public class JamesExample{
- public static void main(String[] args){
- new JamesExample();
- }
- public JamesExample(){
- JFrame frame = new JFrame("JamesExample");
- frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
- frame.setSize(400,400);
- frame.setResizable(false);
- frame.setLocationRelativeTo(null);
- JPanel panel = new JPanel();
- JLabel label = new JLabel("LOL TRAVIS KNOWS ALL");
- label.setFont(new Font("Arial", Font.PLAIN, 16));
- panel.add(label);
- frame.add(panel);
- frame.setVisible(true);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment