Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Longstanding repaint/redraw/refresh issues in embedded Swing composite
Longstanding repaint/redraw/refresh issues in embedded Swing composite [message #440482] Mon, 02 August 2004 16:53 Go to next message
David Thomson is currently offline David ThomsonFriend
Messages: 65
Registered: July 2009
Member
Hello all,

I have a Swing GUI embedded inside a SWT shell. There are two main
Composite SWT_AWT frames, one of which contains an embedded CardLayout
panel, the other of which contains a Panel with multiple nested JSplitPanes.

The problem is that on Windows XP and 2K when the application is
deiconified (perhaps other times as well, but definitely then) it
occasionally comes up completely grey. If the user grabs the side of the
window and resizes it, it will repaint properly. Minimizing and
maximizing does not always force a repaint.

I have tried everything I can think of, including listening on every
shell event I could find, and then forcing a repaint of the window. I
have tried redrawing and repainting all the GUI components I could think
of in multiple ways, such as shell.redraw, shell.update, display.update,
calling repaint and revalidate on every JPanel embedded inside the
composites, calling repaint on the embedded composite AWT frames. I have
tried combinations of different syncExec/asyncExec on the blocks of code
to force such a redraw/repaint/update.

In short, I don't understand enough of what's going on with the various
UI threads and interaction between the Display thread and the Swing
thread to put forth educated trials and therefore I'm stuck in error. If
anyone has any ideas, I would sincerely appreciate it.

Thanks,
David
Re: Longstanding repaint/redraw/refresh issues in embedded Swing composite [message #440528 is a reply to message #440482] Tue, 03 August 2004 22:53 Go to previous message
Steve Northover is currently offline Steve NorthoverFriend
Messages: 1636
Registered: July 2009
Senior Member
Enter a problem report? Make sure you include an example that comes up gray
some of the time. Thanks.

"David Thomson" <david@suprasphere.com> wrote in message
news:celrev$7d8$1@eclipse.org...
> Hello all,
>
> I have a Swing GUI embedded inside a SWT shell. There are two main
> Composite SWT_AWT frames, one of which contains an embedded CardLayout
> panel, the other of which contains a Panel with multiple nested
JSplitPanes.
>
> The problem is that on Windows XP and 2K when the application is
> deiconified (perhaps other times as well, but definitely then) it
> occasionally comes up completely grey. If the user grabs the side of the
> window and resizes it, it will repaint properly. Minimizing and
> maximizing does not always force a repaint.
>
> I have tried everything I can think of, including listening on every
> shell event I could find, and then forcing a repaint of the window. I
> have tried redrawing and repainting all the GUI components I could think
> of in multiple ways, such as shell.redraw, shell.update, display.update,
> calling repaint and revalidate on every JPanel embedded inside the
> composites, calling repaint on the embedded composite AWT frames. I have
> tried combinations of different syncExec/asyncExec on the blocks of code
> to force such a redraw/repaint/update.
>
> In short, I don't understand enough of what's going on with the various
> UI threads and interaction between the Display thread and the Swing
> thread to put forth educated trials and therefore I'm stuck in error. If
> anyone has any ideas, I would sincerely appreciate it.
>
> Thanks,
> David
Previous Topic:menubar listener
Next Topic:Checkbox in table too small
Goto Forum:
  


Current Time: Tue Apr 23 09:05:15 GMT 2024

Powered by FUDForum. Page generated in 0.03293 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top