Solved

setting component Z Order

Posted on 2010-11-12
6
996 Views
Last Modified: 2012-05-10
I am trying to set ZorderComponent of a button..

I am doing something like this -- panel.setComponentZOrder(button, 0);

After adding this line .. no matter what components I add to panel they do not show up :(

and if I remove this line they do show  :(
0
Comment
Question by:hipal
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 92

Expert Comment

by:objects
ID: 34126182
could be because the button is painting over all your other components.
can't tell exactly what the problem is without seeing your code
0
 

Author Comment

by:hipal
ID: 34126186
no it is not so .. i can see button is just in left corner
0
 
LVL 92

Expert Comment

by:objects
ID: 34126199
is it a standard JButton, or a subclass?
And what is its size?

just because you see it top left doesn't mean its not painting to more of the panel
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 92

Expert Comment

by:objects
ID: 34126201
give another component in the panel a lower z order than it
0
 

Accepted Solution

by:
hipal earned 0 total points
ID: 34127630
I got the problem .. I was doing a blunder .. I thought that we can assign any Zorder as it is relative .

I mean I just have 2 components and I was trying to assign Zorder 10 to one of them :P

thanks though !
0
 

Author Closing Comment

by:hipal
ID: 34162440
I got the mistake I was doing  !
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How  can  i  resolve  HTTP Status 404 -? 8 78
Setup GlassFish 4 55
AvlTree-Node Data type 4 46
Code planning methods/tools? 5 55
A short article about problems I had with the new location API and permissions in Marshmallow
In this post we will learn different types of Android Layout and some basics of an Android App.
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question