I am using SmartGWT 4.1 power edition.
I have a label that is set to width 300, in a HLayout.
There is a very long string with no white space in it. Such as,
"a0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789".
In the CSS, it is set to "word-wrap:break-word".
When the label is set with the long string, it wraps around with width 300. That is correct.
Then it is set to a different value by setContents(), such as "abc".
Then it is reset to the long string by setContents(). But it becomes a one-line long string. The width is 1920, instead of 300. Even if I reset width to 300, it doesn't work.
I have a label that is set to width 300, in a HLayout.
There is a very long string with no white space in it. Such as,
"a0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789".
In the CSS, it is set to "word-wrap:break-word".
When the label is set with the long string, it wraps around with width 300. That is correct.
Then it is set to a different value by setContents(), such as "abc".
Then it is reset to the long string by setContents(). But it becomes a one-line long string. The width is 1920, instead of 300. Even if I reset width to 300, it doesn't work.
Comment