package com.tutego.insel.ui.swing;

import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class JLabelDemo
{
  public static void main( String[] args )
  {
    JFrame frame = new JFrame();
    frame.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );

    JLabel l = new JLabel( "Lebe immer First-Class, sonst tun es deine Erben!" );
    l.setForeground( Color.BLUE );

    frame.add( l );

    l.addMouseListener( new MouseAdapter() {
      @Override public void mouseClicked( MouseEvent e ) {
        if ( e.getClickCount() > 1 )
          System.exit( 0 );
      }
    } );

    frame.pack();
    frame.setVisible( true );
  }
}
