Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » shell visible event
shell visible event [message #465674] Sun, 18 December 2005 14:46 Go to next message
Eclipse UserFriend
Originally posted by: swtMan.trash-mail.de

hello,

I have a problem to make a screenshot, who my shell isn't visible.
This screenshot I can only make with a sleep statemant. But this isn't a
good solution. Doesn't give a better solution? I search for a ShellEvent
who signalized that the shell is really visible. SWT.Hide doesn't do this.

I hope you understand me, because I'm german and my english isn't very
well.

Here my code:

shell.setVisible(false); // This shell doesnt show in screenshot
Image buffer = new Image();
try {
Thread.sleep(50);
} catch (InterruptedException e1) {
}
gc.copyArea (buffer,0,0); // makes screenshot
shell.setVisible(true);

Thanks
Peter
Re: shell visible event [message #465697 is a reply to message #465674] Mon, 19 December 2005 20:47 Go to previous message
Daniel Spiewak is currently offline Daniel SpiewakFriend
Messages: 263
Registered: July 2009
Senior Member
Try Shell#addShellListener(ShellListener) You might be able to get the functionality you want from that.
Previous Topic:GlassPane?
Next Topic:Canvas and mouseMoveListener and MacOS
Goto Forum:
  


Current Time: Sat Jun 15 20:50:29 GMT 2019

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

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

Back to the top