You could probably wrap this as a CSS rule: ".somethingRandom {" + 
userProvidedCSS + "}" and then use the StyleInjector to inject that 
stylesheet, and finally call addStyleName on the Element or Widget to apply 
the rule.

On Thursday, May 15, 2014 4:54:30 PM UTC+2, [email protected] wrote:
>
> I've figured out how to change CSS properties using 
> Element.getStyle().setSomething(), but I need to replace an entire CSS 
> style on the fly.  I want my users to be able to supply their own CSS for 
> certain widgets and have GWT replace the current CSS with their user 
> defined CSS.
>
> So instead of asking a user for background image, background repeat, 
> background size, etc, the user just pastes in
>
>     background-size:100% 100%;
>     background-repeat: no-repeat;
>     background-image: url(some_image.jpg);
>
> Is there a way to do this?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to