• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Ascii number of return
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ascii number of return


  • Subject: Re: Ascii number of return
  • From: Doug McNutt <email@hidden>
  • Date: Thu, 22 Oct 2009 16:13:22 -0600

At 08:35 +1100 10/23/09, Shane Stanley quoted:
>>From the documentation: "Which line or paragraph break character you should
>use depends on how your data may be used and on what platforms." And: "The
>default choice for Cocoa is usually \n [linefeed]."

Just to add a bit to the confusion... On this machine, an 8500 running MPW on OS 9.1, \n refers to the carriage return character 13 and \r refers to the linefeed 10. MPW uses a Greek delta instead of a backslash.

Somewhere there is a "standard", perhaps ASCII itself, that the escaped r and n are supposed to make return and linefeed behave the way they should in a system-independent way.

Most shells recognize the return character as a command to return to the start of the line just written so that new characters overwrite the old. That's how curl's progress strip works.

The linefeed advances the paper and strangely then executes a return. That is not the way the historical standard, the ASR-33 teletypewriter, works. You need to send a return and a linefeed and a few nulls to give the machine time to prepare for a new character.  \n\r\0\0\0\0 was common but the actual codes representing the two were 5 bit items. It was quite possible to send a linefeed and continue typing characters at the next horizontal position in the next line down. Early line printers could create 64 shades of gray by overprinting lines before issuing a line feed.

RYRYRYRYRYRYRYRYRY

And editors that insist on changing return and linefeed characters to make them all the same in a document drive me crazy - BBEdit!

--
--> So are we going to celebrate the start of a new decade at the end of this year? Or do the tens start at in January 2011? <--
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Ascii number of return
      • From: Jeff Jungblut <email@hidden>
References: 
 >Re: Ascii number of return (From: Shane Stanley <email@hidden>)

  • Prev by Date: Re: Ascii number of return
  • Next by Date: Re: exists mailbox
  • Previous by thread: Re: Ascii number of return
  • Next by thread: Re: Ascii number of return
  • Index(es):
    • Date
    • Thread