text in fields (CR/LF, CR, LF) which is correct?

Kee Nethery kee at kagi.com
Fri Aug 30 07:32:01 CDT 2002


>J. Landman Gay wrote:
>
>>  "Shao Sean" <shaosean at unitz.ca> wrote:
>>
>>>  i use the constant LINEFEED and let the engine determine if it's just 0x10,
>>>  0x13 or both..
>>
>>  I think the constant "return" also does the same thing as "linefeed" and
>>  "cr".
>
>Pretty much, with the exception of its use in "crlf":
>
>Linefeed  = ASCII 10
>cr/return = ASCII 10 -- the UNIX line ending
>crlf      = ASCII 13 & ASCII 10
>
>So much confusion surrounds the misnamed constants "return" and "cr", which
>suggest ASCII 13 but are actually ASCII 10.  I understand that it's there
>for compatibility with Mac-specific tools like HC, but it does create
>confusion (hence this oft-repeated thread).

might be better to create a new constant called "LineEnd" that is 
platform specific. Return and CR should mean "carriage Return" which 
should be ascii(13). Pretty much every ASCII table I've ever seen 
labels "CR" as ASCII(13).

Kee



More information about the use-livecode mailing list