Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail From: Roedy Green Newsgroups: comp.lang.java.programmer Subject: Re: can't stop JPanel paint Date: Tue, 26 Jul 2011 06:30:24 -0700 Organization: Canadian Mind Products Lines: 18 Message-ID: <19gt279m2nrd4c14ublavb42s5iec2id6d@4ax.com> References: <728e86bb-daed-40cd-b8a2-d2bf08059dd5@glegroupsg2000goo.googlegroups.com> Reply-To: Roedy Green NNTP-Posting-Host: RCd/Ul4tyxGUBII8WGwa5g.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: Forte Agent 6.00/32.1186 Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:6574 On Thu, 14 Jul 2011 04:43:04 -0700 (PDT), Peter Cheung wrote, quoted or indirectly quoted someone who said : >Hi > I have overrider all the paintXX method and did nothing in there. But why I still able to see the component on top of the JPanel? you would gave to block the paint methods of all the children which might be invoked independently of the JPanel container if their values changed. I trust you are just experimenting. The proper way to hide things is with setVisible( false ). -- Roedy Green Canadian Mind Products http://mindprod.com Most of computer code is for telling the computer what do if some very particular thing goes wrong.