[Smaug] CR/LF, wordwrap, newline & ASCII

Rick Moen rick at linuxmafia.com
Fri, 14 Jun 2002 20:05:31 -0700


Quoting Paul Thomas (paul@cuenet.com):

> If Mac Eudora does soft-wrapping with inserting hard breaks, how did
> the ^M characters get in there?

You tell me:  Were the so-called ^M characters (which only _display_ 
as ^M, being actually the non-dislayable ASCII #13 decimal Carriage
Return = CR character) solely at the ends of paragraphs, or were they
also in the middle of sentences, as if they were hard returns at the end
of < 80 column lines?

To repeat what I said earlier, even MacOS software that buys into the
soft-wrapping religion _does_ use hard returns to designate the ends
of paragraphs.  If you think about it for a minute, you'll realise that
that's the only way paragraph breaks would be possible in an
auto-wrapping regime.  

For that matter, there are plenty of Linux editors that behave likewise
or can be easily made to.  nedit would be one obvious example.  The only 
differences is that, by default they insert ASCII #10 decimal (Line Feed
= LF) characters instead of CRs to indicate hard returns.

In any event, the hard returns got into your your Mac-using friend's
text files because some MacOS editor program put them there, either
following some inner compulsion about where hard returns should be
inserted, or because your friend pushed Enter there.

-- 
Cheers,      "On the face of it, Microsoft complaining about the source license 
Rick Moen    used by Linux is like the event horizon calling the kettle black."
rick@linuxmafia.com             -- Adam Barr, former Microsoft Corp. programmer