Summary: | selectionHasStyle doesn't handle text-specific properties properly | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ryosuke Niwa <rniwa> | ||||||||||||||
Component: | HTML Editing | Assignee: | Ryosuke Niwa <rniwa> | ||||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||||
Severity: | Normal | CC: | eric, justin.garcia, tonikitoo | ||||||||||||||
Priority: | P3 | ||||||||||||||||
Version: | 528+ (Nightly build) | ||||||||||||||||
Hardware: | PC | ||||||||||||||||
OS: | All | ||||||||||||||||
Bug Depends on: | 27865, 28055 | ||||||||||||||||
Bug Blocks: | 23892 | ||||||||||||||||
Attachments: |
|
Description
Ryosuke Niwa
2009-07-30 15:20:42 PDT
Created attachment 33849 [details]
fixes the bug, large because converts a pixel test to a dumpastext.
Created attachment 33852 [details]
fixed per comment on IRC
Will fix // CSS properties that only has a visual difference when applied to text. to // CSS properties that have a visual difference only if applied to text. Comment on attachment 33852 [details]
fixed per comment on IRC
will split into two patches.
Created attachment 34107 [details]
fixes the bug
Comment on attachment 34107 [details]
fixes the bug
Converting the tests in one patch and then changing them in a second would be clearer.
The test conversion bug is filed as https://bugs.webkit.org/show_bug.cgi?id=28055 and the corresponding patch has been submitted. Created attachment 34236 [details]
resubmission after split
Comment on attachment 34236 [details]
resubmission after split
Looks OK.
Comment on attachment 34236 [details]
resubmission after split
+ WebKit now applies the text styles (bold, italic, etc) if the specified style was not present on
+ at least one text node, rather than at the beginning of selection. This change is tested in toggle-compound-styles.
Sorry I didn't notice this until now but we behaved this way to match Mac OS X editing behavior (TextEdit). Perhaps we should preserve the old behavior for Mac-only.
Created attachment 34325 [details]
reverts the behavioral change in Mac
Created attachment 34329 [details]
fixes the bug and changes the WebKit behavior on all platforms except mac
mn... I don't know why it has svn property change. that doesn't seem right. should i delete that property change before I commit? Landed in http://trac.webkit.org/changeset/46920. |