Results 1 to 2 of 2
  1. #1
    ayush is offline Member
    Join Date
    Jul 2013
    Rep Power

    Default Overlapping two swing components??

    i m new to java..i m trying to make a small game in net beans Jframe ..
    i wanted to know that how to add an event( show message) when two labels overlap each other.. one is running with help of timer while other one is controlled through keyboard (arrow keys) ..i have already tried matching their coordinates but as their size is big and their coordinates are being changed continuously hence it is not useful.. any other ideas please..

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Madgaon, Goa, India
    Rep Power

    Default Re: Overlapping two swing components??

    To get better help sooner, post a SSCCE (Short, Self Contained, Correct (Compilable), Example) that demonstrates the problem.

    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. some swing components are not displaying
    By mDennis10 in forum AWT / Swing
    Replies: 6
    Last Post: 01-27-2012, 10:26 AM
  2. Using swing components in a handler
    By aianta in forum New To Java
    Replies: 6
    Last Post: 10-19-2011, 03:27 AM
  3. Two Overlapping Components
    By javadeveloper2011 in forum AWT / Swing
    Replies: 4
    Last Post: 03-26-2011, 07:46 PM
  4. Overlapping Components using Netbeans GUI Interface
    By hitmen in forum Java Applets
    Replies: 3
    Last Post: 03-06-2009, 06:33 AM
  5. Problem In Swing Components
    By SANDY_INDIA in forum AWT / Swing
    Replies: 1
    Last Post: 07-19-2008, 10:23 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts