 |
AppletTalk.com Java discussions newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Taras_96 Guest
|
Posted: Sun Sep 28, 2003 6:51 am Post subject: Size of JMenu |
|
|
Hi all,
Just wondering, how do you find the 'usable' size of a content pane.
Obviously when you add a menu item, this decreases the available
height into which you can insert containers. For example, inserting a
JPanel with height equal to the content pane's height will cause the
bottom of the JPanel to be cut off.
Cheers
Taras
|
|
| Back to top |
|
 |
Simon Righarts Guest
|
Posted: Sun Sep 28, 2003 11:00 am Post subject: Re: Size of JMenu |
|
|
"Taras_96" <tagas96 (AT) hotmail (DOT) com> wrote
| Quote: | Hi all,
Just wondering, how do you find the 'usable' size of a content pane.
Obviously when you add a menu item, this decreases the available
height into which you can insert containers. For example, inserting a
JPanel with height equal to the content pane's height will cause the
bottom of the JPanel to be cut off.
|
Have you tried getting the content pane, then getting the size and insets of
that and going from there?
Your other option is to not force the JFrame to a specific size and let
pack() do all the work.
|
|
| Back to top |
|
 |
Harald Hein Guest
|
Posted: Sun Sep 28, 2003 4:14 pm Post subject: Re: Size of JMenu |
|
|
"Taras_96" wrote:
| Quote: | Just wondering, how do you find the 'usable' size of a content pane.
|
Leave that to the layout manager. That's what they are for.
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|