Joseph Buchignani <joseph.buchign...@gmail.com> writes: > Hi, > > I'm using EmacsW32 on XP. I had a crash. After reboot, the emacs file was > corrupted. All punctuation marks - apostrophes, dashes, etc and chinese > characters - now displayed as octal codes. I manually replaced some of the > damaged punctuation with M-x string-replace. However the chinese characters > and > exotic punctuations are irretrievable.
Are you talking about the original file, a backup file, or the autosave file? > I've read a lot of confusing information about setting character sets and > encodings. But all that's working fine, I just need to recover the damaged > octals. Do you have any idea what the original coding-system that the file was encoded in would be? That would be one possiblity. utf-8-emacs could be another, especially if the exotic punctuation now shows as two octal codes rather than one, and the Chinese characters show as three or more octal codes per character. If you are using an older Emacs, it could also be emacs-mule. Most likely some part of the file is now corrupted so that Emacs can no longer recognize it automatically as the encoding that it is. Forcing the encoding will hopefully allow you to recover most of the original data, if you know what the encoding originally was or can guess (if it has Chinese characters - as opposed to Japanese or Korean, then the choices of coding-system can be narrowed down.