?

Log in

No account? Create an account

Previous Entry | Next Entry

Bug: Line Endings

I've encountered problems with line endings in text pasted into iJournal before a post. Since the underlying protocol is HTTP-based, all lines should end in \r\n. However, \r text pasted into a NSTextView looks just like \r\n text. So, if I were to copy from my web browser, paste to iJournal, do some typing and then post, I would be submitting something with mixed line endings. This leads to automatic formatting issues and if I then edit a post, single \r's have been stripped leaving one block of text. Ick.

The solution (I think) would be to process all text before submitting it, converting all line endings to \r\n.

In general, iJournal really kicks some ass. Thanks,
Michael

Comments

( 2 comments — Leave a comment )
cryo
Mar. 23rd, 2002 10:04 pm (UTC)
there's a lineendings setting when I send the message, the choices are unix for \r\n and macintosh for \r. Are there specific applications that you are pasting from like from classic or carbon, or from cocoa? The ones I've test are cocoa, so that may be why I haven't seen them.
extraneous
Mar. 23rd, 2002 11:05 pm (UTC)
Internet Explorer is the example I encounter most often. I just did a test and was incorrect in my original post (should have checked it.) \n is used as a line ending when copying from IE, not \r as I originally claimed. It presents the same problem, however.
( 2 comments — Leave a comment )

Profile

ijournal
iJournal: Official LiveJournal Client for Mac OS X
iJournal Home

Latest Month

January 2012
S M T W T F S
1234567
891011121314
15161718192021
22232425262728
293031    

Page Summary

Powered by LiveJournal.com
Designed by Lilia Ahner