WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
REOPENED
73047
Justifying text resets typing style
https://bugs.webkit.org/show_bug.cgi?id=73047
Summary
Justifying text resets typing style
Ryosuke Niwa
Reported
2011-11-23 13:31:59 PST
Created
attachment 116412
[details]
demo Justifying text via execCommand erroneously resets typing style. http:://crbug.com/103741
Attachments
demo
(438 bytes, text/html)
2011-11-23 13:31 PST
,
Ryosuke Niwa
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Ryosuke Niwa
Comment 1
2011-11-23 13:36:42 PST
Actually, this behavior matches IE, FF, & Opera. So won't fix.
Vasiliy Baranov
Comment 2
2011-11-23 22:08:18 PST
May I ask how it was concluded that this behavior matches IE, FF, & Opera? I tried the original test from the Chromium bug in FF 6.0.1, FF 8.0, IE 6, and IE 8, and found that it works as expected in these browsers, whereas in Safari, Chromium, and WebKit nightly build it does not. The test attached to this issue does not do any editing in FF and IE: you will see that if you remove the following text from the test: <b>hello</b><div style="text-align: left;"><b>world</b>
Vasiliy Baranov
Comment 3
2011-11-23 22:57:16 PST
(In reply to
comment #2
)
> The test attached to this issue does not do any editing in FF and IE
If it is not obvious, FF and IE do not support the "InsertText" command, that is why the test attached to this issue does not work in these browsers. I spent some time trying to modify the test to insert text in cross-browser manner, but could not come up with a reliable solution. So, at the moment, I can only reproduce this problem manually, e.g. using the test attached to the Chromium bug.
Ryosuke Niwa
Comment 4
2011-11-23 23:00:13 PST
You're right. It's a bad test case :(
Aryeh Gregor
Comment 5
2011-12-01 10:49:39 PST
Correct behavior here is that justify* should preserve typing style (overrides in the spec's terminology). The spec currently does this, with the "Record current overrides" and "Restore states and values" steps here:
http://dvcs.w3.org/hg/editing/raw-file/tip/editing.html#justify-the-selection
It doesn't actually preserve overrides for insertParagraph right now, but that's a separate bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug