Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Background image won't show up on ScrolledForm
Background image won't show up on ScrolledForm [message #77573] Mon, 10 March 2008 08:31 Go to next message
Setya Nugdjaja is currently offline Setya NugdjajaFriend
Messages: 567
Registered: July 2009
Senior Member
Hi,

I wrote the following snippet to set background image:

private FormToolkit toolkit = null;
private ScrolledForm form = null;

public void createPartControl(Composite parent)
{
toolkit = new FormToolkit(parent.getDisplay());
form = toolkit.createScrolledForm(parent);

form.setBackgroundImage(CorePlugin.getInstance().getImage(IP luginPropertiesConstants.WELCOME_IMAGE_BACKGROUND));
form.pack();
}

Somehow the background image won't show up, is this a known limitation ?

Regards,

Setya
Re: Background image won't show up on ScrolledForm [message #77645 is a reply to message #77573] Mon, 10 March 2008 13:33 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: rherrmann.innoopract.com

Hi Setya,

setBackgroundImage has no (reasonable) implementation. It wasn't
intended to make this empty API available in the first place.
However, with the upcoming support of background images on the
Control widget there is a chance we can implement this.

Cheers,
Rüdiger



Setya wrote:
> Hi,
>
> I wrote the following snippet to set background image:
>
> private FormToolkit toolkit = null;
> private ScrolledForm form = null;
>
> public void createPartControl(Composite parent)
> {
> toolkit = new FormToolkit(parent.getDisplay());
> form = toolkit.createScrolledForm(parent);
>
> form.setBackgroundImage(CorePlugin.getInstance().getImage(IP luginPropertiesConstants.WELCOME_IMAGE_BACKGROUND));
>
> form.pack();
> }
>
> Somehow the background image won't show up, is this a known limitation ?
>
> Regards,
>
> Setya
>
Re: Background image won't show up on ScrolledForm [message #77819 is a reply to message #77645] Tue, 11 March 2008 07:45 Go to previous messageGo to next message
Setya Nugdjaja is currently offline Setya NugdjajaFriend
Messages: 567
Registered: July 2009
Senior Member
Rüdiger,

> setBackgroundImage has no (reasonable) implementation. It wasn't
> intended to make this empty API available in the first place.
> However, with the upcoming support of background images on the
> Control widget there is a chance we can implement this.

Thank you for your clarification.

To workaround this limitation I implement the page using browser widget
and put the image in the body element's background.

But this does not work either, the image simply won't show up.

When I browse the html file directly the background image gets displayed
just fine.

In RAP demo I see background image on the upper area, how is this
implemented ?

Regards,

Setya
Re: Background image won't show up on ScrolledForm [message #77895 is a reply to message #77819] Tue, 11 March 2008 14:06 Go to previous message
Eclipse UserFriend
Originally posted by: fappel.innoopract.com

Hi,

in the demo we set an image to a label in the banner composite and move
the other components above it using the FormLayout. You may have a look
at the current CVS-Head as Control#setBackgroundImage is now available.

Ciao
Frank

-----Ursprüngliche Nachricht-----
Von: Setya [mailto:jsetya@gmail.com]
Bereitgestellt: Dienstag, 11. März 2008 08:45
Bereitgestellt in: eclipse.technology.rap
Unterhaltung: Background image won't show up on ScrolledForm
Betreff: Re: Background image won't show up on ScrolledForm


Rüdiger,

> setBackgroundImage has no (reasonable) implementation. It wasn't
> intended to make this empty API available in the first place.
> However, with the upcoming support of background images on the Control

> widget there is a chance we can implement this.

Thank you for your clarification.

To workaround this limitation I implement the page using browser widget
and put the image in the body element's background.

But this does not work either, the image simply won't show up.

When I browse the html file directly the background image gets displayed
just fine.

In RAP demo I see background image on the upper area, how is this
implemented ?

Regards,

Setya
Previous Topic:ScrolledForm's scrollbars shows up after refreshing
Next Topic:How to tell RAP to switch perspective from external servlet ?
Goto Forum:
  


Current Time: Thu Apr 25 07:21:10 GMT 2024

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

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

Back to the top