W3C home > Mailing lists > Public > public-html@w3.org > July 2011

[Bug 13411] New: The spec for setting selectionEnd seems incorrect (or at least incompatible with the symmetric selectionStart case)

From: <bugzilla@jessica.w3.org>
Date: Thu, 28 Jul 2011 16:07:39 +0000
To: public-html@w3.org
Message-ID: <bug-13411-2495@http.www.w3.org/Bugs/Public/>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=13411

           Summary: The spec for setting selectionEnd seems incorrect (or
                    at least incompatible with the symmetric
                    selectionStart case)
           Product: HTML WG
           Version: unspecified
          Platform: PC
               URL: http://www.whatwg.org/specs/web-apps/current-work/mult
                    ipage/association-of-controls-and-forms.html#dom-texta
                    rea/input-selectionend
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: HTML5 spec (editor: Ian Hickson)
        AssignedTo: ian@hixie.ch
        ReportedBy: ehsan@mozilla.com
         QAContact: public-html-bugzilla@w3.org
                CC: bzbarsky@mit.edu, mike@w3.org,
                    public-html-wg-issue-tracking@w3.org,
                    public-html@w3.org, Ms2ger@gmail.com


For selectionStart, the spec says:

"On setting, it must act as if the setSelectionRange() method had been called,
with the new value as the first argument; the current value of the selectionEnd
attribute as the second argument, unless the current value of the selectionEnd
is less than the new value, in which case the second argument must also be the
new value; and the current value of the selectionDirection as the third
argument."

For selectionEnd, it says:

"On setting, it must act as if the setSelectionRange() method had been called,
with the current value of the selectionStart attribute as the first argument,
the current value of the selectionEnd attribute as the first argument, and the
new value as the third argument."

That sentence is wrong :-)  Also, I think we should explicitly mention that if
the new value is less than the current value of selectionStart, the first
argument should also be the new value.

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
Received on Thursday, 28 July 2011 16:07:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:17:37 GMT