Page MenuHomePhabricator

Newline handling when using edit toolbar buttons
Closed, ResolvedPublic

Description

Try selecting a text which includes a newline, and clicking the bold button. Several bugs occur:

  • the ''' marks will only be placed at the beginning and end of selection, which will not produce the expected result (one could say that is a bug with the parser rather than with the edit interface, but that would still leave the problem of double newlines).
  • the newline turns into a double newline.
  • newlines are inserted to the beginning and end of the selection.

(FF3.5/WinXP)

This behavior is even more counter-intuitive with lists; for example, I would expect

a
b
c

to turn into

  • a
  • b
  • c

when selected and listified.


Version: unspecified
Severity: minor

Details

Reference
bz22488

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:57 PM
bzimport added a project: WikiEditor.
bzimport set Reference to bz22488.
bzimport added a subscriber: Unknown Object (MLST).

(In reply to comment #0)

Try selecting a text which includes a newline, and clicking the bold button.
Several bugs occur:

  • the ''' marks will only be placed at the beginning and end of selection,

which will not produce the expected result (one could say that is a bug with
the parser rather than with the edit interface, but that would still leave the
problem of double newlines).

Maybe the bold button should operate on each line individually.

  • the newline turns into a double newline.
  • newlines are inserted to the beginning and end of the selection.

(FF3.5/WinXP)

That's weird, I'll look into that.

This behavior is even more counter-intuitive with lists; for example, I would
expect

a
b
c

to turn into

  • a
  • b
  • c

when selected and listified.

That's bug 22209.

TheDJ subscribed.

Most of this is solved, other than the potential point of splitting up the bolding per line. Since we have not had any comments about this since 2011 however when this was introduced, I'm guessing it is not too much of a problem, And we should probably just close it.