Article View: borland.public.jbuilder.java.swing
Article #7651Re: Resizing problems
From: Torsten Welches
Date: Thu, 11 Jan 2001 20:33
Date: Thu, 11 Jan 2001 20:33
57 lines
2823 bytes
2823 bytes
Rich, Sam talked about a ScrollPane and a Panel inside a Frame. The ScrollPane shall be size based on a percentage of the size of the frame. I assume the panel should get the remainder. Pretty much like a BorderLayout with, say, the ScrollPane NORTH or SOUTH and the panel CENTER. If that's what he was after it can be done with a null/XY layout, why not. Of cause a null layout scales nothing, it's a formlessvoid ;-) He has to make it himself... err, I mean - actually he showed code that intended just that - inside a componentResized event handler. No? Torsten Rich Wilkman schrieb in Nachricht <3A5DFAC1.240F0CD6@formlessvoid.com>... >Torsten: > >XYLayout is "like" null layout but not the same. With XY the component also >has a size constraint that goes with it. > >I've not seen null layout proportionally scale components based on the >container size and a user defined value for the proportion (overriding the >preferredSize of the components to do so instead of leaving them alone when >they say they're already big enough). How do you do that? > >-Rich > >Torsten Welches wrote: > >> Rich, >> >> I don't get your point, sorry. I have never used XYLayout but >> as I understand it it is like a null layout. >> You *can* do what Sam wants with a null layout, but you have >> to position all your controls yourself whenever the container >> size changes. Sam wanted to do just that, no? >> Or what am I missing? >> >> Thanks, >> Torsten >> >> Rich Wilkman <richw@formlessvoid.com> wrote: >> >Sam: >> > >> >XYLayout will never get you there -- that's the problem with co-ordinate >> >based layouts. Things go where you stick them at the size you stick them >> >there. I haven't seen a PercentOfContainer layout so you'll probably have >> >to invent one (or use GridBagLayout which is very, very powerful). >> > >> >-Rich >
Technical Details
Message-ID:
<3a5e194f_1@dnews>Path:
arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-out.usenetserver.com!portc03.blue.aol.com!news.maxwell.syr.edu!neel.uni2.net!newssuck.uni2.dk!bornews.borland.com!dnews!195.14.233.152References:
<3A5CBA35.FBDC69B0@home.com> <3A5CCA16.7EC9FF9A@formlessvoid.com> <3a5db048$1_1@dnews> <3A5DFAC1.240F0CD6@formlessvoid.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,ecab773c49c5caa6 X-Google-Attributes: gid111d45,public X-Google-ArrivalTime: 2001-01-11 12:54:08 PST From: "Torsten Welches" <torsten.welches@who.cares.netcologne.de> Newsgroups: borland.public.jbuilder.java.swing References: <3A5CBA35.FBDC69B0@home.com> <3A5CCA16.7EC9FF9A@formlessvoid.com> <3a5db048$1_1@dnews> <3A5DFAC1.240F0CD6@formlessvoid.com> Subject: Re: Resizing problems Date: Thu, 11 Jan 2001 21:33:45 +0100 Lines: 61 X-Newsreader: Microsoft Outlook Express 4.72.3110.5 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 NNTP-Posting-Host: 195.14.233.152 Message-ID: <3a5e194f_1@dnews> X-Trace: 11 Jan 2001 12:36:31 -0800, 195.14.233.152 Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-out.usenetserver.com!portc03.blue.aol.com!news.maxwell.syr.edu!neel.uni2.net!newssuck.uni2.dk!bornews.borland.com!dnews!195.14.233.152