What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 131 Stack Exchange communities.

Whenever I use the question/answer editor's link button, to insert a link, the link gets inserted correctly, but then each line-break is doubled (which means I now have three line-breaks between paragraphs, and single line breaks get empty lines = paragraph breaks.)

Repeating this doubles the line-breaks again, now I have seven empty lines between paragraphs. As an example, here is a screenshot from the editor of a question on the new crypto StackExchange (still in private beta), after inserting three inline links:

screenshot - many empty lines

Actually, the same thing occurs after inserting an image (look at the source code of this question to see a single example).

This is happening since a day or two (I'm not quite sure), in Opera 11.50 on Ubuntu 11.04. (It does not happen in Firefox 5.0 on the same system.)

share|improve this question
    
It does seem to be Opera-specific; reproduced. –  Tim Stone Jul 17 '11 at 1:21
    
I've never had this happen and it doesn't appear to be reproducible to me on Chrome or Firefox. I don't have Opera installed, though. All of you Opera troublemakers... :-) –  Cody Gray Jul 17 '11 at 4:38

1 Answer 1

up vote 3 down vote accepted

This is :

if (uaSniffed.isOpera) {
    chunk.before = chunk.before.replace(/\n/g, "\r\n");
    chunk.selection = chunk.selection.replace(/\n/g, "\r\n");
    chunk.after = chunk.after.replace(/\n/g, "\r\n");
}

– but I'm inclined to question this design :)

There's no explanatory comment around this piece of code (which, except for changed variable names, has always been in the editor JavaScript); I'll assume that this was working around an Opera issue that has since been fixed, and thus this special handling can be dropped now.

share|improve this answer
    
Could be that this got superfluous (or at least, damaging) with Opera 11.50. So maybe a version toggle? (Or we simply wait if now someone with an earlier Opera version complains, to see for what it was good.) –  Paŭlo Ebermann Jul 17 '11 at 10:40
    
Thanks, it seems to work now. –  Paŭlo Ebermann Jul 18 '11 at 13:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .