CR LF Problem in Windows XP
Ron Teitelbaum
Ron at USMedRec.com
Wed Apr 5 15:14:39 UTC 2006
I went back to see what I did. I only set
lineEndConvention: #crlf.
But then saw the wantsLineEndConversion: wasn't set. So I figured I was
doing it wrong. Shouldn't this be automatic for each platform?
I'll try just setting wantsLineEndConversion: true like you suggested and
see what it does.
Ron Teitelbaum
> -----Original Message-----
> From: squeak-dev-bounces at lists.squeakfoundation.org [mailto:squeak-dev-
> bounces at lists.squeakfoundation.org] On Behalf Of Yoshiki Ohshima
> Sent: Tuesday, April 04, 2006 4:57 PM
> To: The general-purpose Squeak developers list
> Subject: Re: CR LF Problem in Windows XP
>
> Ron,
>
> > I saw the CRLF stream but figured there was some magic way to get the
> file
> > to use it. I saw ascii and all those flags for #crlf and
> wantsEndConversion
> > or something like that but nothing worked.
>
> Didn't a code snippet like following work?
>
> f _ FileStream newFileNamed: 'foo.txt'.
> f wantsLineEndConversion: true.
> f nextPutAll: 'abc\def' withCRs
> f close.
>
> To specify it explicitly:
>
> f _ FileStream newFileNamed: 'foo.txt'.
> f wantsLineEndConversion: true.
> f lineEndConvention: #crlf.
> f nextPutAll: 'abc\def' withCRs.
> f close.
>
> should work, too.
>
> -- Yoshiki
More information about the Squeak-dev
mailing list
|