Topic: 【请教】布局问题(Question about layout) |
Print this page |
1.【请教】布局问题(Question about layout) | Copy to clipboard |
Posted by: yamakasy Posted on: 2003-08-08 09:22 | leftPanel | centerPanel | rightPanel | 实现如图的布局,有如下要求 1.leftPanel和rightPanel大小一样。 2.centerPanel大小固定,不会随着整体的布局的变化而改变大小,而且始终居中,centerPanel和leftPanle,rightPanle大小不一样。 3.当整个窗体调整大小的时候,首先centerPanel满足以上条件,其次,leftPanel和rightPanel以同样比例放缩。 你们有什么好的建议? |
2.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: jigsaw Posted on: 2003-08-08 16:14 左中右用BorderLayout 中间用GridBagLayout GridBagConstraints.anchor = GridBagConstraints.CENTER; 没有动手试过 |
3.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: floater Posted on: 2003-08-08 22:14 simple flowlayout, set preferred size/size on the middle one. My guess |
4.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: yamakasy Posted on: 2003-08-09 23:05 不能满足要求。 |
5.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: fly2fire Posted on: 2003-08-10 09:08 整体用GridBag布局器就可以了.如果用JBuilder来画的话就非常简单. |
6.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: floater Posted on: 2003-08-11 06:31
|
7.Re:【请教】布局问题(Question about layout) [Re: yamakasy] | Copy to clipboard |
Posted by: yamakasy Posted on: 2003-08-11 11:49 呵呵,BoxLayout实现这个似乎不错。不过,我这里有一个StackLayout,功能强大,可以方便的实现上面的效果 StackLayout.java (8.57k) |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |