Last modified: 2014-02-28 23:04:43 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T52419, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 50419 - VisualEditor: Selection over a line (with shift-down) applies formatting changes to second line (where logical selection ends), not just first line (where visible selection ends)
VisualEditor: Selection over a line (with shift-down) applies formatting chan...
Status: ASSIGNED
Product: VisualEditor
Classification: Unclassified
ContentEditable (Other open bugs)
unspecified
All All
: Low normal
: ---
Assigned To: Editing team bugs – take if you're interested!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-06-29 12:23 UTC by Axel Boldt
Modified: 2014-02-28 23:04 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Axel Boldt 2013-06-29 12:23:28 UTC
Suppose an article contains two lines in Paragraph formatting, and we want to turn the first one into Heading formatting. Select the entire first line (Cursor at beginning of line, Shift-CursorDown) then choose Heading formatting from the selection box at the top. Result: both lines are turned into Headings, not just the first. (Bold and italics formatting changes work correctly and affect only the current line.)
Comment 1 Rummana Yasmeen 2013-10-29 21:22:34 UTC
This issue exists for all kind of formatting from the Headings pull-down menu.
Comment 2 James Forrester 2013-11-26 13:04:05 UTC
This is the same behaviour as in other rich editors.

By selecting in the manner you've stated ("Cursor at beginning of line, Shift-CursorDown") you've selected the current text, the current line, AND the newline into the place before the first character.

If you mark the text as bold (which is character-level) the boldness becomes a "pre-annotation" on the second line before the first character (so typing anything at that point will become bold).

However, changing the format (rather than styling) of some text applies to the entire paragraph (because that's how HTML works) – i.e., the entire second line gets this applied.

We could theoretically apply different behaviour for styling and formatting, so we apply over a newline for the first but not the second, but that might be more unexpected?

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links