The International Simutrans Forum

Community => Community Discussion => Forum => Topic started by: jamespetts on April 14, 2019, 05:44:48 PM

Title: Carriage return issues
Post by: jamespetts on April 14, 2019, 05:44:48 PM
I notice that, when using the standard editor (i.e., when "Toggle view" has not been selected), it often happens that double carriage returns are not respected as such, with the result that breaks between paragraphs inserted for formatting purposes disappear and the text is harder to read. I have noticed this for some time, but have not got around to reporting this until now.
Title: Re: Carriage return issues
Post by: Isaac Eiland-Hall on April 19, 2019, 04:01:56 AM
I'll see if I can poke at this, but delving into SMF's code doesn't give me hope for a solution. :(
Title: Re: Carriage return issues
Post by: An_dz on April 29, 2019, 12:04:46 AM
By standard do you mean the WYSIWYG editor or the plain text one?
Title: Re: Carriage return issues
Post by: jamespetts on April 30, 2019, 11:04:07 AM
Quote from: An_dz on April 29, 2019, 12:04:46 AM
By standard do you mean the WYSIWYG editor or the plain text one?

I mean the one that is selected by default when clicking "reply", i.e., the WYSIWYG editor.
Title: Re: Carriage return issues
Post by: Leartin on April 30, 2019, 01:24:37 PM
For completions sake: Whether it's WYSIWYG or not by default is a setting in the users profile, so "the default" is not quite a helpful description :)
Title: Re: Carriage return issues
Post by: An_dz on May 06, 2019, 01:59:57 AM
Exactly what Leartin said, I was not clear enough. I wanted to know if the bug happens when going plain -> WYSIWYG or WYSIWYG -> plain.

But now I see that it's WYSIWYG -> plain.




Fixed. It uses an HTML5 feature called contenteditable and it has no standard on its output. SMF was outputting Firefox-like html on WebKit/Blink and also got it wrong on how to transform it back to plain text on WebKit/Blink.
Title: Re: Carriage return issues
Post by: Carl on August 07, 2019, 01:06:24 PM
Just came to this forum to post a similar bug. The following post appears to have paragraph breaks in the WYSIWYG editor but these don't appear in the post:
https://forum.simutrans.com/index.php/topic,7367.msg181291.html#msg181291 (https://forum.simutrans.com/index.php/topic,7367.msg181291.html#msg181291)


I also had terrible trouble formatting this post the other day - after having done it in WYSIWYG I first ended up with no line breaks at all - and it didn't match the preview.
https://forum.simutrans.com/index.php/topic,7367.msg181252.html#msg181252 (https://forum.simutrans.com/index.php/topic,7367.msg181252.html#msg181252)

Is the solution just not to use the WYSIWYG editor?
Title: Re: Carriage return issues
Post by: An_dz on August 07, 2019, 08:35:37 PM
Yes, not using the WYSIWYG editor will yield no problems, I never used it.