Saturday, March 29, 2014

Why “word-wrap” css style doesn't work when setting in UiBinder but ok when setting via code (GWT)?

We got this css to make a long string (without any space in it, URL for example) to fall into many new lines rather than just show 1 line:

.wordWrap{  word-wrap:break-word;  }

in .xml file

<g:HTMLPanel ui:field="myPanel" addStyleNames="{style.wordWrap}" > <g:Label text="Aaaaaa..very long string without any space in it... aa"> <g:/HTMLPanel>

This does not work.

However, if we set styleName via coding:

myPanel.addStyleNames("wordWrap");

Then it works fine.

So

Why "word-wrap" css style doesn't work when setting in UiBinder but ok when setting via code (GWT)?


(also: http://stackoverflow.com/questions/22740185/why-word-wrap-css-style-doesnt-work-when-setting-in-uibinder-but-ok-when-sett)

--
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 google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment