Reputation: 11647
I've noticed this different specifically with iTunes when you export your music library.
I have a song with é (that is, a small latin E with an acute accent) and when I export the library in Windows, it gets encoded at %C3%A9, but when I export the library from Mac, a normal 'e' is printed, followed by %CC%81.
Example:
Song Name: Héllo World
Windows Export: H%C3%A9llo World
Mac Export: He%CC%81llo World
This is important to me for a program I'm making where, in the Windows version, I decode the encoding, but now it doesn't work if the file comes from a Mac.
So why is there this difference? Is there a place I can see the differences and see what the Mac encodings are? Is there maybe an Object-C routine to decode these strings?
Thanks.
Upvotes: 2
Views: 3968
Reputation: 522135
C3A9
is the UTF-8 encoding for the character é.
CC81
is the UTF-8 encoding for the COMBINING ACUTE ACCENT character (U+0301).
An "e" followed by a COMBINING ACUTE ACCENT combines to the character "é".
The two are simply different forms of Unicode normalization.
Why one iTunes prefers one over the other I don't know, there's no inherent reason to do so.
Upvotes: 6