FROM : Stéphane Sudre
DATE : Tue Jul 25 23:20:19 2006
Let's say I want to save the following string in a .plist file:
"this is a stupid line of text, isn't it?\r"
and the resulting .plist shall be something like this:
<I don't remember the plist header so this is a replacement>
<dict>
<key>A string</key>
<string> this is a stupid line of text, isn't it?
</string>
</dict>
</I should remember them though>
The idea being to have the \r character be replaced by its hexa value.
If I save a NSDictionary using the writeToFile:atomically: API, I will
get a '\r'.
If I replace the \r with 
, I will get &#x0D; of course.
Any idea on how to do this?
DATE : Tue Jul 25 23:20:19 2006
Let's say I want to save the following string in a .plist file:
"this is a stupid line of text, isn't it?\r"
and the resulting .plist shall be something like this:
<I don't remember the plist header so this is a replacement>
<dict>
<key>A string</key>
<string> this is a stupid line of text, isn't it?
</string>
</dict>
</I should remember them though>
The idea being to have the \r character be replaced by its hexa value.
If I save a NSDictionary using the writeToFile:atomically: API, I will
get a '\r'.
If I replace the \r with 
, I will get &#x0D; of course.
Any idea on how to do this?






Cocoa mail archive

