Results 1 to 4 of 4
  1. #1
    techbossmb is offline Member
    Join Date
    Sep 2009
    Posts
    10
    Rep Power
    0

    Question Overlapping JLabels

    how do i make two jLabels to overlap. I used netbeans ide to develop the interface where i used two jLabels to display to images, but now i am having problem with making to to overlap each other.

  2. #2
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default

    You may need to use absolute positioning here by setting the layout of the Container that's holding the JLabel's to null and then specifying the precise size and position of the JLabels (and everything else held by that container) using a method such as setBounds(....).

  3. #3
    techbossmb is offline Member
    Join Date
    Sep 2009
    Posts
    10
    Rep Power
    0

    Default

    Thanks a lot. I have also gotten a way out the mess using a layered pane. Thanks again.

  4. #4
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

Similar Threads

  1. Help with overlapping JPanels
    By xcallmejudasx in forum New To Java
    Replies: 2
    Last Post: 03-09-2009, 10:19 PM
  2. Overlapping Components using Netbeans GUI Interface
    By hitmen in forum Java Applets
    Replies: 3
    Last Post: 03-06-2009, 05:33 AM
  3. overlapping forms
    By keerthi_y19 in forum New To Java
    Replies: 4
    Last Post: 08-26-2008, 10:30 PM
  4. problem with JLabels
    By geork in forum New To Java
    Replies: 3
    Last Post: 01-31-2008, 02:30 PM
  5. Having Trouble Aligning JLabels
    By Mark_Petrov in forum AWT / Swing
    Replies: 0
    Last Post: 01-20-2008, 05:22 PM

Posting Permissions

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