|How to create a shell out of the screen? [message #986958]
||Thu, 22 November 2012 09:25
| Francis Delsinnes
Registered: November 2011
How to create a shell out of the screen?|
In a RAP application (made from a primary shell in full size),
I would like create another shell and give it an absolute position relative to the content of its parent.
To create information panels overlays to existing content of a page.
Example: an information over a background image as a banner.
Easy => Use a Composite (set its background-image)...
But: this panel should not completely to be included in the background image.
Only a part of this image, the rest would be beside of.../in the "empty space".
When you scroll the screen, this panel (shell) does not remain "stuck" in the display area.
Improve the presentation of information and obtain a more beautiful layout.
|Re: How to create a shell out of the screen? [message #987482 is a reply to message #986958]
||Mon, 26 November 2012 15:09
| Cole Markham
Registered: July 2009
As Ralf mentioned, a screenshot would definitely help. It is simple enough to open a shell, however.
Shell popup = new Shell(parentShell, SWT.SHELL_TRIM);
// Create contents of shell as you would the
// Calculate location and size
int x = ...;
int y = ...;
int width = ...;
int height = ...;
// Set size and location of shell in Display coordinates
popup.setBounds(x, y, width, height);
Hope that helps,
Powered by FUDForum
. Page generated in 0.04682 seconds