Friday, October 28, 2011

Re: LayoutPanel - how to set background image?


Try myLayoutPanel.setStyleName("my-layout-style"). And then in the css
add the rule
.my-layout-style { background-image:...}.It will repeat by default,
unless you set background-repeat:"no-repeat".

I think this would work.

On 28 Οκτ, 20:02, Ed <> wrote:
> Use @sprite to set the background image and use the image settings in
> de ClientBundle to define the h/v repeat.
> See:
> - Ed
> On Oct 28, 6:33 pm, Magnus <> wrote:
> > Hi,
> > I have a Layout Panel and I would like a background image.
> > How can I do that? And how can I make it repeat, horizontally and
> > vertically?
> > I found that a LayoutPanel does not have a getElement/getStyle method.
> > So how can I access the element style or how can I realize the background?
> > Thanks a lot!
> > Magnus

You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

No comments:

Post a Comment