Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-swt-dev] How do you remove trim from SWT_AWT Shell

Sorry for posting, i figured it out.  I'm a total noob when it comes to swt.

shell = SWT_AWT.new_Shell(FlexIntegration.getDisplay(), canvas);
GridLayout gl = new GridLayout();
gl.marginWidth = 0;
gl.marginHeight = 0;
shell.setLayout(gl);
shell.setLayoutData(new FillLayout());

----------------------------------------
> From: jmandawg@xxxxxxxxxxx
> To: platform-swt-dev@xxxxxxxxxxx
> Subject: RE: How do you remove trim from SWT_AWT Shell
> Date: Tue, 12 Apr 2011 14:36:34 -0400
>
>
> Sorry. To be more clear, there is a 4 pixel padding around the shell object.  Here is a screen shot and the corresponding code:
>
> (Screenshot URL)
> http://i.imgur.com/1vUFv.jpg
>
> JDialog Parent = new JDialog();
> parent.getContentPane().add(canvas,BorderLayout.CENTER);
> parent.setVisible(true);
>
> shell = SWT_AWT.new_Shell(FlexIntegration.getDisplay(), canvas);
>
> shell.setBackground(new org.eclipse.swt.graphics.Color(display, new RGB(255 ,0, 0)));
> shell.setLayout(new GridLayout());
> shell.setLayoutData(new FillLayout());
>
> browser = new Browser(shell, SWT.NONE);
> browser.setLayoutData(new GridData(GridData.FILL_BOTH));
> browser.setUrl("http://www.google.com";);
> shell.pack();
> shell.open();
>
>
>
> ----------------------------------------
> > From: jmandawg@xxxxxxxxxxx
> > To: platform-swt-dev@xxxxxxxxxxx
> > Subject: How do you remove trim from SWT_AWT Shell
> > Date: Tue, 12 Apr 2011 13:24:21 -0400
> >
> >
> > Hi All,
> >
> > Is there anyway to remove the trim from an SWT_AWT Shell?
> >
> > shell = SWT_AWT.new_Shell(display, canvas);
> >
> > There is no options to set the style to SWT_NOTRIM. Right now i have a 4 pixel border around the entire shell.
> >
> > Thanks,
> >
> > J
> >
>
 		 	   		  

Back to the top