About line breaks in Matlab under Mac OS and Windows

There is a slight, necessary difference between the Mac and Win versions of the M files in the Psychtoolbox. Mac and Win use different invisible characters to mark the ends of lines. Win marks the ends of lines with CRLF and Mac marks the ends of lines with CR. "CR" is carriage return. "LF" is linefeed.

We use the same files to produce both the Mac and Win archives, but we apply a filter, either TextToWin or TextToMac, to convert all line endings in TEXT files to the correct flavor: CRLF for Windows or CR for Mac. (TextToWin and TextToMac execute under Mac OS.)

Current versions of Matlab (6 on Win and 5.2 on Mac) correctly recognize line breaks of either flavor, but the older Win:Matlab 5 fails to recognize Mac style linebreaks.


David Brainard, Denis Pelli & Allen Ingling.
psychtoolbox@yahoogroups.com

18 June 2002.