RESOLVED FIXED Bug 97266
Deleting across multiple paragraphs can change the style of surrounding text
https://bugs.webkit.org/show_bug.cgi?id=97266
Summary Deleting across multiple paragraphs can change the style of surrounding text
Ryosuke Niwa
Reported 2012-09-20 15:33:59 PDT
Deleting text from multiple paragraphs can alter the style of surrounding text if all text involved have the same style from css rules and have inline style declaration.
Attachments
Demo (674 bytes, text/html)
2012-09-20 15:34 PDT, Ryosuke Niwa
no flags
Fixes the bug (11.50 KB, patch)
2012-10-05 11:08 PDT, Ryosuke Niwa
leviw: review+
Ryosuke Niwa
Comment 1 2012-09-20 15:34:18 PDT
Jelte Liebrand
Comment 2 2012-09-21 03:14:13 PDT
This defect impacts our Document Viewer for Chrome. Ideally the spans that get created during the deletion of a selection (to merge the text) would inherit the className of the original spans. However, as this is potentially tricky, at the very least it would be great if the span would get the same styling applied to it such that the text looks OK.
Ojan Vafai
Comment 3 2012-09-21 10:06:40 PDT
Filed related bug 97345 for maintaining attributes on inlines.
Ryosuke Niwa
Comment 4 2012-10-05 11:08:56 PDT
Created attachment 167356 [details] Fixes the bug
Levi Weintraub
Comment 5 2012-10-05 11:18:29 PDT
Comment on attachment 167356 [details] Fixes the bug View in context: https://bugs.webkit.org/attachment.cgi?id=167356&action=review Looks good. We talked in person. > Source/WebCore/editing/EditingStyle.cpp:1027 > - if (node->isStyledElement()) { > + if (node->isStyledElement() && !isMailBlockquote(node)) { I understand this change, but wish there were explanation in the changelog. > LayoutTests/ChangeLog:8 > + Added a regerssion test and rebaselined tests. like smfr said ;)
Ryosuke Niwa
Comment 6 2012-10-05 11:26:19 PDT
Note You need to log in before you can comment on or make changes to this bug.