[webkit-dev] [HTML Editing] WebKit's implementation of removeFormat is completely different from other UAs.

Maciej Stachowiak mjs at apple.com
Mon Jul 26 13:10:19 PDT 2010

On Jul 26, 2010, at 11:46 AM, Ryosuke Niwa wrote:

> Thanks a lot for the feedback!
> On Sun, Jul 25, 2010 at 5:07 PM, Maciej Stachowiak <mjs at apple.com> wrote:
> I think the key question here is what counts as as "formatting". That needs to be determined empirically by testing other browsers, not just by reading their docs.
> I agree, it's crucial that we carefully decide on what to preserve and what to not.
> But MSDN explicitly say "character formatting" and bugs such as 
> Bug 13125 - removeformat execCommand loses input elements
> Bug 20216 - execCommand RemoveFormat removes links
> indicates that there is a demand to correct WebKit's behavior.

If our goal is to match other browsers, we need to test them, not read the docs. MSDN often bears little relation to IE's actual behavior.

> I agree.  We should test and see what other browsers do in various cases.
> But since it's impossible for us to enumerate every possible formatting, I propose to just remove text-decoration, font-weight, etc... and the corresponding presentational elements probably using ApplyStyleCommand as a starting point.  We can then file a separate bug or so to uncover edge cases and polish the behavior.

Sure it's possible. We can test every CSS property and every HTML element. It should be easy to write a test case that checks every case exhaustively. I don't think it makes sense to change our behavior based on a guess of what other browsers do.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20100726/84567777/attachment.html>

More information about the webkit-dev mailing list