Path: csiph.com!x330-a1.tempe.blueboxinc.net!feeder1.hal-mli.net!news.alt.net!news-in-01.newsfeed.easynews.com!easynews.com!easynews!news-out.news.tds.net!newsreading01.news.tds.net!86597e80!not-for-mail From: "Tandaina" Subject: Re: Odd GUI behavior (Win Message-ID: <1164638946.784423.5630@l39g2000cwd.googlegroups.com> X-Comment-To: comp.lang.java.gui Newsgroups: comp.lang.java.gui In-Reply-To: <1164638688.425527.317490@n67g2000cwd.googlegroups.com> References: <1164638688.425527.317490@n67g2000cwd.googlegroups.com> Content-Type: text/plain; charset=IBM437 Content-Transfer-Encoding: 8bit X-Gateway: time.synchro.net [Synchronet 3.15a-Win32 NewsLink 1.92] Lines: 30 Date: Wed, 27 Apr 2011 15:26:12 GMT NNTP-Posting-Host: 96.60.20.240 X-Complaints-To: news@tds.net X-Trace: newsreading01.news.tds.net 1303917972 96.60.20.240 (Wed, 27 Apr 2011 10:26:12 CDT) NNTP-Posting-Date: Wed, 27 Apr 2011 10:26:12 CDT Organization: TDS.net Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.gui:206 To: comp.lang.java.gui Andrew Thompson wrote: > Get rid of the setBounds.. > > Did you mention no use of pack()? > > Check the docs. for both pack() *and* validate() > carefully, the code needs one or the other (and > I always let the compiler to tell me which one!). I believe the rather heavy handed use of setSize (only for dialogs and frames) is related to the lack of pack and validate? I'll need to read up on those two. There isn't a single pack or validate anywhere. When I remove the setsize from an example dialog and add pack I end up with a tiny little box. I can expand that tiny box and see all the components but I'm guessing (big leap huh?) that this indicates a bit of a problem. My example dialog is in fact using layouts (Border to be exact) and seems to be doing everything else properly. Not entirely sure why its showing this behavior but I'm going to guess that the previous developer saw that setSize fixed the problem and just stuck it in as needed. Chris --- * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet! --- Synchronet 3.15a-Win32 NewsLink 1.92 Time Warp of the Future BBS - telnet://time.synchro.net:24