Any chance the unicode backspace character would solve your problem?
http://www.fileformat.info/info/unicode/char/0008/index.htm
Update
One other idea. Have you looked into the XDocument.Save(TextWriter textWriter, SaveOptions saveOptions)
method? The documentation says that if you use SaveOptions.DisableFormatting
, it will preserve spacing.
DanM
2010-01-29 05:41:07