0

Help with Borderlayout

asked 2012-12-09 16:57:56 +0800

andij62 gravatar image andij62
303 1 7

Hi all,

i have a question about Borderlayout. I set the west-Area to "collapsible="true". I will show/hide the west-Area in my controller and when i hide the west-Area then should not a frame is displayed left. The west-Area should be 0px.

Can someone help me?

Andi

delete flag offensive retag edit

8 Replies

Sort by ยป oldest newest

answered 2012-12-09 21:27:19 +0800

terrytornado gravatar image terrytornado flag of Germany
9393 3 7 16
http://www.oxitec.de/

If you set the west-Area to '0px' how you will get it back to the original width?

west.setWidth("0px");

link publish delete flag offensive edit

answered 2012-12-10 05:58:53 +0800

Senthilchettyin gravatar image Senthilchettyin flag of India
2621 3 8
http://emrpms.blogspot.in...

You can setvisible = false if you do not want to display

link publish delete flag offensive edit

answered 2012-12-10 10:03:05 +0800

andij62 gravatar image andij62
303 1 7

When is set to "setvisible = false" then the slide-effect is not shown. I will place a toolbarbutton in the header of the center-Area and then in the Controller i will show/hide the west-Area when the Toolbarbutton is clicked. How can i do this in the controller. My App runs on iphone and i have no space to show the west-Area if it is not needed.

link publish delete flag offensive edit

answered 2012-12-10 14:22:11 +0800

terrytornado gravatar image terrytornado flag of Germany
9393 3 7 16
http://www.oxitec.de/

updated 2012-12-10 14:22:33 +0800

store before do 0px
int width = west.getWidth();
west.setWidth("0px");

reset after click 'restore'
west.setWidth(width + "px");

best
Stephan

link publish delete flag offensive edit

answered 2012-12-10 16:15:12 +0800

andij62 gravatar image andij62
303 1 7

Hi Stephan,

easy and it does exactly what I need! I searched for the appropriate command to open/close the west-Area.

Thx Andi

link publish delete flag offensive edit

answered 2012-12-10 16:33:42 +0800

andij62 gravatar image andij62
303 1 7

I still have another Problem..

My App runs on iphone. The witdh from iphone is 320px. When i set the west-Area (Menu) to "210px" the center-area resize to the rest of Pixel. This is not good because my tabbox with grids resize and does not look nice. Is it possible to freeze the center-Area during the west-Area is open?

Thanks for help!

link publish delete flag offensive edit

answered 2013-01-07 03:14:45 +0800

samchuang gravatar image samchuang
4084 4

hi, the center component will use the rest size, so, I think, the issue you mention doesn't fix the borderlayout's spec ? so maybe you need to consider to use different component for layout instead of borderlayout

link publish delete flag offensive edit

answered 2013-01-07 16:02:37 +0800

hswain gravatar image hswain flag of India
1763 3 10
http://corejavaexample.bl...

hi. you cannot change width center-area. you can use east-area instead of center-area then you can re-size as your choice.

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2012-12-09 16:57:56 +0800

Seen: 104 times

Last updated: Jan 07 '13

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More