Advertisement
Aminpro

JFrame

Dec 31st, 2013
277
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.60 KB | None | 0 0
  1. import java.awt.FlowLayout;
  2. import javax.swing.JFrame;
  3. import javax.swing.JLabel;
  4.  
  5. public class tuna extends JFrame{
  6.    
  7.     private JLabel item1;
  8.    
  9.     public tuna(){
  10.         super("Aminpro Title Bar");
  11.         setLayout(new FlowLayout());
  12.        
  13.         item1 = new JLabel("This is a text");
  14.         item1.setToolTipText("This is a hover hand");
  15.         add(item1);
  16.    
  17.     }
  18. }
  19.  
  20. import javax.swing.JFrame;
  21.  
  22. class apples{
  23.     public static void main(String args[]){
  24.         tuna tunaObject = new tuna();
  25.        
  26.         tunaObject.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  27.         tunaObject.setSize(275, 180);
  28.         tunaObject.setVisible(true);
  29.     }
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement