Skip to content

Missing "Insert" and "Delete" keys from the Event Key Location table #347

@denilsonsa

Description

@denilsonsa

The 5.6.2. Keyboard Event Key Location section (source) has a table of several keys that have different locations, and a list of all the possible (and known) values for .location for such keys. It also says:

For all other keys not listed in this table, the location attribute MUST always be set to DOM_KEY_LOCATION_STANDARD.

However, the Insert and Delete keys are missing from that table. Those keys are traditionally together with Home/End and Page Up/Down; and they are also available as Numpad0 and NumpadDecimal.

Additionally, both Firefox and Chrome (on Linux) report Insert and Delete with .location = 3 (DOM_KEY_LOCATION_NUMPAD), deviating from the current draft. Thus, I believe the lack of those keys in the UI Events spec was a mistake. (I have not tested on any other system.)

You can test the behavior yourself by disabling NumLock and trying those keys on either https://dvcs.w3.org/hg/d4e/raw-file/tip/key-event-test.html or https://codepen.io/denilsonsa/pen/epmoma

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions