4 ms·
Why does Unicode have such powerful control characters that can be used to construct misleading strings? Is there a non-malicious use case for them?
by null_ptr 13y ago
Why does Unicode have such powerful control characters that can be used to construct misleading strings? Is there a non-malicious use case for them?
- AsymetricCom 13y agoYeah, writing anything that doesn't conform to typical rules of lexicography.
- derleth 13y agoThe point is that the typical rules in one language are completely bizarre in another. Unicode tries hard to be at least minimally useful to everyone, meaning that it has to make allowances for all of the rules. It's complicated. It's more complicated than any encoding standard that came before. It's also the most broadly useful, and the first standard to really take into account the complexities of human written language, as opposed to just one region's written language.
- jahewson 13y agoStacked diacritics are used in Thai and other Asian languages, as well as rarely-seen languages such as those of the Yukon. The right-to-left control character is for embedding e.g. Arabic or Hebrew script inside Latin text (or vice versa). It is actually a controversial feature of Unicode as some people feel it belongs in a higher-level protocol. Check out the examples here http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=CmplxRndExamples http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=... for an idea of what rendering non-Western scripts can entail.
- BitMastro 13y agoThanks for the link, it's very interesting!
- deleted 13y ago[deleted]