Closed Clashsoft closed 4 years ago
Changed the StringRenderer.encodeHTML method, i.e. the implementation for format="xml-encode", in order to support Unicode characters encoded as two chars (surrogate pairs). An example where this problem occurred was with emojis, as outlined in #260. While the old implementation produced two invalid HTML entities �� for the two characters encoding the emoji "🩳", after this change it only generates one entity, namely 🩳 (ref.: https://unicode-table.com/de/1FA73/)
StringRenderer.encodeHTML
format="xml-encode"
char
��
🩳
Closes #260
Thanks, @Clashsoft !!
Changed the
StringRenderer.encodeHTML
method, i.e. the implementation forformat="xml-encode"
, in order to support Unicode characters encoded as twochar
s (surrogate pairs). An example where this problem occurred was with emojis, as outlined in #260. While the old implementation produced two invalid HTML entities��
for the two characters encoding the emoji "🩳", after this change it only generates one entity, namely🩳
(ref.: https://unicode-table.com/de/1FA73/)Closes #260