himselfv / ScrapbookFS

Firefox Scrapbook plugin backed by File/Folder structure instead of RDF file
Mozilla Public License 2.0
0 stars 0 forks source link

Think through CRLF handling in notes #2

Open himselfv opened 8 years ago

himselfv commented 8 years ago

Newline on Windows is traditionally \r\n. Meanwhile Firefox controls seem to have it as just \r, and that is saved to .txt if you just write the text.

I'm currently replacing it \r\n before saving, but this is just as bad since on Linux it is traditionally the other way, just \r.

Ideally, it should:

pascallothar commented 8 years ago

on Linux it is traditionally the other way, just \r.

No, on Linux, it is \n (LF).


I think that on Mac, it is \r (CR).

And, I think, but I am not sure, that \r\n will be understood by Linux and Mac, even if it is not native for them.