[Webkit-unassigned] [Bug 53465] Can't remove style when selection starts with a horizontal rule

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Aug 19 14:07:02 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=53465


Aryeh Gregor <ayg at aryeh.name> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ayg at aryeh.name




--- Comment #3 from Aryeh Gregor <ayg at aryeh.name>  2011-08-19 14:07:02 PST ---
My spec pays attention only to editable text nodes when determining the state/value of inline commands.  E.g.:

"""
If a command has inline command activated values defined, its state is true if either no editable Text node is effectively contained in the active range, and the active range's start node's effective command value is one of the given values; or if there is at least one editable Text node effectively contained in the active range, and all of them have an effective command value equal to one of the given values.
"""
http://aryeh.name/spec/editing/editing.html#inline-command-activated-values

So in the selection {<hr><u>foo</u>}, the only editable text node effectively contained in the selection is "foo", and that's underlined, so queryCommandState("underline") is true.  This works well for inline style commands, since the styles are mostly only relevant to text nodes, and we can only change editable nodes so those are the only ones we should care about.

It might make sense to also care about <br>, but <hr> should almost definitely be ignored here.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list