Community
Participate
Working Groups
related bugs are #304364 and #337974 To reproduce the problem: - open the controls demo, text tab, and set the value of a MULTI Text using the widgets on the right hand side to a string that contains the unicode codepoint: 2028 (tip: on windows, by setting a registry key (http://en.wikipedia.org/wiki/Unicode_input#Hex_input), you can easily input this character by pressing ALT + "+" + 2028) Note: this semantic line separator character is often found on websites, e.g. in the impressum. After copying this text to a RAP application, where it is processed and later displayed in a text, this error happens. The reason for this problem is that the resolution of bug: #304364 did not fix this issue in the multi text. Proposed solution: In MultiTextLCA#renderChanges, use TextLCAUtil.writeText( text ) to set a text, just as it is done in the other text LCAs. TextLCAUtil.writeText, besides setting the text also transforms the string appropriately. Note: I think the reason for this bug was the fact, that this MultiTextLCA did not delegate to the TextLCAUtil. Hence, when that code was fixed, it was easily forgotten.
Created attachment 189608 [details] patch resolution: use the TextLCAUtil.writeText() method in all 3 Text LCAs. that method performs the necessary string transformations. note: to preserve the behaviour of replacing new line characters with a space, a boolean replaceNewLines parameter was added to TextLCAUtil.writeText, and the 3 calls were adjusted appropriately
Istvan, thanks for the patch. Applied patch to CVS HEAD. Now all three types of Text widget (SINGLE, MULTI and PASSWORD) use TextLCAUtil#write Text. JUnit tests added.