Re: NSString Drawing Accents
Re: NSString Drawing Accents
- Subject: Re: NSString Drawing Accents
- From: Karl Goiser <email@hidden>
- Date: Tue, 15 Apr 2003 14:19:22 +1000
Thanks for the responses Chris and Douglas.
I am reading the putative UTF-8 data in from a file using
stringWithContentsOfFile. The thing is is that when I draw the string,
it all looks the same - with square root signs.
Here's an example:
Take a string like
(1)
zC)z
(zed, e accent, zed) in a file.
If I look at it in TextEdit, I get:
(2)
zbB)z
(zed, square root sign, copyright sign, zed)
If I do a 'more' on the file in Terminal, I see (1).
As above, TextEdit shows (2)
If I look at it in the debugger, I see (2)
drawing it out shows (2)
If I enter (1) in a string constant (with @" and "), I see (1) in
ProjectBuilder's editor, but NSString's draw displays it as (2).
If I do a hexdump of the file, I see: 7a c3 a9 7a
To me, that looks like (2) is the natural encoding of (1), that at the
point where it is drawn, it has been unchanged, but that the draw
method doesn't understand UTF-8!
Regards,
Karl
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.