Re: SafeHtml and SafeStyles

2012-05-02 Thread Joseph Lust
I look forward to it since writing string literals for CSS properties seems silly in this day and age. Joe -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-w

Re: SafeHtml and SafeStyles

2012-05-02 Thread Thomas Broyer
On Wednesday, May 2, 2012 6:14:35 PM UTC+2, Joseph Lust wrote: > > @Template(" style=\"position:absolute;display:none;"\>{1}") > SafeHtml unsorted(SafeStyles imageWidthStyle, SafeHtml text); > > double width = 34.34d; > SafeStyles imageWidthStyle = > SafeStylesUtils.fromTrustedString("width:"+w

Re: SafeHtml and SafeStyles

2012-05-02 Thread Joseph Lust
@Template("{1}") SafeHtml unsorted(SafeStyles imageWidthStyle, SafeHtml text); double width = 34.34d; SafeStyles imageWidthStyle = SafeStylesUtils.fromTrustedString("width:"+width+"px;"); SafeHtml text = SafeHtmlUtils.fromString("blah"); unsorted( imageWidthStyle, text ); // call your template

Re: SafeHtml and SafeStyles

2011-05-04 Thread Thomas Broyer
Have a look at the SafeStylesUtils and SafeStylesBuilder; and change your "imageWidth" argument to SafeStyles (where's that SafeCSSWidth coming from?!) See http://google-web-toolkit.googlecode.com/svn/javadoc/2.3/com/google/gwt/safecss/shared/SafeStyles.html -- You received this message becaus

SafeHtml and SafeStyles

2011-05-04 Thread Deyan Atanasov
Hi, I am trying to implement SafeHtml with some parameters in the HTML style atribute: Example: @Template("{1}") SafeHtml unsorted(SafeCSSWidth imageWidth, String text); My SafeCSSWidth class implements SafeStyles, according to the contract but the GWT compiler still outputs: [INF