🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #12938

Re: ghost images

#12938
From: John Bartholdi
Date: Fri, 23 Oct 1998 00:00
35 lines
1780 bytes
i fixed this by calling super.repaintComponent() before repainting the
BevelPanel.

i have no idea why this works but perhaps it will help someone else...

-- jjb

    John Bartholdi wrote in message <6vvnnm$ft717@forums.borland.com>...
    Hello,

    I have a jbcl.control.BevelPanel that includes a
jbcl.control.NavigatorControl in the North, another BevelPanel in the
Center, and a jbcl.control.StatusBar in the South.

    My program draws on the BevelPanel in response to mouse clicks on that
BevelPanel (a different drawing for each successive click). To accomplish
the drawing I overrode the paintComponent method of the BevelPanel.

    The problem is that successive images are repainted in the wrong place.
Everything is shifted: including the NavigatorControl and the StatusBar,
which seems especially puzzling to me because they know nothing about the
drawing in the BevelPanel.

    Have I somehow mixed light and heavy-weight components here? (All this
sits on a jbcl.control.TabsetPanel.) The documentation suggests that all
these are lightweight components.

    I have tried calls to invalidate() followed by validate() but all to no
avail.

    Can anyone suggest what might be the problem here?

    Thanks in advance,

    John
Technical Details
Message-ID: <70q9vu$pes8@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <6vvnnm$ft717@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,c1db9700e9c1da60
X-Google-Attributes: gid111d45,public
From: "John Bartholdi" <john.bartholdi@isye.gatech.edu>
Subject: Re: ghost images
Date: 1998/10/23
Message-ID: <70q9vu$pes8@forums.borland.com>
X-Deja-AN: 404332026
References: <6vvnnm$ft717@forums.borland.com>
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4
Organization: Another Netscape Collabra Server User
Newsgroups: borland.public.jbuilder.java.swing