WD-DOM-Level-3-Events-20110531 695 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>Document Object Model (DOM) Level 3 Events Specification</title>
    <link rel="author" href="mailto:www-dom@w3.org" />
    <link rel="help" href="http://www.w3.org/webapps/" />
    <link rel="alternate stylesheet" type="text/css" media="screen" title="geek" href="geek.css" />
    <link rel="stylesheet" type="text/css" href="./spec.css" />
    
    <link rel="stylesheet" type="text/css" href="http://www.w3.org/StyleSheets/TR/w3c-tr.css" />
    <link rel="stylesheet" type="text/css" href="http://www.w3.org/StyleSheets/TR/W3C-WD" />
    
<!--     <link rel="stylesheet" type="text/css" href="w3c-tr.css" />
    <link rel="stylesheet" type="text/css" href="W3C-ED" /> -->
    
    <!-- <link rel="local stylesheet" type="text/css" href="W3C-WD.css" /> -->
  </head>
  <body>
    <div id="Overview" class="head">
      <p>
        <a href="http://www.w3.org/">
          <img height="48" width="72" alt="W3C" src="http://www.w3.org/Icons/w3c_home" />
        </a>
      </p>
      <h1 id="Overview-title">Document Object Model (DOM) Level 3 Events Specification</h1>
<!-- @-->
      <h2 id="Overview-W3C-doctype">W3C Working Draft <span class="2011-05-31">31 May 2011</span></h2>
      <dl>
        <dt>This version:</dt>
        <dd><a href="http://www.w3.org/TR/2011/WD-DOM-Level-3-Events-20110531">http://www.w3.org/TR/2011/WD-DOM-Level-3-Events-20110531</a></dd>

        <dt>Latest stable version:</dt>
        <dd><a href="http://www.w3.org/TR/DOM-Level-3-Events/">http://www.w3.org/TR/DOM-Level-3-Events/</a></dd>

        <dt>Previous version:</dt>
        <dd><a href="http://www.w3.org/TR/2010/WD-DOM-Level-3-Events-20100907">http://www.w3.org/TR/2010/WD-DOM-Level-3-Events-20100907</a></dd>

        <dt>Editor's Draft:</dt>
        <dd><a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html">http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html</a></dd>

		    <dd><br/></dd>
        <dt>Public Comments:</dt>
        <dd>
          <a href="mailto:www-dom@w3.org">www-dom@w3.org</a> 
          (<a href="http://lists.w3.org/Archives/Public/www-dom/">archive</a>)
        </dd>
        <dt>Working Group:</dt>
        <dd>
          <a href="http://www.w3.org/2008/webapps/">Web Applications WG</a>
        </dd>
        
      </dl>
      <dl>
        <dt>Editors:</dt>
        <dd>Doug Schepers, <em>W3C</em></dd>
		    <dd>Jacob Rossi, <em>Microsoft</em></dd>
		    
		    <dd><br/></dd>
        <dd>Bj&#xF6;rn H&#xF6;hrmann, <em>Invited Expert (until December 2007)</em></dd>
        <dd>Philippe Le H&#xE9;garet, <em>W3C (until November 2003)</em></dd>
        <dd>Tom Pixley, <em>Netscape Communications Corporation (until July 2002)</em></dd>
      </dl>
      <p class="copyright" id="copyright-copy-2010-w3creg-mit-ercim-kei">
        <a href="http://www.w3.org/Consortium/Legal/ipr-notice#Copyright">Copyright</a>
       &#xA9; 2010 <a href="http://www.w3.org/"><acronym title="World Wide Web Consortium">W3C</acronym></a><sup>&#xAE;</sup> 
       (<a href="http://www.csail.mit.edu/"><acronym title="Massachusetts Institute of Technology">MIT</acronym></a>, 
       <a href="http://www.ercim.org/"><acronym title="European Research Consortium for Informatics and Mathematics">ERCIM</acronym></a>, 
       <a href="http://www.keio.ac.jp/">Keio</a>), All Rights Reserved. W3C <a href="http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer">liability</a>,
       <a href="http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks">trademark</a>
       and <a href="http://www.w3.org/Consortium/Legal/copyright-documents">document
       use</a> rules apply.</p>
              
    </div>
    <hr title="separator from header" />
    <h2><a id="Overview-abstract" href="#Overview-abstract">Abstract</a></h2>

    <div class="abstract">
      <p>This specification defines the Document Object Model Events Level 3, a generic platform- and language-neutral event system which allows registration of event handlers, describes event flow through a tree structure, and provides basic contextual information for each event. The Document Object Model Events Level 3 builds on the Document Object Model Events Level 2 [<a href="#references-DOM2Events">DOM2 Events</a>].</p>
    </div>
    
    <h2 class="no-num no-toc" id="sotd">Status of This Document</h2>
    <div>
      <p><em>This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the <a href="http://www.w3.org/TR/">W3C technical reports index</a> at http://www.w3.org/TR/.</em></p>
      
      <p><strong>This document is the Last Call Working Draft of the Document Object Model Level 3 Events (DOM3 Events) specification.</strong> This document was previously published as a W3C Note, pending further feedback from implementers, and is now being revised to reflect the current state of implementation.  It is expected that this specification will progress to W3C Recommendation status after review and refinement.</p>
      <p>The <a href="http://www.w3.org/2008/webapps/">Web Applications Working Group</a> (WebApps WG) believes this specification to be feature complete, subject to further feedback during the Last Call period.  The Last Call period extends through 28 June 2011.  The public is encouraged to send comments to the WebApps Working Group's public mailing list for DOM specifications <a href="mailto:www-dom@w3.org">www-dom@w3.org</a> (<a href="http://lists.w3.org/Archives/Public/www-dom/">archive</a>).  See <a href="http://www.w3.org/Mail/">W3C mailing list and archive usage guidelines</a>.</p> 


      <p id="this-document-is-produced-by-the-web-app">This document is produced
        by the <a href="http://www.w3.org/2008/webapps/">Web Applications WG</a>,
        part of the <a href="http://www.w3.org/2006/rwc/Activity">Rich Web
        Clients Activity</a> in the W3C <a href="http://www.w3.org/Interaction/">Interaction Domain</a>. It is
        expected that this document will progress along the W3C's Recommendation
        track. Publication as a Working Draft does not imply endorsement by the
        W3C Membership. This is a draft document and may be updated, replaced or
        obsoleted by other documents at any time. It is inappropriate to cite
        this document as other than work in progress.</p>

      <p id="latest-editors-draft"><strong>You can find the latest <a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html">Editor's Draft</a> of this document in the <a href="http://dev.w3.org/">W3C's CVS repository</a>, which is updated on a regular basis.</strong></p>


      <p>Publication as a Working Draft does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.</p>
      <p id="this-document-was-produced-by-a-group-op">This document was produced by a group operating under the <a href="http://www.w3.org/Consortium/Patent-Policy-20040205/">5 February 2004 W3C Patent Policy</a>. W3C maintains a <a href="http://www.w3.org/2004/01/pp-impl/42538/status" rel="disclosure">public list of any patent disclosures</a> made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains <a href="http://www.w3.org/Consortium/Patent-Policy-20040205/#def-essential">Essential Claim(s)</a> must disclose the information in accordance with <a href="http://www.w3.org/Consortium/Patent-Policy-20040205/#sec-Disclosure">section 6 of the W3C Patent Policy</a>.</p>

      <p id="unstable"><strong class="redNote">Implementers should be aware that this document is not
        stable.</strong> Implementers who are not taking part in the discussions
        are likely to find the specification changing out from under them in
        incompatible ways. Vendors interested in implementing this document
        before it eventually reaches the Candidate Recommendation stage should
        join the aforementioned mailing lists and take part in the discussions.</p>
    </div>
    
    <h2 id="Overview-table-of-contents">
      <a id="Overview-contents">Table of Contents</a>
    </h2>
    <ul class="toc">
      <li><a href="#dom-events">1. Document Object Model Events</a>
        <ul class="toc">
          <li><a href="#dom-events-overview">1.1 Introduction</a></li>
          <li><a href="#dom-events-conformance">1.2 Conformance</a></li>
          <li><a href="#feature-detection">1.3 Feature Detection</a></li>
          <li><a href="#style-conventions">1.4 Stylistic Conventions</a></li>
        </ul>
      </li>
      <li><a href="#glossary" class="glossary">2. Glossary</a></li>
      <li><a href="#dom-event-architecture">3. DOM Event Architecture</a>
        <ul class="toc">
          <li><a href="#event-flow">3.1 Event dispatch and DOM event flow</a></li>
          <li><a href="#event-flow-default-cancel">3.2 Default actions and cancelable events</a></li>
          <li><a href="#sync-async">3.3 Synchronous and asynchronous events</a>
            <ul class="toc">
              <li><a href="#event-order-and-loops">3.3.1 Event order and event loops</a></li>
            </ul>
          </li>
          <li><a href="#trusted-events">3.4 Trusted events</a></li>
          <li><a href="#event-flow-activation">3.5 Activation triggers and behavior</a>
            <ul class="toc">
              <li><a href="#events-activation-event-order">3.5.1 Activation Event Order</a></li>
            </ul>
          </li>
        </ul>
      </li>
      <li><a href="#event-interfaces">4. Basic Event Interfaces</a>
        <ul class="toc">
          <li><a href="#interface-Event">4.1 Interface Event</a></li>
          <li><a href="#interface-CustomEvent">4.2 Interface CustomEvent</a></li>
          <li><a href="#interface-EventTarget">4.3 Interface EventTarget</a></li>
          <li><a href="#interface-EventListener">4.4 Interface EventListener</a></li>
          <li><a href="#interface-DocumentEvent">4.5 Interface DocumentEvent</a>
            <ul class="toc">
              <li><a href="#event-creation">4.5.1 Event creation</a></li>
            </ul>
          </li>
        </ul>
      </li>
      <li><a href="#events-module">5. Events Module</a>
        <ul class="toc">
          <li><a href="#event-types">5.1 Event Types</a>
            <ul class="toc">
              <li><a href="#event-types-list">5.1.1 List of DOM3 Event Types</a></li>
            </ul>
          </li>
          <li><a href="#event-definitions">5.2 Event Module Definitions</a>
            <ul class="toc">
              <li><a href="#events-uievents">5.2.1 User Interface Event Types</a>
                <ul class="toc">
                  <li><a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-load"><code>load</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-unload"><code>unload</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-abort"><code>abort</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-error"><code>error</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-select"><code>select</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-resize"><code>resize</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-scroll"><code>scroll</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-focusevent">5.2.2 Focus Event Types</a>
                <ul class="toc">
                  <li><a href="#events-focusevent-event-order">5.2.1.1 Focus Interface Event Order</a></li>
                  <li><a href="#events-focusevent-doc-focus">5.2.1.2 Document Focus and Focus Context</a></li>
                  <li><a class="eventtype" href="#event-type-blur"><code>blur</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-focus"><code>focus</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-focusIn"><code>focusin</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-focusout"><code>focusout</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-mouseevents">5.2.3 Mouse Event Types</a>
                <ul class="toc">
                  <li><a href="#events-mouseevent-event-order">5.2.3.2 Mouse Event Order</a></li>
                  <li><a class="eventtype" href="#event-type-click"><code>click</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-dblclick"><code>dblclick</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mousedown"><code>mousedown</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mousemove"><code>mousemove</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mouseover"><code>mouseover</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mouseout"><code>mouseout</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-mouseup"><code>mouseup</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-wheelevents">5.2.4 Wheel Event Types</a>
                <ul class="toc">
                  <li><a class="eventtype" href="#event-type-wheel"><code>wheel</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-textevents">5.2.5 Text Event Types</a>
                <ul class="toc">
                  <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-keyboardevents">5.2.6 Keyboard Event Types</a>
                <ul class="toc">
                  <li><a href="#events-keyboard-event-order">5.2.6.1 Keyboard Event Order</a></li>
                  <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-keypress"><code>keypress</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-compositionevents">5.2.7 Composition Event Types</a>
                <ul class="toc">
                  <li><a href="#events-composition-event-order">5.2.7.1 Composition Event Order</a></li>
                  <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code> event</a></li>
                  <li><a href="#handwriting">5.2.7.2 Handwriting Recognition Systems</a></li>
                </ul>
              </li>
              <li><a href="#events-mutationevents">5.2.8 Mutation Events</a>
                <ul class="toc">
                  <li><a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument"><code>DOMNodeInsertedIntoDocument</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument"><code>DOMNodeRemovedFromDocument</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMSubtreeModified"><code>DOMSubtreeModified</code> event</a></li>
                </ul>
              </li>
              <li><a href="#events-mutationnameevents">5.2.9 Mutation Name Event Types</a>
                <ul class="toc">
                  <li><a class="eventtype" href="#event-type-DOMAttributeNameChanged"><code>DOMAttributeNameChanged</code> event</a></li>
                  <li><a class="eventtype" href="#event-type-DOMElementNameChanged"><code>DOMElementNameChanged</code> event</a></li>
                </ul>
              </li>
            </ul>
          </li>
        </ul>
      </li>
      <li><a href="#keys">6. Keyboard events and key values</a>
        <ul class="toc">
          <li><a href="#keyboard-input">6.1 Keyboard Input</a>
            <ul class="toc">
              <li><a href="#key-legends">6.1.1 Key Legends</a></li>
              <li><a href="#keyboard-layout">6.1.2 Keyboard Layout</a>
                <ul class="toc">
                  <li><a href="#keyboard-desktop">6.1.2.1 Desktop and Laptop Keyboards</a></li>
                  <li><a href="#keyboard-mobile">6.1.2.2 Mobile Keypads</a></li>
                  <li><a href="#keyboard-chording-virtual">6.1.2.4 Virtual Keyboards and Chording Keyboards</a></li>
                </ul>
              </li>
            </ul>
          </li>
          <li><a href="#keys-keyvalues">6.2 Key Values</a>
            <ul class="toc">
              <li><a href="#keys-unicode">6.2.1 Key Values and Unicode</a></li>
              <li><a href="#keys-Modifiers">6.2.2 Modifier keys</a></li>
              <li><a href="#keys-DeadKeys">6.2.3 Dead keys</a></li>
              <li><a href="#keys-IME">6.2.4 Input Method Editors</a>
                <ul class="toc">
                  <li><a href="#keys-IME_keys">6.2.4.1 Input Method Editor mode keys</a></li>
                </ul>
              </li>
              <li><a href="#keys-cancelable_keys">6.2.5 Default actions and cancelable keyboard events</a></li>
              <li><a href="#keys-Guide">6.2.6 Guidelines for selecting and defining key values</a></li>
              <li><a href="#key-values">6.2.7 Key Values Set</a>
                <ul class="toc">
                  <li><a href="#key-values-legend">6.2.7.1 Key Values Legend</a></li>
                  <li><a href="#key-values-list">6.2.7.2 Key Values List</a></li>
                </ul>
              </li>
            </ul>
          </li>
        </ul>
      </li>
      <li><a href="#legacy-key-attributes">Appendix A: Legacy key attributes: keyCode, charCode, and which</a>
        <ul class="toc">
          <li><a href="#KeyboardEvent-supplemental-interface">A.1 Legacy KeyboardEvent supplemental interface</a></li>
          <li><a href="#legacy-key-models">A.2 Legacy key models</a>
            <ul class="toc">
              <li><a href="#determine-keydown-keyup-keyCode">A.2.1 How to determine keyCode for keydown and keyup events</a></li>
              <li><a href="#determine-keypress-keyCode">A.2.2 How to determine keyCode for keypress events</a></li>
              <li><a href="#fixed-virtual-key-codes">A.2.3 Fixed virtual key codes</a></li>
              <li><a href="#optionally-fixed-virtual-key-codes">A.2.4 Optionally fixed virtual key codes</a></li>
            </ul>
          </li>
        </ul>
      </li>
      <li><a href="#extending_events">Appendix B: Extending Events</a>
        <ul class="toc">
          <li><a href="#extending_events-intro">B.1 Introduction</a></li>
          <li><a href="#extending_events-Custom_Events">B.2 Custom Events</a></li>
          <li><a href="#extending_events-Impl_Extensions">B.3 Implementation-Specific Extensions</a>
            <ul class="toc">
              <li><a href="#extending_events-prefixes">B.3.1 Known Implementation-Specific Prefixes</a></li>
            </ul>
          </li>
        </ul>
      </li>
	  <li><a href="#webidl-definitions">Appendix C: Web IDL Interface Definitions</a>
        <ul class="toc">
          <li><a href="#webidl-events-Event">Interface Event</a></li>
          <li><a href="#webidl-events-CustomEvent">Interface CustomEvent</a></li>
          <li><a href="#webidl-events-EventTarget">Interface EventTarget</a></li>
          <li><a href="#webidl-events-EventListener">Interface EventListener</a></li>
          <li><a href="#webidl-events-EventException">Exception EventException</a></li>
          <li><a href="#webidl-events-DocumentEvent">Interface DocumentEvent</a></li>
          <li><a href="#webidl-events-UIEvent">Interface UIEvent</a></li>
          <li><a href="#webidl-events-FocusEvent">Interface FocusEvent</a></li>
          <li><a href="#webidl-events-MouseEvent">Interface MouseEvent</a></li>
          <li><a href="#webidl-events-WheelEvent">Interface WheelEvent</a></li>
          <li><a href="#webidl-events-TextEvent">Interface TextEvent</a></li>
          <li><a href="#webidl-events-KeyboardEvent">Interface KeyboardEvent</a></li>
          <li><a href="#webidl-events-CompositionEvent">Interface CompositionEvent</a></li>
          <li><a href="#webidl-events-MutationEvent">Interface MutationEvent</a></li>
          <li><a href="#webidl-events-MutationNameEvent">Interface MutationNameEvent</a></li>
        </ul>
      </li>
      <li><a href="#security-considerations-Security">Appendix D: Security Considerations</a></li>
      <li><a href="#changes-Changes">Appendix E: Changes</a>
        <ul class="toc">
          <li><a href="#changes-DOMEvents2to3Changes">E.1 Changes between DOM Level 2 Events and DOM Level 3 Events</a>
            <ul class="toc">
              <li><a href="#changes-DOMEvents2to3Changes-flow">E.1.1 Changes to DOM Level 2 event flow</a></li>
              <li><a href="#changes-DOMEvents2to3Changes-event-types">E.1.2 Changes to DOM Level 2 event types</a></li>
              <li><a href="#changes-DOMLevel2to3Changes">E.1.3 Changes to DOM Level 2 Events interfaces</a></li>
              <li><a href="#changes-DOMLevel3Addons">E.1.4 New Interfaces</a></li>
            </ul>
          </li>
          <li><a href="#changes-drafts">E.2 Changes between different drafts of DOM Level 3 Events</a></li>
        </ul>
      </li>
      <li><a href="#acknowledgements-contributors">Appendix F: Acknowledgements</a>
        <ul class="toc">
          <li><a href="#acknowledgements-Productions">F.1 Production Systems</a></li>
        </ul>
      </li>
      <li><a href="#references-role-references" class="references">Appendix G: References</a>
        <ul class="toc">
          <li><a href="#references-References-Normative">G.1 Normative References</a></li>
          <li><a href="#references-References-Informative">G.2 Informative References</a></li>
        </ul>
      </li>
    </ul>
    
    
    <div>
      <h1><a id="dom-events" href="#dom-events">1. Document Object Model Events</a></h1>

      
      <div>
        <h2><a id="dom-events-overview" href="#dom-events-overview">1.1 Introduction</a></h2>

        <p>DOM Events is designed with two main goals. The first goal is the design of an <a class="def" href="#glossary-event">event</a> system which allows registration of event listeners and describes event flow through a tree structure. Additionally, the specification will provide standard modules of events for user interface control and document mutation notifications, including defined contextual information for each of these event modules.</p>
        <p>The second goal of DOM Events is to provide a common subset of the current event systems used in existing browsers. This is intended to foster interoperability of existing scripts and content. It is not expected that this goal will be met with full backwards compatibility. However, the specification attempts to achieve this when possible.</p>
        <div>
          <h3><a id="dom-events-conformance" href="#dom-events-conformance">1.2 Conformance</a></h3>

          <p><strong>This section is normative.</strong></p>
          <p>Within this specification, the key words 
            “MUST”, 
            “MUST NOT”,
            “REQUIRED”, 
            “SHALL”, 
            “SHALL NOT”, 
            “SHOULD”, 
            “SHOULD NOT”,
            “RECOMMENDED”, 
            “MAY”, and 
            “OPTIONAL” are to be interpreted as
            described in <a href="http://www.ietf.org/rfc/rfc2119.txt">RFC 2119</a>
            [<a href="#ref-rfc2119">RFC2119</a>].
            However, for readability, these words do not necessarily appear in uppercase in this specification.</p>
          <p>This specification is to be understood in the context of the DOM Level 3 Core specification [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>] and the general considerations for DOM implementations apply. For example, behavior in exceptional circumstances (such as when a <code>null</code> argument is passed when <code>null</code> was not expected) is discussed under <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-17189187"><em>DOMException</em></a>, and handling of <a class="def" href="#glossary-namespaceURI">namespace URIs</a> is discussed in <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#Namespaces-Considerations"><em>XML Namespaces</em></a>. For additional information about <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/introduction.html#ID-Conformance"><em>conformance</em></a>, please see the DOM Level 3 Core specification [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>].  A <a class="def" href="#glossary-user-agent">user agent</a> is not required to conform to the entirety of another specification in order to conform to this specification, but it must conform to the specific parts of any other specification which are called out in this specification (e.g., a conforming DOM3 Events <a class="def" href="#glossary-user-agent">user agent</a> must support the <code>DOMString</code> data type as defined in DOM3 Core, but need not support every method or data type defined in DOM3 Core in order to conform to DOM3 Events).</p>
          <p>This specification defines several classes of conformance for different <a class="def" href="#glossary-user-agent">user agents</a>, specifications, and content authors:</p>
          <dl>
            
            <dt id="conf-interactive-ua">Web browsers and other dynamic or interactive <a class="def" href="#glossary-user-agent">user agents</a></dt>
            <dd>
              <p>A dynamic or interactive <a class="def" href="#glossary-user-agent">user agent</a>, referred to here as a “browser” (be it a Web browser, AT (Accessibility Technology) application, or other similar program), conforms to DOM Level 3 Events if it supports the Core module defined in [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>], the <a href="#event-flow">Event dispatch and DOM event flow</a> mechanism, all the interfaces and events with their associated methods, attributes, and semantics defined in this specification which are not marked as <a class="def" href="#glossary-deprecated">deprecated</a>, and the complete set of <a class="def" href="#glossary-character-value">character values</a> and <a class="def" href="#glossary-key-value">key values</a> in the <a href="#key-values">Key Values Set</a> (subject to platform availability), as well as all other normative requirements defined in this specification.  A conforming browser must <a class="def" href="#glossary-dispatch">dispatch</a> events appropriate to the given <a href="#events-EventTarget">EventTarget</a> when the conditions defined for that <a class="def" href="#glossary-event-type">event type</a> have been met.</p>
              <p><span id="conform-arch">A browser conforms specifically to the DOM Level 3 Events Architecture if it implements the <a href="#dom-event-architecture">DOM Event Architecture</a> and <a href="#event-interfaces">Basic Event Interfaces</a>, regardless of its support for any other event interfaces or <a class="def" href="#glossary-event-type">event types</a> defined in this specification.</span>  <span id="conform-module">A browser conforms specifically to the DOM Level 3 Events Module if it implements the interfaces and its related <a class="def" href="#glossary-event-type">event types</a> specified in the <a href="#events-module">Events Module</a>, and to each event interface if it implements that interface and its related <a class="def" href="#glossary-event-type">event types</a>.</span></p>
              <p><span id="conform-script">A conforming browser must support scripting, declarative interactivity, or some other means of detecting and dispatching events in the manner described by this specification, and with the attributes specified for that <a class="def" href="#glossary-event-type">event type</a>.</span>  <span id="conform-declarative">A declarative browser may still conform to this specification if it does not directly support or expose the methods defined for the DOM Level 3 Events interfaces, but it should provide compatible functionality by other means.</span></p>
              <p>In addition to meeting all other conformance criteria, a conforming browser may implement features of this specification marked as <a class="def" href="#glossary-deprecated">deprecated</a>, for backwards compatibility with existing content, but such implementation is discouraged.</p>
              <p>A conforming browser may also support features not found in this specification, but which use the <a href="#event-flow">Event dispatch and DOM event flow</a> mechanism, interfaces, events, or other features defined in DOM Level 3 Events, and may implement additional interfaces and <a class="def" href="#glossary-event-type">event types</a> appropriate to that implementation.  Such features may be later standardized in future specifications.</p>
              <p>A browser which does not conform to all required portions of this specification must not claim conformance to DOM Level 3 Events.  Such an implementation which does conform to portions of this specification may claim conformance to those specific portions.</p>
<!-- //if we move to Web IDL, use something like the HTML5 wording:
              <p>A conforming browser must also be conforming implementations of the IDL fragments in this specification, as described in the Web IDL specification. <a href="references.html#refsWEBIDL">[WEBIDL]</a></p> -->
            </dd>

            <dt id="conf-author-tools">Authoring tools</dt>
            <dd>
              <p>A content authoring tool conforms to DOM Level 3 Events if it produces content which uses the <a class="def" href="#glossary-event-type">event types</a> and <a href="#event-flow">Event dispatch and DOM event flow</a> model, consistent in a manner as defined in this specification.  A content authoring tool must not claim conformance to DOM Level 3 Events for content it produces which uses features of this specification marked as <a class="def" href="#glossary-deprecated">deprecated</a><!--  or <a class="def" href="#glossary-obsolete">obsolete</a> --> in this specification.  A conforming content authoring tool should provide to the content author a means to use all <a class="def" href="#glossary-event-type">event types</a> and interfaces appropriate to all <a class="def" href="#glossary-host-language">host languages</a> in the content document being produced.</p>
            </dd>

            <dt id="conf-authors">Content authors and content</dt>
            <dd>
              <p>A content author creates conforming DOM Level 3 Events content if that content uses the <a class="def" href="#glossary-event-type">event types</a> and <a href="#event-flow">Event dispatch and DOM event flow</a> model, consistent in a manner as defined in this specification.  A content author should not use features of this specification marked as <a class="def" href="#glossary-deprecated">deprecated</a><!--  or <a class="def" href="#glossary-obsolete">obsolete</a> -->, but should rely instead upon replacement mechanisms defined in this specification and elsewhere.  Conforming content must use the semantics of the interfaces and <a class="def" href="#glossary-event-type">event types</a> as described in this specification, and must follow best practices as described in accessibility and internationalization guideline specifications. <!-- <i class="issue" id="issue-guidelines"><strong>Issue:</strong> define specific guideline specifications.</i> --></p>
            </dd>

            <dt id="conf-specs">Specifications and host languages</dt>
            <dd>
              <p>A specification or <a class="def" href="#glossary-host-language">host language</a> conforms to DOM Level 3 Events if it references and uses the <a href="#event-flow">Event dispatch and DOM event flow</a> mechanism, interfaces, events, or other features defined in this specification, and does not extend these features in incompatible ways.  A specification or <a class="def" href="#glossary-host-language">host language</a> conforms specifically to the DOM Level 3 Events Architecture if it references and uses the <a href="#dom-event-architecture">DOM Event Architecture</a> and <a href="#event-interfaces">Basic Event Interfaces</a>, regardless of its use of any other event interfaces or <a class="def" href="#glossary-event-type">event types</a> defined in this specification.  A specification or <a class="def" href="#glossary-host-language">host language</a> conforms specifically to the DOM Level 3 Events Module if it references and uses the interfaces and its related <a class="def" href="#glossary-event-type">event types</a> specified in the <a href="#events-module">Events Module</a>, and to each event interface if it references and uses that interface and its related <a class="def" href="#glossary-event-type">event types</a>.  <span id="conf-extend">A conforming specification may define additional interfaces and <a class="def" href="#glossary-event-type">event types</a> appropriate to that specification, or may extend the DOM Level 3 Events interfaces and <a class="def" href="#glossary-event-type">event types</a> in a manner that does not contradict or conflict with the definitions of those interfaces and <a class="def" href="#glossary-event-type">event types</a> in this specification.  Events defined in conforming specifications must not have name conflicts with known languages, and should be defined in a manner that can be generalized for use with other specifications conforming to DOM Level 3 Events, as much as is possible.</span>  Specifications or <a class="def" href="#glossary-host-language">host languages</a> which reference DOM Level 3 Events should not use or recommend features of this specification marked as <a class="def" href="#glossary-deprecated">deprecated</a><!--  or <a class="def" href="#glossary-obsolete">obsolete</a> -->, but should point instead to the indicated replacement for that the feature.  Editors of specifications referring to DOM Level 3 Events should consult with the Working Group responsible for this specification when using or extending the features defined in this specification.</p>
            </dd>
          </dl>
        </div>

        <div>
          <h3><a id="feature-detection" href="#feature-detection">1.3 Feature Detection</a></h3>

          <p><em>This section is normative</em></p>
          <p>A conforming DOM Level 3 Events <a class="def" href="#glossary-user-agent">user agent</a> must implement the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method to allow content authors to detect for support of features defined in this specification.  Refer to <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#DOMFeatures"><em>DOM Features</em></a> in [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>] for additional information on feature strings.</p>
          <p class="note" id="_0"><strong>Note:</strong> The <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method has been of limited utility to content authors in some instances, because of imprecision in conformance criteria in some specifications, and insufficient granularity of feature strings, leading to implementations misrepresenting the degree of support for a class of features.  This specification seeks to remedy that in the context of <a class="def" href="#glossary-user-agent">user agents</a> conforming to DOM Level 3 Events by providing discrete feature strings and clear guidelines for the circumstances under which a <a class="def" href="#glossary-user-agent">user agent</a> must or must not report in a positive manner when queried for support of the feature which that feature string represents.</p>
          <p>DOM Level 3 Events introduces compositional feature strings, which are base feature strings combined with extended feature strings, a new mechanism for testing support for each specific feature, rather than relying on modules-level feature strings.  A <a class="def" href="#glossary-user-agent">user agent</a> conforming to DOM Level 3 Events must also implement the following feature string convention for describing DOM3 Events feature support:</p>
          <ul>
            <li id="base-feature-string">The primary base feature string for DOM Level 3 Events must be “<code>Events</code>”, with the optional version string “<code>3.0</code>”, indicating that the <a class="def" href="#glossary-user-agent">user agent</a> supports the <a href="#conform-arch">DOM Level 3 Events Architecture</a> in the manner described in the appropriate conformance section.
              <ul>
                <li><span class="assert must">Since DOM Level 3 Events is built on top of DOM Level 2 Events [<cite><a class="normative" href="#references-DOM2Events">DOM2 Events</a></cite>], an implementation that returns <code>true</code> for <code>"Events"</code> and <code>"3.0"</code> must also return <code>true</code> for the parameters <code>"Events"</code> and <code>"2.0"</code>.</span></li>
                <li><span class="assert mustnot">If the version parameter is omitted, the <a class="def" href="#glossary-user-agent">user agent</a> must not differentiate between the <a href="#conform-arch">DOM Events Architecture</a> as described in DOM Level 3 Events and DOM Level 2 Events, in terms of reporting support for the features indicated by the base feature string.</span></li>
              </ul>
            </li>
            <li id="extended-feature-string">The extended feature string for each event type defined in DOM Level 3 Events must be the base feature string “<code>Events</code>”, followed by the period character ("."), followed by the name of that event type, with the optional version string “<code>3.0</code>”, indicating that the <a class="def" href="#glossary-user-agent">user agent</a> supports that specific event type in the manner described in the appropriate <a href="#conform-module">conformance section</a>.  For example, the feature string for the <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event would be “<code>Events.textinput</code>”, with the optional version string “<code>3.0</code>”.
              <ul>
                <li><span class="assert must">Because this specification does not retroactively define extended feature strings for DOM Level 2 Events, using the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method with extended feature strings with a version string “<code>2.0</code>” must return false.</span><span class="warning" id="_42"><strong>Warning!</strong> Because this mechanism for discrete feature strings was not defined in earlier DOM Events specifications, older user agents which support those specifications but not this one may report false negatives in terms of supporting particular features.  For example, a browser which supports the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type as defined in DOM Level 2 Events, but does not support this specification, is likely to return <code>false</code> to the method call <code>document.implementation.hasFeature("Events.click", "")</code>.  The content author should not take this for definitive proof that the implementation does not support the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, but rather that other means of testing are required in that instance.  This method is best used as a means to detect positive results, not negative ones.  However, it is expected that this will prove of sufficient utility in many cases to justify its use.</span></li>
                <li><span class="assert must">A <a class="def" href="#glossary-user-agent">user agent</a> which supports an event type in a manner conforming to DOM Level 2 Events but not conforming to DOM Level 3 Events must not report a positive result to that extended feature string, regardless of the value of the version string.</span></li>
                <li><span class="assert must">A specification or <a class="def" href="#glossary-host-language">host language</a> which <a href="#conf-specs">conforms</a> to DOM Level 3 Events, and which extends this specification in a manner consistent with the <a href="#conf-extend">extension conformance criteria</a>, may define extended feature strings for event types defined in that specification.  These extended feature strings may be used with the feature string “<code>Events</code>”.<!-- These extended feature strings may be used with the <a href="#base-feature-string">base feature string</a> of that specification, or with the feature string "<code>Events</code>"; for example, support for the SVG <code>zoom</code> event type might be tested using the method call <code>document.implementation.hasFeature("Events.zoom", "")</code> or the hypothetical <code>document.implementation.hasFeature("SVG.events.zoom", "")</code>. --></span>
                    <p class="example" id="example-zoom"><strong>Example:</strong> Support for the SVG <code>zoom</code> event type might be tested using the method call <code>document.implementation.hasFeature("Events.zoom", "")</code></p>
                  <!-- <ul>
                    <li><span class="assert may">A specification or <a class="def" href="#glossary-host-language">host language</a> which extends event types defined in this specification, but which adds functionality to be detected independently.  </span></li>
                  </ul> -->
                </li>
              </ul>
            </li>
            <li>For backwards compatibility, each interface defined in DOM Level 3 Events also has a feature string, which may act as a base feature string or as an extended feature string.  If used as a base feature string, it must follow the conventions of the <a href="#base-feature-string">primary base feature string</a> (e.g., “<code>KeyboardEvent</code>”, with the optional version string “<code>3.0</code>”); if used as an extended feature string, it must follow the conventions of the <a href="#extended-feature-string">extended feature strings for event types</a> (e.g., “<code>Events.KeyboardEvent</code>”, with the optional version string “<code>3.0</code>”).  In either case, the <a class="def" href="#glossary-user-agent">user agent</a> must only report a positive result if it supports that specific interface and all associated event types in the manner described in the appropriate <a href="#conform-module">conformance section</a>.  <span class="warning" id="_2"><strong>Warning!</strong> because this is not as specific as testing for a specific event type and may thus be less likely to be accurate, content authors are encouraged to use the feature strings for event types rather than interfaces.</span></li>
          </ul>
          <p class="warning" id="_3"><strong>Warning!</strong> This specification does not provide a means to guarantee that any given element of a <a class="def" href="#glossary-host-language">host language</a> is capable of generating or dispatching an event of any given <a class="def" href="#glossary-event-type">event type</a> (e.g., an HTML <code>'img'</code> element may not dispatch a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event), or what the attributes of that event will be beyond those defined in this specification (e.g., the host language may add attributes to the event object).  A  <a class="def" href="#glossary-host-language">host language</a> may provide a different means to do so, including its own relevant feature strings.</p>
        </div>


        <div>
          <h3><a id="style-conventions" href="#style-conventions">1.4 Stylistic Conventions</a></h3>

          <p>The following stylistic conventions are followed in this specification, per the <a href="http://www.w3.org/People/Schepers/spec-conventions.html">Proposed W3C Specification Conventions</a>:</p>
          
          <div style="margin-left: 3em;">
            <p class=""><code>'This is a keyword or value'</code></p>
            <p>
              <a class="eventtype"><code>This is an event type</code></a>
            </p>
            <p>
              <a class="def">This is a link to a definition in the glossary</a>
            </p>
            <p class="note">This is a note.</p>
            <p class="warning">This is a warning.  It is used on security notes and to mark <a class="def" href="#glossary-deprecated">deprecated</a><!--  or <a class="def" href="#glossary-obsolete">obsolete</a> --> features.</p>
            <p class="example">This is an example.</p>
            <p class="atrisk">This is a feature at risk, which is likely to be removed from the specification.</p>
            <p class="proposal">This is a proposed new feature.</p>
            <p class="issue"><strong>Issue:</strong> This is an open issue.</p>
          </div>
          <p>Feedback on features at risk, new features, and open issues is especially appreciated.</p>
          <p>In addition, certain terms are used in this specification with particular meanings.  The term “implementation” applies to a browser, content authoring tool, or other <a class="def" href="#glossary-user-agent">user agent</a> that implements this specification, while a content author is a person who writes script or code that takes advantage of the interfaces, methods, attributes, events, and other features described in this specification in order to make Web applications, and a user is the person who uses those Web applications in an implementation.</p>
        </div>
<!-- div3 Conformance -->
      </div>
<!-- div1 glossary -->
      <div id="glossary-glossary">
        <h1 class="glossary">
          <a id="glossary" href="#glossary">2. Glossary</a>
        </h1>
        <p class="1st">Some of the following term definitions have been borrowed or modified from similar definitions in other W3C or standards documents. See the links within the definitions for more information.</p>
        <dl id="glossary-list">
          <dt id="glossary-activation-behavior"><dfn>activation behavior</dfn></dt>
          <dd>The action taken when an <a class="def" href="#glossary-event">event</a>, typically initiated by users through an input device, causes an element to fulfill a defined task.  The task may be defined for that element by the <a class="def" href="#glossary-host-language">host language</a>, or by author-defined variables, or both.  The default task for any given element may be a generic action, or may be unique to that element.  For example, the activation behavior of an HTML or SVG <code>&lt;a&gt;</code> element is be to cause the <a class="def" href="#glossary-user-agent">user agent</a> to traverse the link specified in the <code>href</code> attribute, with the further optional parameter of specifying the browsing context for the traversal (such as the current window or tab, a named window, or a new window); the activation behavior of an HTML <code>&lt;input&gt;</code> element with the <code>type</code> attribute value <code>submit</code> is be to send the values of the form elements to an author-defined IRI by the author-defined HTTP method.  See <a href="#event-flow-activation">Activation triggers and behavior</a> for more details.</dd>

          <dt id="glossary-activation-trigger"><dfn>activation trigger</dfn></dt>
          <dd>An event which is defined to initiate an <a class="def" href="#glossary-activation-behavior">activation behavior</a>.  Refer to <a href="#event-flow-activation">Activation triggers and behavior</a> for more details.</dd>

          <dt id="glossary-author"><dfn>author</dfn></dt>
          <dd>In the context of this specification, an <em>author</em>, <em>content author</em>, or <em>script author</em> is a person who writes script or other executable content that uses the interfaces, events, and event flow defined in this specification.  See <a href="#conf-authors">Content authors and content</a>  conformance category for more details.</dd>

          <dt id="glossary-bubbling-phase"><dfn>bubbling phase</dfn></dt>
          <dd>The process by which an <a class="def" href="#glossary-event">event</a> can be handled by one of the target ancestors after being handled by the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  See the description of the <a href="#bubble-phase">bubble phase</a> in the context of event flow for more details.</dd>

          <dt id="glossary-capture-phase"><dfn>capture phase</dfn></dt>
          <dd>The process by which an <a class="def" href="#glossary-event">event</a> can be handled by one of the target ancestors before being handled by the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  See the description of the <a href="#capture-phase">capture phase</a> in the context of event flow for more details.</dd>

          <dt id="glossary-character-value"><dfn>character value</dfn></dt>
          <dd>In the context of key values, a character value is a string representing one or more Unicode characters, such as a letter or symbol, or a set of letters.  
            <span class="note" id="note_character-value-escapes"><strong>Note:</strong> in source code, some key values, such as non-graphic characters, may be represented using the character escape syntax of the programming language in use.</span>
          </dd>
          <!-- <dd>In the context of key values, a character value is a string representing a single Unicode character, such as a letter or symbol, as a UTF-16 character escape (e.g., <code class="value">U+0041</code> for the Latin Capital Letter A key, <code class="value charrep">A</code>.). <i class="issue" id="issue-character_value"><strong>Issue:</strong> this may not be the best way to represent a character value, see notes in key values.  Also, is “character value” the best term?</i></dd> -->

          <dt id="glossary-dead-key"><dfn>dead key</dfn></dt>
          <dd>A dead key is a key or combination of keys which produces no character by itself, but which in combination or sequence with another key produces a modified character, such as a character with diacritical marks (e.g., <code>&#xF6;</code>, <code>&#xE9;</code>, <code>&#xE2;</code>).</dd>

          <dt id="glossary-default-action"><dfn>default action</dfn></dt>
          <dd>A <a class="def" href="#glossary-default-action">default action</a> is an optional supplementary behavior that an implementation must perform in combination with the dispatch of the event object.  Each event type definition, and each specification, defines the <a class="def" href="#glossary-default-action">default action</a> for that event type, if it has one.  An instance of an event may have more than one <a class="def" href="#glossary-default-action">default action</a> under some circumstances, such as when associated with an <a class="def" href="#glossary-activation-trigger">activation trigger</a>.  A <a class="def" href="#glossary-default-action">default action</a> may be cancelled through the invocation of the <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> method.  For more details, see <a href="#event-flow-default-cancel">Default actions and cancelable events</a>.</dd>

          <dt id="glossary-defaultView"><dfn>defaultView</dfn></dt>
          <dd>The <code>defaultView</code> is the document's browsing context's Window Proxy object as defined in <a href="http://dev.w3.org/html5/spec/Overview.html#dom-document-defaultview" title="HTML5 defaultView IDL attribute">HTML5</a>.</dd>

          <dt id="glossary-delta"><dfn>delta</dfn></dt>
          <dd>The distance an input device using the <a href="#events-wheelevents">WheelEvent</a> interface (such as a mouse wheel) has rotated around its axis.  The value of a <a class="def" href="#glossary-delta">delta</a> must be a floating point number indicating the number of pixels, lines, or pages scrolled (as indicated by the <a href="#events-WheelEvent-deltaMode"><code>deltaMode</code></a> property. The relationship between the physical direction of rotation and whether the <a class="def" href="#glossary-delta">delta</a> is positive or negative is environment and device dependent. However, if a user agent scrolls as the <a class="def" href="#glossary-default-action">default action</a> then the sign of the <a class="def" href="#glossary-delta">delta</a> is given by a right-hand coordinate system where positive X,Y, and Z axes are directed towards the right-most edge, bottom-most edge, and farthest depth (away from the user) of the document, respectively.
          </dd>

          <dt id="glossary-deprecated"><dfn>deprecated</dfn></dt>
          <dd>Features marked as deprecated are included in the specification as reference to older implementations or specifications, but are optional and discouraged.  Only features which have existing or in-progress replacements must be deprecated in this specification.  Implementations which do not already include support for the feature may implement deprecated features for reasons of backwards compatibility with existing content, but content authors creating content should not use deprecated features, unless there is no other way to solve a use case.  Other specifications which reference this specification should not use deprecated features, but should point instead to the replacements of which the feature is deprecated in favor.  Features marked as deprecated in this specification are expected to be dropped from future specifications.</dd>

          <dt id="glossary-dispatch"><dfn>dispatch</dfn></dt>
          <dd>To create an event with attributes and methods appropriate to its type and context, and propagate it through the DOM tree in the specified manner. Interchangeable with the term “<a href="#glossary-fire">fire</a>", e.g., “fire a 'click' event” or “dispatch a 'load' event”.</dd>

          <dt id="glossary-document"><dfn>document</dfn></dt>
          <dd>An object instantiating the <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#i-Document" title="Document Object Model Core"><code>Document</code> interface</a> [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>], representing the entire HTML or XML text document.  Conceptually, it is the root of the document tree, and provides the primary access to the document's data.</dd>

          <dt id="glossary-DOM-application"><dfn>DOM application</dfn></dt>
          <dd>A DOM application is script or code, written by a content author or automatically generated, which takes advantage of the interfaces, methods, attributes, events, and other features described in this specification in order to make dynamic or interactive content, such as Web applications, exposed to users in a <a class="def" href="#glossary-user-agent">user agent</a>.</dd>

          <dt id="glossary-DOM-Level-0"><dfn>DOM Level 0</dfn></dt>
          <dd>The term “DOM Level 0” refers to a mix of HTML document functionalities, often not formally specified but traditionally supported as de facto standards, implemented originally by Netscape Navigator version 3.0 or Microsoft Internet Explorer version 3.0.  In many cases, attributes or methods have been included for reasons of backward compatibility with “DOM Level 0”.</dd>

          <dt id="glossary-empty-string"><dfn>empty string</dfn></dt>
          <dd>The empty string is a value of type <code>DOMString</code> of length <code>0</code>, i.e., a string which contains no characters (neither printing nor control characters).</dd>

          <dt id="glossary-event"><dfn>event</dfn></dt>
          <dd>An event is the representation of some occurrence (such as a mouse click on the presentation of an element, the removal of child node from an element, or any number of other possibilities) which is associated with its <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  Each event is an instantiation of one specific <a class="def" href="#glossary-event-type">event type</a>.</dd>

          <dt id="glossary-event-order"><dfn>event order</dfn></dt>
          <dd>The sequence in which events from the same event source or process occur, using the same or related event interfaces.  For example, in an environment with a mouse, a track pad, and a keyboard, each of those input devices would constitute a separate event source, and each would follow its own event order; a <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> event from the trackpad followed by a <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> event from the mouse would not result in a <a class="eventtype" href="#event-type-click"><code>click</code></a> event.      
            Note that there may be interactions between different event orders; for example, a <a class="eventtype" href="#event-type-click"><code>click</code></a> event might be modified by a concurrent <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event (<code>shift+click</code>); however, the event orders of these different event sources would be distinct.
            The event order of some interfaces are device-independent; for example, a user might change focus using the <a href="#key-Tab"><code class="value keyname">'Tab'</code></a> key, or by clicking the new focused element with the mouse.  The event order in such cases depends on the state of the process, not on the state of the device that initiates the state change.
          </dd>

          <dt id="glossary-event-phase"><dfn>event phase</dfn></dt>
          <dd>See <a class="def" href="#glossary-phase">phase</a>.</dd>

          <dt id="glossary-event-target"><dfn>event target</dfn></dt>
          <dd>The object to which an <a class="def" href="#glossary-event">event</a> is targeted.</dd>

          <dt id="glossary-event-type"><dfn>event type</dfn></dt>
          <dd>An <em>event type</em> is an <a class="def" href="#glossary-event">event</a> object with a particular name and which defines particular trigger conditions, properties, and other characteristics which distinguish it from other event types.  For example, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type has different characteristics than the <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a> or <a class="eventtype" href="#event-type-load"><code>load</code></a> event types. The event type is exposed as the <a href="#events-event-type-type"><code class="interface-attribute">Event.type</code></a> attribute on the event object.  See <a href="#event-types">event types</a> for more details.  Also loosely referred to as <em>'event'</em>, such as the <em><a class="eventtype" href="#event-type-click"><code>click</code></a> event</em>.</dd>

          <dt id="glossary-event-focus"><dfn>focus</dfn></dt>
          <dd>Focus is a special state of receptivity and concentration on an particular element or other <a class="def" href="#glossary-event-target">event target</a> within a document.  Each element has different behavior when focused, depending on its functionality, such as priming the element for activation (as for a button or hyperlink) or toggling state (as for a checkbox), receiving text input (as for a text form field), or copying selected text.  For more details, see <a href="#events-focusevent-doc-focus">Document Focus and Focus Context</a>.</dd>

          <dt id="glossary-event-focus-ring"><dfn>focus ring</dfn></dt>
          <dd>A focus ring is a an ordered set of <a class="def" href="#glossary-event-focus">focus</a> targets within a document.  A <a class="def" href="#glossary-host-language">host language</a> may define one or more ways to determine the order of targets, such as document order, a numerical index defined per focus target, explicit pointers between focus targets, or a hybrid of different models.  Each document may contain multiple focus rings, or conditional focus rings.  Typically, for document-order or indexed focus rings, focus “wraps around” from the last focus target to the first.</dd>

          <dt id="glossary-fire"><dfn>fire</dfn></dt>
          <dd>A synonym for <a href="#glossary-dispatch">dispatch</a>.</dd>

          <dt id="glossary-host-language"><dfn>host language</dfn></dt>
          <dd>Any language which integrates the features of another language or API specification, while normatively referencing the origin specification rather than redefining those features, and extending those features only in ways defined by the origin specification.  An origin specification typically is only intended to be implemented in the context of one or more host languages, not as a standalone language.  For example, XHTML, HTML, and SVG are host languages for DOM 3 Events, and they integrate and extend the objects and models defined in this specification.</dd>

          <dt id="glossary-hysteresis"><dfn>hysteresis</dfn></dt>
          <dd>A feature of human interface design to accept input values within a certain range of location or time, in order to improve the user experience.  For example, allowing for small deviation in the time it takes for a user to double-click a mouse button is temporal hysteresis, and not immediately closing a nested menu if the user mouses out from the parent window when transitioning to the child menu is locative hysteresis.</dd>

          <dt id="glossary-ime"><dfn>IME</dfn></dt>
          <dt id="glossary-input-method-editor"><dfn>input method editor</dfn></dt>
          <dd>An <em>input method editor</em> (IME), also known as a <em>front end processor</em>, is an application that performs the conversion between keystrokes and ideographs or other characters, usually by user-guided dictionary lookup, often used in East Asian languages (e.g., Chinese, Japanese, Korean).  An <a class="def" href="#glossary-ime">IME</a> may also be used for dictionary-based word completion, such as on mobile devices.  See <a href="#keys-IME">Input Method Editors</a> for treatment of IMEs in this specification.  See also <a class="def" href="#glossary-text-composition-system">text composition system</a>.</dd>

          <dt id="glossary-key-value"><dfn>key value</dfn></dt>
          <dd>A key value is <a class="def" href="#glossary-character-value">character value</a> or multi-character string (such as <code class="value">'Enter'</code>, <code class="value">'Tab'</code>, or <code class="value">'MediaNextTrack'</code>) associated with a key in a particular state.  Every key has a key value, whether or not it has a <a class="def" href="#glossary-character-value">character value</a>; this includes control keys, function keys, <a class="def" href="#glossary-modifier-key">modifier keys</a>, <a class="def" href="#glossary-dead-key">dead keys</a>, and any other key.  The key value of any given key at any given time depends upon the <a class="def" href="#glossary-key-mapping">key mapping</a>.</dd>

          <dt id="glossary-key-mapping"><dfn>key mapping</dfn></dt>
          <dd>Key mapping is the process of assigning a key value to a particular key, and is the result of a combination of several factors, including the operating system and the keyboard layout (e.g., <a class="def" href="#glossary-qwerty">QWERTY</a>, Dvorak, Spanish, InScript, Chinese, etc.), and after taking into account all <a class="def" href="#glossary-modifier-key">modifier key</a> (<a href="#key-Shift"><code class="value keyname">'Shift'</code></a>, <a href="#key-Alt"><code class="value keyname">'Alt'</code></a>, etc.) and <a class="def" href="#glossary-dead-key">dead key</a> states.</dd>

          <dt id="glossary-localname"><dfn>local name</dfn></dt>
          <dd>See local name in [<cite><a class="informative" href="#references-Namespaces10">XML Namespaces 1.0</a></cite>].</dd>

          <dt id="glossary-modifier-key"><dfn>modifier key</dfn></dt>
          <dd>A modifier key changes the normal behavior of a key, such as to produce a character of a different case (as with the <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> key), or to alter what functionality the key triggers (as with the <a href="#key-Fn"><code class="value keyname">'Fn'</code></a> or <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> keys).  Refer to the <a href="#events-KeyboardEvent-getModifierState"><code>KeyboardEvent.getModifierState()</code></a> method for a list of modifier keys defined in this specification.  See also <a href="#keys-Modifiers">Modifier keys</a>.</dd>

          <dt id="glossary-namespaceURI"><dfn>namespace URI</dfn></dt>
          <dd>A <em>namespace URI</em> is a URI that identifies an XML namespace. This is called the namespace name in [<cite><a class="informative" href="#references-Namespaces10">XML Namespaces 1.0</a></cite>]. See also sections 1.3.2 "<a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#baseURIs-Considerations"><em>DOM URIs</em></a>" and 1.3.3 "<a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#Namespaces-Considerations"><em>XML Namespaces</em></a>" regarding URIs and namespace URIs handling and comparison in the DOM APIs.</dd>

          <dt id="glossary-phase"><dfn>phase</dfn></dt>
          <dd>In the context of <a class="def" href="#glossary-event">events</a>, a phase is set of logical traversals from node to node along the DOM tree, from the <a class="def" href="#glossary-defaultView">defaultView</a> (window), to the <code>Document</code> object, <a class="def" href="#glossary-root-element">root element</a>, and down to the <a class="def" href="#glossary-event-target">event target</a> (<a class="def" href="#glossary-capture-phase">capture phase</a>), at the <a class="def" href="#glossary-event-target">event target</a> itself (<a class="def" href="#glossary-target-phase">target phase</a>), and back up the same chain (<a class="def" href="#glossary-bubbling-phase">bubbling phase</a>).</dd>

          <dt id="glossary-propagation-path"><dfn>propagation path</dfn></dt>
          <dd>The ordered set of <a class="def" href="#glossary-event-target">event targets</a> though which an <a class="def" href="#glossary-event">event</a> object will pass sequentially on the way to and back from the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  As the event propagates, each <a class="def" href="#glossary-event-target">event target</a> in the propagation path is in turn set as the <a href="#events-event-type-currentTarget"><code>Event.currentTarget</code></a>.  The propagation path is initially composed of one or more <a class="def" href="#glossary-event-phase">event phases</a> as defined by the <a class="def" href="#glossary-event-type">event type</a>, but may be interrupted.  Also known as an <em>event target chain</em>.</dd>

          <dt id="glossary-proximal-event-target"><dfn>proximal event target</dfn></dt>
          <dd>The proximal event target is the object representing the <a class="def" href="#glossary-event-target">event target</a> to which an <a class="def" href="#glossary-event">event</a> is targeted using the DOM event flow.  The proximal event target is the value of the <a href="#events-event-type-target">Event.target</a> attribute.</dd>

          <dt id="glossary-qwerty"><dfn>QWERTY</dfn></dt>
          <dd>QWERTY (pronounced "&#x2C8;kw&#x25C;rti") is a common keyboard layout, so named because the first five character keys on the top row of letter keys are Q, W, E, R, T, and Y.  There are many other popular keyboard layouts (including the Dvorak and Colemak layouts), most designed for localization or ergonomics.</dd>

          <dt id="glossary-root-element"><dfn>root element</dfn></dt>
          <dd>The first element node of a document, of which all other elements are children; the document element.</dd>

          <dt id="events-WheelEvent-rotation"><dfn>rotation</dfn></dt>
          <dd>An indication of incremental change on an input device using the <a href="#events-wheelevents">WheelEvent</a> interface. On some devices this may be a literal rotation of a wheel, while on others, it may be movement along a flat surface, or pressure on a particular button.</dd>

          <dt id="glossary-text-composition-system"><dfn>text composition system</dfn></dt>
          <dd>A software component that interprets some form of alternate input (such as a <a class="def" href="#glossary-ime">input method editor</a>, a speech processor, or a handwriting recognition system) and converts it to text.</dd>

          <dt id="glossary-target-phase"><dfn>target phase</dfn></dt>
          <dd>The process by which an <a class="def" href="#glossary-event">event</a> can be handled by the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  See the description of the <a href="#target-phase">target phase</a> in the context of event flow for more details.</dd>

          <dt id="glossary-topmost-event-target"><dfn>topmost event target</dfn></dt>
          <dd>The <a class="def" href="#glossary-topmost-event-target">topmost event target</a> must be the element highest in the rendering order which is capable of being an <a class="def" href="#glossary-event-target">event target</a>.  In this case, 'top' must refer not to the position on the screen, but the logical order of the element in relation to other elements in drawing or stacking order on the z-axis (where the x-axis is the screen width and the y-axis is the screen height).  In HTML and CSS, or in SVG, this is controlled by the document order, as modified in HTML and CSS by the <code>'z-index'</code> property.  In some cases, such as when using some values of the SVG <code>'pointer-events'</code> property, the topmost element may not receive pointer events, in which case, the next element in z-index order which can receive pointer-events is the <a class="def" href="#glossary-topmost-event-target">topmost event target</a>.  Note that visibility of the element does not necessarily affect its ability to be the <a class="def" href="#glossary-topmost-event-target">topmost event target</a>, since an element which is hidden by use of the CSS <code>'visibility'</code> property can still receive pointer events (though not one with a <code>'display'</code> property of <code>none</code>), and the <a class="def" href="#glossary-topmost-event-target">topmost event target</a> may be completely obscured by another element which cannot receive pointer events.  Unless otherwise noted, there is only one <a class="def" href="#glossary-topmost-event-target">topmost event target</a> in any event.  For specific details regarding hit testing and stacking order, refer to the <a class="def" href="#glossary-host-language">host language</a>.</dd>

          <dt id="glossary-tree"><dfn>tree</dfn></dt>
          <dd>A data structure that represents a document as a hierarchical set of nodes with child-parent-sibling relationships, i.e., each node having one or more possible ancestors (nodes higher in the hierarchy in a direct lineage), one or more possible descendants (nodes lower in the hierarchy in a direct lineage), and one or more possible peers (nodes of the same level in the hierarchy, with the same immediate ancestor).</dd>

          <dt id="glossary-Unicode-character-categories"><dfn>Unicode character categories</dfn></dt>
          <dd>The Unicode character categories, a subset of the complete Unicode general categories, comprise the categories <abbr title="Letter, Lowercase">Ll</abbr>, <abbr title="Letter, Modifier">Lm</abbr>, <abbr title="Letter, Other">Lo</abbr>, <abbr title="Letter, Titlecase">Lt</abbr>, <abbr title="Letter, Uppercase">Lu</abbr>, <abbr title="Number, Decimal Digit">Nd</abbr>, <abbr title="Number, Letter">Nl</abbr>, <abbr title="Number, Other">No</abbr>, <abbr title="Punctuation, Connector">Pc</abbr>, <abbr title="Punctuation, Dash">Pd</abbr>, <abbr title="Punctuation, Close">Pe</abbr>, <abbr title="Punctuation, Final quote">Pf</abbr>, <abbr title="Punctuation, Initial quote">Pi</abbr>, <abbr title="Punctuation, Other">Po</abbr>, <abbr title="Punctuation, Open">Ps</abbr>, <abbr title="Symbol, Currency">Sc</abbr>, <abbr title="Symbol, Modifier">Sk</abbr>, <abbr title="Symbol, Math">Sm</abbr>, and <abbr title="Symbol, Other">So</abbr>.</dd>

          <dt id="glossary-unicode-code-point"><dfn>Unicode code point</dfn></dt>
          <dd>A Unicode code point is a unique hexadecimal number signifying a character by its index in the Unicode codespace (or library of characters).  In the context of key values, a Unicode code point is expressed as a string in the format “\u” followed by a hexadecimal character index in the range <code>0000</code> to <code>10FFFF</code>, using at least four digits.  See also <a class="def charrep" href="#glossary-character-value">character value</a>.</dd>

          <dt id="glossary-user-agent"><dfn>user agent</dfn></dt>
          <dd>A program, such as a browser or content authoring tool, normally running on a client machine, which acts on a user's behalf in retrieving, interpreting, executing, presenting, or creating content.  Users may act on the content using different user agents at different times, for different purposes.  See the <a href="#conf-interactive-ua">Web browsers and other dynamic or interactive user agents</a> and <a href="#conf-author-tools">Authoring tools</a> for details on the requirements for a <em>conforming</em> user agent.</dd>

        </dl>
      </div>
<!-- div1 glossary -->
<!-- div2 Events-overview -->
      <h2><a id="dom-event-architecture" href="#dom-event-architecture">3. DOM Event Architecture</a></h2>

      <div>
        <h3><a id="event-flow" href="#event-flow">3.1 Event dispatch and DOM event flow</a></h3>

        <p>This section defines the event <a class="def" href="#glossary-dispatch">dispatch</a> mechanism of the event model defined in this specification. <span class="assert may">Applications may dispatch event objects using the <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> method</span>, and <span class="assert must">implementations must dispatch event objects as if through this method.</span> The behavior of this method depends on the <em>event flow</em> associated with the underlying object. An event flow describes how event objects <em>propagate</em> through a data structure. As an example, when an event object is dispatched to an element in an XML document, the object propagates through parts of the document, as determined by the DOM event flow which is defined at the end of this section.</p>
        <div class="figure" style="text-align: center">
          <object type="image/svg+xml" data="images/eventflow.svg" width="520" height="560">
            <img src="images/eventflow.png" alt="graphical representation of an event dispatched in a DOM tree using the DOM event flow" title="graphical representation of an event dispatched in a DOM tree using the DOM event flow" />
          </object>
          <p style="text-align:left">
            <em>Figure 1: graphical representation of an event dispatched in a DOM tree using the DOM event flow</em>
          </p>
        </div>
        <p>Event objects are always dispatched to the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.  <span class="assert must">At the beginning of the dispatch, implementations must first determine the event object's <a class="def" href="#glossary-propagation-path">propagation path</a>.</span></p> 
          <p>The propagation path must be an ordered list of <a class="def" href="#glossary-event-target">event targets</a> through which the event object must pass. For tree-based DOM implementations, the propagation path must be reflect the hierarchical tree structure of the document.  <span class="assert must">The last item in the list must be the <a class="def" href="#glossary-proximal-event-target">proximal event target</a></span>; the preceding items in the list are referred to as the <em>target's ancestors</em>, and the immediately preceding item as the <em>target's parent</em>.  <span class="assert mustnot">Once determined, the propagation path must not be changed; for tree-based DOM implementations, this applies even if an element in the propagation path is moved within the DOM or removed from the DOM.</span> As an example, in the DOM event flow event listeners might change the position of the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> in the document while the event object is being dispatched; such changes do not affect the propagation path. Additionally, exceptions inside event listeners do not stop the propagation of the event or affect the <a class="def" href="#glossary-propagation-path">propagation path</a>.</p>
        <p id="event-phase">As the next step, the event object must complete one or more <a class="def" href="#glossary-phase">event phases</a>. This specification defines three event phases: <a href="#capture-phase">capture phase</a>; <a href="#target-phase">target phase</a>; and <a href="#bubble-phase">bubble phase</a>.  Event objects complete these phases in the specified order using the partial propagation paths as defined below.  <span class="assert must">A phase must be skipped if it is not supported, or if the event object's propagation has been stopped.</span>  For example, if the <a href="#events-event-type-canBubble"><code>Event.bubbles</code></a> attribute is set to false, the bubble phase will be skipped, and if <a href="#events-event-type-stopPropagation"><code>Event.stopPropagation()</code></a> has been called prior to the dispatch, all phases must be skipped.</p>
        <ol>
          <li>The <strong id="capture-phase">capture phase</strong>: <span class="assert must">the event object must propagate through the target's ancestors from the <a class="def" href="#glossary-defaultView">defaultView</a> to the target's parent.</span> This phase is also known as the <em>capturing phase</em>. <span class="assert must">Event listeners registered for this phase must handle the event before it reaches its target.</span></li>
          <li>The <strong id="target-phase">target phase</strong>: <span class="assert must">the event object must arrive at the event object's <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.</span> This phase is also known as the <em>at-target phase</em>. <span class="assert must">Event listeners registered for this phase must handle the event once it has reached its target.</span>  <span class="assert must">If the <a class="def" href="#glossary-event-type">event type</a> indicates that the event must not bubble, the event object must halt after completion of this phase.</span></li>
          <li>The <strong id="bubble-phase">bubble phase</strong>: <span class="assert must">the event object propagates through the target's ancestors in reverse order, starting with the target's parent and ending with the <a class="def" href="#glossary-defaultView">defaultView</a>.</span> This phase is also known as the <em>bubbling phase</em>. <span class="assert must">Event listeners registered for this phase must handle the event after it has reached its target.</span></li>
        </ol>
        
        <p>
          <span class="assert must">Implementations must let event objects accomplish an event phase by applying the following steps while there are pending event targets in the partial propagation path for this phase and the event object's propagation has not been stopped through <a href="#events-event-type-stopPropagation"><code>Event.stopPropagation()</code></a>.</span>
        </p>
        <p>
          <span class="assert must">First, the implementation must determine the <em>current target</em>. This must be the next pending event target in the partial propagation path, starting with the first. From the perspective of an event listener this must be the event target the listener has been registered on.</span>
        </p>
        <p>
          <span class="assert must">Next, the implementation must determine the current target's <em>candidate event listeners</em>. This must be the list of all event listeners that have been registered on the current target in their order of registration. [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>] defines the ordering of listeners registered through event handler attributes. Once determined, the candidate event listeners cannot be changed; adding or removing listeners does not affect the current target's candidate event listeners.</span>
        </p>
        <p>
          <span class="assert must">Finally, the implementation must process all candidate event listeners in order and trigger each listener if all the following conditions are met:</span>
        </p>
        <ul>
          <li>
            <span class="assert must">The event object's immediate propagation has not been stopped.</span>
          </li>
          <li>
            <span class="assert must">The listener has been registered for this event phase.</span>
          </li>
          <li>
            <span class="assert must">The listener has been registered for this <a class="def" href="#glossary-event-type">event type</a>.</span>
          </li>
        </ul>
        <p>
          <span class="assert must">An implementation must trigger a listener by invoking the <a href="#events-EventListener-handleEvent"><code class="method-name">EventListener.handleEvent()</code></a> method or an equivalent binding-specific mechanism.</span>
        </p>
        <p><span class="assert must">As the final step of the event dispatch, for reasons of backwards compatibility, the implementation must reset the event object's internal-propagation and default-action-prevention states.</span> This ensures that an event object may be properly dispatched multiple times while also allowing to prevent the event object's propagation or <a class="def" href="#glossary-default-action">default actions</a> prior to the event dispatch.</p>
        <p>In the production of the <a class="def" href="#glossary-propagation-path">propagation path</a>, if the <a class="def" href="#glossary-defaultView">defaultView</a> implements the <a href="#events-EventTarget">EventTarget</a> interface, the event propagates from <a class="def" href="#glossary-defaultView">defaultView</a> to the <code>document</code> object during the <a class="def" href="#glossary-capture-phase">capture phase</a>, and from the <code>document</code> object to the <a class="def" href="#glossary-defaultView">defaultView</a> during the <a class="def" href="#glossary-bubbling-phase">bubble phase</a>.</p>
        <p>The model defined above must be applied regardless of the specific event flow associated with an event target. Each event flow must define how the propagation path must be determined and which event phases are supported. The <em>DOM event flow</em> is an application of this model: the propagation path for a <code>Node</code> object must be determined by its <code>Node.parentNode</code> chain, and if applicable, the document's containing <a class="def" href="#glossary-defaultView">defaultView</a>; all events accomplish the capture and target phases; whether an event accomplishes the bubble phase must be defined individually for each <a class="def" href="#glossary-event-type">event type</a>. An alternate application of this model can be found in [<cite><a class="informative" href="#references-DOMLS">DOM3 Load and Save</a></cite>].</p>
        <p>Implementations of the DOM event model must be reentrant. Event listeners may perform actions that cause additional events to be dispatched. Such events are handled in a synchronous manner, the event propagation that causes the event listener to be triggered must resume only after the event dispatch of the new event is completed.</p>
      </div>
<!-- div2 Events-flow -->
      <div>
        <h3><a id="event-flow-default-cancel" href="#event-flow-default-cancel">3.2 Default actions and cancelable events</a></h3>

        <p>Event objects may have one or more <a class="def" href="#glossary-default-action">default actions</a> associated with them.  These are actions the implementation must perform in combination with the dispatch of the event object.  An example is the [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>] form element. When the user submits the form (e.g., by pressing on a submit button), the HTML event <code class="eventtype">submit</code> will be dispatched to the element and the <a class="def" href="#glossary-default-action">default action</a> for this <a class="def" href="#glossary-event-type">event type</a> will be generally to send a request to a Web server with the parameters from the form.</p>
        <p><a class="def" href="#glossary-default-action">Default actions</a> should be performed after the event dispatch has been completed, but in exceptional cases also immediately before the event is dispatched.</p>
        <!-- <span class="issue"><strong>Issue:</strong> insert example here: &lt;input type="checkbox"&gt;'s .checked handling comes to mind.
        .checked is changed just before 'click' event is dispatched, and if
        default action is prevented, .checked is set to its original value.</span> -->
        <p id="events-dt-cancelable-event">Some event objects are <em>cancelable</em>, meaning the <a class="def" href="#glossary-default-action">default action</a> can be prevented from occuring, or, if the <a class="def" href="#glossary-default-action">default action</a> is carried out before the dispatch, its effect may be reversed. Whether an event object is cancelable must be indicated by the <a href="#events-event-type-canCancel"><code>Event.cancelable</code></a> attribute. Event listeners can cancel <a class="def" href="#glossary-default-action">default actions</a> of cancelable event objects by invoking the <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> method, and determine whether an event has been canceled through the <a href="#events-event-type-defaultPrevented"><code>Event.defaultPrevented</code></a> attribute while the object is being dispatched, or from the return value of the <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> method for event objects dispatched by the <a class="def" href="#glossary-DOM-application">DOM application</a> itself.</p>
        <p>This specification does not offer features to programatically query if an event object has any <a class="def" href="#glossary-default-action">default action</a> associated with it, or to associate new <a class="def" href="#glossary-default-action">default actions</a> with an event object. Other specifications may define what default actions, if any, are associated with certain event objects. Further, implementations may associate <a class="def" href="#glossary-default-action">default actions</a> with events as necessary and appropriate for that implementation. As an example, one implementation might scroll a document view by a certain amount as <a class="def" href="#glossary-default-action">default action</a> of a mouse wheel event, while another implementation might instead zoom the document as its <a class="def" href="#glossary-default-action">default action</a> for a mouse wheel event.</p>
      </div>
<!-- div2 sync-async -->
      <div>
        <h3><a id="sync-async" href="#sync-async">3.3 Synchronous and asynchronous events</a></h3>

        <p>Events may be either synchronously  or asynchronously .</p>
        <p>Events which are synchronous (<em>"sync events"</em>) must be treated as if they are in a virtual queue in a first-in-first-out model, ordered by sequence of temporal occurrence, with respect to other events, to changes in the DOM, and to user interaction.  Each event in this virtual queue must be delayed until the previous event has completed its propagation behavior, or been canceled.  Some sync events are driven by a specific device or process, such as mouse button events; these events are governed by the <a class="def" href="#glossary-event-order">event order</a> algorithms defined for that set of events, and a user agent must dispatch these events in the defined order.</p>
        <p class="example" id="example-sync"><strong>Example:</strong> A user double-clicks a passage of text to select a word, then presses the <code class="value">'delete'</code> key to erase the word, triggering the following synchronous sequence of events: <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>, <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, <a class="eventtype" href="#event-type-click"><code>click</code></a>, <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>, <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, <a class="eventtype" href="#event-type-click"><code>click</code></a>, <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>, <a class="eventtype" href="#event-type-select"><code>select</code></a>, <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>, <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a>.  Each of these events are fired in the sequence initiated by the user's actions.</p>
        <p>Events which are asynchronous (<em>"async events"</em>) may be dispatched as the results of the action are completed, with no relation to other events, to other changes in the DOM, nor to user interaction.</p>
        <p class="example" id="example-async"><strong>Example:</strong> During loading of a document, an inline script element is parsed and executed. The <a class="eventtype" href="#event-type-load"><code>load</code></a> event is queued to be fired asynchronously at the script element. However, because it is an async event, its order with relation to other synchronous events fired during load (such as the DOMContentLoaded event from <cite><a class="informative" href="#references-HTML5">HTML5</a></cite>).          
        </p>
      </div>
      
<!-- div2 event-order-and-loops -->
      <div>
        <h4><a id="event-order-and-loops" href="#event-order-and-loops">3.3.1 Event order and event loops</a></h4>
        
        <p>Most events take place in a sequential context.  [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>] defines its event operations in terms of an event loop mechanism, in which events of all types are fed into different <em>task queues</em>.  This specification does not define events in terms of this event loop mechanism, but it is compatible with this mechanism.  Instead, this specification defines several operation-specific <a class="def" href="#glossary-event-order">event orders</a>.</p>
        <p>Using the terminology of HTML5, each independent device, such as a mouse or keyboard, should be treated as a <em>task source</em> which feeds into the appropriate <em>task queue</em>, in the order defined by the <a class="def" href="#glossary-event-order">event order</a> associated with that device; each operation, such as a focus change or composition input, also acts as a <em>task source</em> for the appropriate <em>task queue</em>.  The resolution of these event loops is handled in a manner conforming to the <a class="def" href="#glossary-host-language">host language</a>, such as HTML [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>].</p>
        <p class="warning" id="dropped-events"><strong>Warning!</strong> Certain events, such as “hotkeys” or controls keys pressed in a certain sequence, may be “swallowed” by the operating system or the application, interrupting the expected <a class="def" href="#glossary-event-order">event order</a>.  Content authors should make appropriate checks for such occurrences.</p>
        
      </div>

      
      
<!-- div2 trusted events -->
      <div>
        <h3><a id="trusted-events" href="#trusted-events">3.4 Trusted events</a></h3>

        <p>Events that are generated by the user agent, either as a result of user interaction, or as a direct result of changes to the DOM, are trusted by the user agent with privileges that are not afforded to events generated by script through the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("Event")</code></a> method, modified using the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method, or dispatched via the <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> method.  The <a href="#events-event-type-isTrusted"><code>isTrusted</code></a> attribute of trusted events has a value of <code>true</code>, while untrusted events have a <a href="#events-event-type-isTrusted"><code>isTrusted</code></a> attribute value of <code>false</code>.</p>
        <p>Most untrusted events should not trigger <a class="def" href="#glossary-default-action">default actions</a>, with the exception of <a class="eventtype" href="#event-type-click"><code>click</code></a> or <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> events which have been synthesized and are managed by the <a class="def" href="#glossary-user-agent">user agents</a> event as the <a class="def" href="#glossary-default-action">default action</a> of an <a class="def" href="#glossary-activation-trigger">activation trigger</a> (see <a href="#event-flow-activation">Activation triggers and behaviors</a> for more details); these <a class="def" href="#glossary-user-agent">user-agent</a>-managed synthesized events have an <a href="#events-event-type-isTrusted"><code>isTrusted</code></a> attribute value of <code>false</code>, but still initiate any <a class="def" href="#glossary-default-action">default actions</a>.  All other untrusted events must behave as if the <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> method had been called on that event.</p>
        <p>For security reasons, a <a class="def" href="#glossary-host-language">host language</a> should not define events which are not cancelable (see <a href="#event-flow-default-cancel">Default actions and cancelable events</a>), but also have <a class="def" href="#glossary-default-action">default actions</a>, since these <a class="def" href="#glossary-default-action">default actions</a> may be initiated by untrusted events.</p>
      </div>
<!-- div2 Events-flow-cancelation -->
      <div>
        <h3><a id="event-flow-activation" href="#event-flow-activation">3.5 Activation triggers and behavior</a></h3>

        <p>Certain <a class="def" href="#glossary-proximal-event-target">proximal event targets</a> (such as a link or button element) may have associated <a class="def" href="#glossary-activation-behavior">activation behavior</a> (such a following a link) that implementations perform in response to an <em><a class="def" href="#glossary-activation-trigger">activation trigger</a></em> (such as clicking a link).</p>
        <p>A <a class="def" href="#glossary-host-language">host language</a> should indicate which, if any, elements have activation behavior, describe appropriate <a class="def" href="#glossary-activation-trigger">activation triggers</a>, and define the result of that activation behavior.  An implementation which supports a <a class="def" href="#glossary-host-language">host language</a> should initiate these <a class="def" href="#glossary-activation-behavior">activation behavior</a> when the associated <a class="def" href="#glossary-activation-trigger">activation trigger</a> occurs.</p>
        <p class="example" id="example-activation"><strong>Example:</strong> Both HTML and SVG have an <code class="element">a</code> element which indicates a link.  Relevant <a class="def" href="#glossary-activation-trigger">activation triggers</a> for an <code class="element">a</code> element are a <a class="eventtype" href="#event-type-click"><code>click</code></a> event on the text or image  content of the <code class="element">a</code> element, or a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event with a <a href="#events-KeyboardEvent-key">key</a> attribute value of <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> key when the <code class="element">a</code> element has focus.  The activation behavior for an <code class="element">a</code> element is normally to change the content of the window to the content of the new document, in the case of external links, or to reposition the current document relative to the new anchor, in the case of internal links.</p>
        <p>An <a class="def" href="#glossary-activation-trigger">activation trigger</a> is a user action or an event which indicates to the implementation that an activation behavior should be initiated.  User-initiated <a class="def" href="#glossary-activation-trigger">activation triggers</a> include clicking a mouse button on an activatable element, pressing the <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> key when an activatable element has focus, or pressing a key that is somehow linked to an activatable element (a “hotkey” or “access key”) even when that element does not have focus.  Event-based <a class="def" href="#glossary-activation-trigger">activation triggers</a> may include timer-based events that activate an element at a certain clock time or after a certain time period has elapsed, progress events after a certain action has been completed, or many other condition-based or state-based events.</p>
        <p>In some cases, a <a class="def" href="#glossary-host-language">host language</a> may define attributes or even attribute values which add to or change the native <a class="def" href="#glossary-activation-trigger">activation trigger</a> or <a class="def" href="#glossary-activation-behavior">activation behavior</a> of an element.  For example, ARIA [<cite><a class="informative" href="#ref-ARIA">ARIA</a></cite>] defines values for the <code class="attr">role</code> attribute that add semantics to the element to which it is applied, for purposes of enhanced accessibility.  In such cases, if the <a class="def" href="#glossary-host-language">host language</a> does not explicitly define the <a class="def" href="#glossary-activation-trigger">activation trigger</a> or <a class="def" href="#glossary-activation-behavior">activation behavior</a>, the content author must provide the mechanics of the <a class="def" href="#glossary-activation-trigger">activation trigger</a> (via an event listener) or <a class="def" href="#glossary-activation-behavior">activation behavior</a> (such as calling an ECMAScript function) for that element when applying that attribute or attribute value.</p>
        
        <h4><a id="click-synthesis" href="#click-synthesis">3.5.1 Activation event synthesis</a></h4>
        
        <p>If the instance of the <a class="def" href="#glossary-activation-trigger">activation trigger</a> is not an event of <a class="def" href="#glossary-event-type">event type</a> <a class="eventtype" href="#event-type-click"><code>click</code></a> (that is, when it does not result from a user's activation of a button or link using a mouse or equivalent pointing device), the implementation must synthesize and dispatch an event of <a class="def" href="#glossary-event-type">event type</a> <a class="eventtype" href="#event-type-click"><code>click</code></a> as one of the <a class="def" href="#glossary-default-action">default actions</a> of that <a class="def" href="#glossary-activation-trigger">activation trigger</a>; the value of the <code class="attribute-name"><a href="#events-event-type-target">Event.target</a></code> must be set to the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> (normally, the currently focused element), and the event must simulate a <em>left click</em> (i.e., the <a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> attribute value must be <code>0</code>, and the <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attribute value must be <code>1</code>).  Other context information of such a simulated <a class="eventtype" href="#event-type-click"><code>click</code></a> event is implementation dependent, but for historical purposes, the interface for the <a class="eventtype" href="#event-type-click"><code>click</code></a> event must be the <a href="#events-MouseEvent"><code>MouseEvent interface</code></a>, regardless of the actual device used to activate the element.  Preventing the <a class="def" href="#glossary-default-action">default action</a> of the <a class="def" href="#glossary-activation-trigger">activation trigger</a>, such as with the <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a>, must stop the initiation of the <a class="def" href="#glossary-activation-behavior">activation behavior</a>.</p>
        <p class="example" id="example-activation-click"><strong>Example:</strong>  When a user activates a hyperlink using a keyboard, such as by focusing the hyperlink element and pressing the <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> or <a href="#key-Spacebar"><code class="value keyname">'Space'</code></a> key, a <a class="eventtype" href="#event-type-click"><code>click</code></a> event would be dispatched as the <a class="def" href="#glossary-default-action">default action</a> of the respective <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event.</p>
        <p>Implementations must dispatch the synthesized <a class="eventtype" href="#event-type-click"><code>click</code></a> event as described above even if they do not normally dispatch such an event (e.g., when activation is requested by a voice command, since this specification does not address <a class="def" href="#glossary-event-type">event types</a> for voice input).</p>
        <p class="note" id="application-dependent-activation"><strong>Note:</strong> The activation of an event target is device dependent, but is also application dependent, e.g., a link in a document can be activated using a mouse click or a mouse double click.</p>
        <p>Implementations which support the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> should also dispatch a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event as a <a class="def" href="#glossary-default-action">default action</a> of a <a class="eventtype" href="#event-type-click"><code>click</code></a> event which is associated with an <a class="def" href="#glossary-activation-trigger">activation trigger</a>.  However, such implementations should only initiate the associated <a class="def" href="#glossary-activation-behavior">activation behavior</a> once for any given occurrence of an <a class="def" href="#glossary-activation-trigger">activation trigger</a>.</p>
        <p class="example" id="example-activation-DOMActivate"><strong>Example:</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is required to be supported for XForms [<cite><a class="informative" href="#ref-xforms">XFORMS</a></cite>], which is intended for implementation within a <a class="def" href="#glossary-host-language">host language</a>.  In a scenario where a plugin or script-based implementation of XForms is intended for installation in a native implementation of this specification which does not support the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a>, the XForms <a class="def" href="#glossary-user-agent">user agent</a> has to synthesize and dispatch its own <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> events based on the appropriate <a class="def" href="#glossary-activation-trigger">activation triggers</a>.  Thus, when a <a class="eventtype" href="#event-type-click"><code>click</code></a> event is dispatched by the DOM Level 3 Events <a class="def" href="#glossary-user-agent">user agent</a>, the XForms <a class="def" href="#glossary-user-agent">user agent</a> has to determine whether to synthesize a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event with the same relevant properties as a <a class="def" href="#glossary-default-action">default action</a> of that <a class="eventtype" href="#event-type-click"><code>click</code></a> event; appropriate cues might be whether the <a class="eventtype" href="#event-type-click"><code>click</code></a> event is <a href="#trusted-events">trusted</a>, or whether its <a class="def" href="#glossary-proximal-event-target">proximal event target</a> has a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event listener registered.</p>
        <p class="note" id="authors-activation"><strong>Note:</strong>  Content authors should not rely upon the interoperable support of <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> in many <a class="def" href="#glossary-user-agent">user agents</a>.  Thus, content authors may use the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> whenever they wish to make or react to an <a class="def" href="#glossary-activation-trigger">activation trigger</a>, but should use the <a class="eventtype" href="#event-type-click"><code>click</code></a> <a class="def" href="#glossary-event-type">event type</a> for more accessible behavior instead, due to wider implementation.</p>

        <p class="warning" id="activation-deprecated"><strong>Warning!</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is deprecated in this specification.</p>

        <h4 class="needswork">
          <a id="events-activation-event-order" href="#events-activation-event-order">3.5.1 Activation Event Order</a>
        </h4>
        <p>Activation triggers and behavior can be defined in part by the events which are dispatched in a set order relative to one another.  The following is the typical sequence of events for an element activated by a pointing device (with only pertinent events listed):</p>
        <ol>
          <li>
            <a class="eventtype" href="#event-type-click"><code>click</code></a>
          </li>
          <li><a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> (<a class="def" href="#glossary-default-action">default action</a>, if supported by the <a class="def" href="#glossary-user-agent">user agent</a>; synthesized; <code>trusted="false"</code>)</li>
          <li>
            <em>All other <a class="def" href="#glossary-default-action">default actions</a>, including the <a class="def" href="#glossary-activation-behavior">activation behavior</a></em>
          </li>
        </ol>
        <p>The following is the typical sequence of events when a focused element is activated by a key event (with only pertinent events listed):</p>
        <ol>
          <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> (must be a key which can activate the element, such as the <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> or <a href="#key-Spacebar"><code class="value keyname">'Space'</code></a> key, or the element is not activated)</li>
          <li><a class="eventtype" href="#event-type-click"><code>click</code></a> (<a class="def" href="#glossary-default-action">default action</a>; synthesized; <code>trusted="false"</code>)</li>
          <li><a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> (<a class="def" href="#glossary-default-action">default action</a>, if supported by the <a class="def" href="#glossary-user-agent">user agent</a>; synthesized; <code>trusted="false"</code>)</li>
          <li>
            <em>All other <a class="def" href="#glossary-default-action">default actions</a>, including the <a class="def" href="#glossary-activation-behavior">activation behavior</a></em>
          </li>
        </ol>
<!--
       <p>Implementations could react to an event before dispatching it
       	  and do changes on the display and the DOM tree. In such case,
       	  if a DOM attribute is changed before the event is fired,
       	  cancelling the device event type will also reverse the
       	  change. A good example is the attribute
       	  <code>HTMLInputElement.checked</code>: As described in 
       	  [<a class="normative" href="references.html#DOM2HTML">DOM Level 2 HTML</a>], 
       	  the value of this property may be changed before the dispatch of the event;
       	  the user clicks on the radio button, the radio button is being
       	  checked (or unchecked) on the display, the attribute
       	  <code>HTMLInputElement.checked</code> is changed as well, and
       	  then the device event type <code>{"http://www.w3.org/2001/xml-events",
       	  "click"}</code> is being dispatched. If the default action of
       	  the device event type is prevented, or if the default action
       	  attached to the <code>{"http://www.w3.org/2001/xml-events", "DOMActivate"}</code>
       	  event type is prevented, the property <code>HTMLInputElement.checked</code> will need to be changed
       	  back to its original value.
       	</p>
       -->
      </div>
<!-- div2 Events-flow-activation -->
<!-- div2 Event-interfaces -->
      <div>
        <h2><a id="event-interfaces" href="#event-interfaces">4. Basic Event Interfaces</a></h2>


        <p>The interfaces described in this section are fundamental to DOM Level 3 Events and must always be supported by the implementation. Together they define the feature Events 3.0.</p>
        <p>The event types defined in this specification derive from these basic interfaces, and must inherit all of the attributes, methods, and constants of the interfaces they derive from.  Event types defined in other specifications may similarly inherit from these basic interfaces or other interfaces defined in this specification, or may define their own interfaces.  The following chart describes the inheritance structure of interfaces defined in this specification.</p>
        <div class="figure" style="text-align: center">
          <object type="image/svg+xml" data="images/event-inheritance.svg" width="960" height="230">
            <img src="images/event-inheritance.png" alt="graphical representation of the DOM3 Events interface inheritance" />
          </object>
          <p style="text-align:left">
            <em>Figure 2: graphical representation of the DOM3 Events interface inheritance</em>
          </p>
        </div>
        <h3><a id="interface-Event" href="#interface-Event">4.1 Interface Event</a></h3>


        <dl>
          <dt><strong>Interface <em><a id="events-Event">Event</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
          <dd>
            <p>The <code>Event</code> interface is used to provide contextual information about an event to the listener processing the event. An object which implements the <code>Event</code> interface must be passed as the parameter to an <a href="#events-EventListener"><code>EventListener</code></a>. The object passed to the event listener may also implement derived interfaces that provide access to information directly relating to the type of event they represent.</p>
            <p>To create an instance of the <code>Event</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("Event")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-Event"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Event">Event</a> {

  // PhaseType
  const unsigned short               <a href="#events-CAPTURING_PHASE">CAPTURING_PHASE</a>      = 1;
  const unsigned short               <a href="#events-AT_TARGET">AT_TARGET</a>            = 2;
  const unsigned short               <a href="#events-BUBBLING_PHASE">BUBBLING_PHASE</a>       = 3;

  readonly attribute DOMString       <a href="#events-event-type-type">type</a>;
  readonly attribute <a href="#events-EventTarget">EventTarget</a>     <a href="#events-event-type-target">target</a>;
  readonly attribute <a href="#events-EventTarget">EventTarget</a>     <a href="#events-event-type-currentTarget">currentTarget</a>;
  readonly attribute unsigned short  <a href="#events-event-type-eventPhase">eventPhase</a>;
  readonly attribute boolean         <a href="#events-event-type-canBubble">bubbles</a>;
  readonly attribute boolean         <a href="#events-event-type-canCancel">cancelable</a>;
  readonly attribute DOMTimeStamp    <a href="#events-event-type-timeStamp">timeStamp</a>;
  void                               <a href="#events-event-type-stopPropagation">stopPropagation</a>();
  void                               <a href="#events-event-type-preventDefault">preventDefault</a>();
  void                               <a href="#events-event-type-initEvent">initEvent</a>(in DOMString eventTypeArg, 
                                               in boolean canBubbleArg, 
                                               in boolean cancelableArg);
  // Introduced in DOM Level 3:
  void                               <a href="#events-event-type-stopImmediatePropagation">stopImmediatePropagation</a>();
  readonly attribute boolean         <a href="#events-event-type-defaultPrevented">defaultPrevented</a>;
  readonly attribute boolean         <a href="#events-event-type-isTrusted">isTrusted</a>;
};
                </code></pre>
              </dd>

              <dt>
                <strong>Definition group <em><a id="events-event-type-eventPhaseType">PhaseType</a></em></strong>
              </dt>
              <dd>
                <p>An integer indicating which phase of the event flow is being processed as defined in <a href="#event-flow">Event dispatch and DOM event flow</a>.</p>
                <dl>
                  <dt><strong>Defined Constants</strong></dt>
                  <dd>
                    <dl>
                      <dt><a id="events-AT_TARGET"><code class="constant-name">AT_TARGET</code></a></dt>
                      <dd>The current event is in the <a class="def" href="#glossary-target-phase">target phase</a>, i.e., it is being evaluated at the <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.</dd>

                      <dt><a id="events-BUBBLING_PHASE"><code class="constant-name">BUBBLING_PHASE</code></a></dt>
                      <dd>The current event phase is the <a class="def" href="#glossary-bubbling-phase">bubbling phase</a>.</dd>

                      <dt><a id="events-CAPTURING_PHASE"><code class="constant-name">CAPTURING_PHASE</code></a></dt>
                      <dd>The current event phase is the <a class="def" href="#glossary-capture-phase">capture phase</a>.</dd>

                    </dl>
                  </dd>
                </dl>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-event-type-canBubble">bubbles</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><p>Used to indicate whether or not an event is a bubbling event. If the event can bubble the value must be <code>true</code>, otherwise the value must be <code>false</code>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-canCancel">cancelable</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><p>Used to indicate whether or not an event can have its <a class="def" href="#glossary-default-action">default action</a> prevented (see also <a href="#event-flow-default-cancel">Default actions and cancelable events</a>). If the <a class="def" href="#glossary-default-action">default action</a> can be prevented the value must be <code>true</code>, otherwise the value must be <code>false</code>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-currentTarget">currentTarget</a></code> of type <a href="#events-EventTarget"><code>EventTarget</code></a>, readonly</dt>
                  <dd><p>Used to indicate the <a href="#events-EventTarget"><code>EventTarget</code></a> whose <a href="#events-EventListener"><code>EventListeners</code></a> are currently being processed. This is particularly useful during the capture and bubbling phases. When used with the <a href="#event-flow">Event dispatch and DOM event flow</a>, this attribute contains the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> or a target ancestor.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-defaultPrevented">defaultPrevented</a></code> of type <code>boolean</code>, readonly, introduced in <strong class="version">DOM Level 3</strong></dt>
                  <dd><p>Used to indicate whether <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> has been called for this event.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-isTrusted">isTrusted</a></code> of type <code>boolean</code>, readonly, introduced in <strong class="version">DOM Level 3</strong></dt>
                  <dd><p>Used to indicate whether this event was generated by the <a class="def" href="#glossary-user-agent">user agent</a> (trusted) or by script (untrusted).  See <a href="#trusted-events">trusted events</a> for more details.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-eventPhase">eventPhase</a></code> of type <code>unsigned short</code>, readonly</dt>
                  <dd><p>Used to indicate which phase of event flow is currently being accomplished.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-target">target</a></code> of type <a href="#events-EventTarget"><code>EventTarget</code></a>, readonly</dt>
                  <dd><p>Used to indicate the <a class="def" href="#glossary-event-target">event target</a>. This attribute contains the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> when used with the <a href="#event-flow">Event dispatch and DOM event flow</a>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-timeStamp">timeStamp</a></code> of type <code>DOMTimeStamp</code>, readonly</dt>
                  <dd><p>Used to specify the time at which the event was created in milliseconds relative to 1970-01-01T00:00:00Z.</p></dd>

                  <dt><code class="attribute-name"><a id="events-event-type-type">type</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p>The name of the event type. The name must be a <code>DOMString</code>.  <a href="#conf-specs">Specifications that define events</a>, <a href="#conf-authors">content authors</a>, and <a href="#conf-author-tools">authoring tools</a> must use case-sensitive event type names.</p></dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initEvent">initEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of an <code>Event</code> created through the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent</code></a> method. This method may only be called before the <code>Event</code> has been dispatched via the <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> method. If the method is called several times before invoking <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent</code></a>, only the final invocation takes precedence. This method has no effect if called after the event has been dispatched. If called from a subclass of the <code>Event</code> interface only the values specified in this method are modified, all other attributes are left unchanged.</p>
                      <p>This method sets the <a href="#events-event-type-type"><code>Event.type</code></a> attribute to <code>eventTypeArg</code>.</p>
                      <p class="warning" id="warning-initEvent-untrusted"><strong>Warning!</strong>  For security reasons, events modified using <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> must have a <code class="attribute-name"><a href="#events-event-type-isTrusted">isTrusted</a></code> attribute value of <code>false</code>.  See <a href="#trusted-events">trusted events</a> for more details.</p>

                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">eventTypeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-event-type-type"><code>Event.type</code></a>, the name of the event type.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Specifies <a href="#events-event-type-canBubble"><code>Event.bubbles</code></a>. This parameter overrides the intrinsic bubbling behavior of the event.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Specifies <a href="#events-event-type-canCancel"><code>Event.cancelable</code></a>. This parameter overrides the intrinsic cancelable behavior of the event.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
                  </dd>

                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-preventDefault">preventDefault</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">When this method is invoked, the event must be canceled, meaning any <a class="def" href="#glossary-default-action">default actions</a> normally taken by the implementation as a result of the event must not occur (see also <a href="#event-flow-default-cancel">Default actions and cancelable events</a>). Default actions which occur prior to the event's dispatch (see <a href="#event-flow-default-cancel">Default actions and cancelable events</a>) are reverted. Calling this method for a non-cancelable event must have no effect.  If an event has more than one <a class="def" href="#glossary-default-action">default action</a>, each cancelable <a class="def" href="#glossary-default-action">default action</a> must be canceled.
<p class="note" id="note-preventDefault-prop"><strong>Note:</strong> This method does not stop the event propagation; use <a href="#events-event-type-stopPropagation"><code>Event.stopPropagation()</code></a> or <a href="#events-event-type-stopImmediatePropagation"><code>Event.stopImmediatePropagation()</code></a> for that effect.</p>
                      <div><strong>No Parameters</strong></div>

                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
                  </dd>

                  <dt><code class="method-name"><a id="events-event-type-stopImmediatePropagation">stopImmediatePropagation</a></code> introduced in <strong class="since">DOM Level 3</strong></dt>
                  <dd>
                    <div class="method">
                      Prevents other event listeners from being triggered and, unlike <a href="#events-event-type-stopPropagation"><code>Event.stopPropagation()</code></a> its effect must be immediate . Once it has been called, further calls to this method have no additional effect.
                      <p class="note" id="note-stopImmediatePropagation-default"><strong>Note:</strong> This method does not prevent the <a class="def" href="#glossary-default-action">default action</a> from being invoked; use <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> for that effect.</p>
                      <div><strong>No Parameters</strong></div>

                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
                  </dd>

                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-stopPropagation">stopPropagation</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      Prevents other event listeners from being triggered but its effect must be deferred until all event listeners attached on the <a href="#events-event-type-currentTarget"><code>Event.currentTarget</code></a> have been triggered. Once it has been called, further calls to this method have no additional effect.
                      <p class="note" id="note-stopPropagation-default"><strong>Note:</strong> This method does not prevent the <a class="def" href="#glossary-default-action">default action</a> from being invoked; use <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> for that effect.</p>
                      <div><strong>No Parameters</strong></div>

                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <h3><a id="interface-CustomEvent" href="#interface-CustomEvent">4.2 Interface CustomEvent</a></h3>

        <dl>
          <dt><strong>Interface <em><a id="events-CustomEvent">CustomEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
          <dd>
            <p>The <a href="#events-CustomEvent"><code>CustomEvent</code></a> interface is the recommended interface for application-specific event types. Unlike the <a href="#events-Event"><code>Event</code></a> interface, it allows applications to provide contextual information about the event type. Application-specific event types should use a prefix string on the event type name to avoid clashes with future general-purpose event types.</p>
            <p>To create an instance of the <code>CustomEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("CustomEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                
                <pre class="idl" id="idl-interface-CustomEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-CustomEvent">CustomEvent</a> : <a href="#events-Event">Event</a> {
  readonly attribute any             <a href="#events-CustomEvent-detail">detail</a>;
  void                               <a href="#events-event-type-initCustomEvent">initCustomEvent</a>(in DOMString typeArg, 
                                                     in boolean   canBubbleArg, 
                                                     in boolean   cancelableArg, 
                                                     in any       detailArg);
};
                </code></pre>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-CustomEvent-detail">detail</a></code> of type <code>any</code>, readonly</dt>
                  <dd><p>Specifies some detail information about the <a href="#events-Event"><code>Event</code></a>.</p></dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initCustomEvent">initCustomEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">Initializes attributes of a <code>CustomEvent</code> object. This method has the same behavior as <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a>.
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">detailArg</code> of type <code>any</code></dt>
                            <dd><p>Specifies <a href="#events-CustomEvent-detail"><code>CustomEvent.detail</code></a>. This value may be <code>null</code>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        
        
        <h3><a id="interface-EventTarget" href="#interface-EventTarget">4.3 Interface EventTarget</a></h3>

        <dl>
          <dt><strong>Interface <em><a id="events-EventTarget">EventTarget</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
          <dd>
            <p>The <code>EventTarget</code> interface must be implemented by all the objects which could be <a class="def" href="#glossary-event-target">event targets</a> in an implementation which supports an event flow. The interface allows registration and removal of event listeners, and dispatch of events to an event target.</p>
            
            <p class="note" id="EventTarget-trusted"><strong>Note:</strong>  Though an event listener can be registered for any <a class="def" href="#glossary-event-target">event target</a> node, the user agent only dispatches UA-generated (trusted) events on node types that are defined as proximal event target types for that specific event type (see the <a href="#event-types-list">List of DOM3 Event Types</a>); for example, a <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a> event type registered on a text node will never be fired by the user agent, though a content author could dispatch an event of that type on the text node via script.</p>
            
            <p>When used with the DOM event flow, this interface must be implemented by all <a class="def" href="#glossary-proximal-event-target">proximal event targets</a> and target ancestors, i.e., all DOM <code>Nodes</code> of the tree support this interface when the implementation conforms to DOM Level 3 Events and, therefore, this interface can be obtained by using binding-specific casting methods on an instance of the <code>Node</code> interface.</p>
            <p>Invoking <code>addEventListener</code> repeatedly on the same <code>EventTarget</code> with the same values for the parameters <code>type</code>, <code>listener</code>, and <code>useCapture</code> has no effect. Doing so does not cause the <a href="#events-EventListener"><code>EventListener</code></a> to be called more than once and does not cause a change in the triggering order.</p>

            <p class="note" id="EventTarget-onfoo"><strong>Note:</strong>  In addition to the <a href="#events-EventTarget-addEventListener">EventTarget.addEventListener</a> method, some <a class="def" href="#glossary-host-language">host languages</a> may allow a content author to register event listeners by the use of attributes, e.g., <em><code>onclick="handleClick()"</code></em>.  Because the details of this are often language-specific, this type of event listener registration is not defined in this specification, but in general, any event type may be used as an attribute in this way by adding the prefix <em><code>on-</code></em> to the event type name, and events so dispatched should behave consistently with the event registration and propagation defined in this specification, with the same interfaces, properties, and methods.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-"><code>
// Introduced in DOM Level 2:
interface <a href="#events-EventTarget">EventTarget</a> {
  // Modified in DOM Level 3:
  void               <a href="#events-EventTarget-addEventListener">addEventListener</a>(in DOMString type, 
                                      in <a href="#events-EventListener">EventListener</a> listener, 
                                      in boolean useCapture);
  void               <a href="#events-EventTarget-removeEventListener">removeEventListener</a>(in DOMString type, 
                                         in <a href="#events-EventListener">EventListener</a> listener, 
                                         in boolean useCapture);
  boolean            <a href="#events-EventTarget-dispatchEvent">dispatchEvent</a>(in <a href="#events-Event">Event</a> evt)
                                   raises(<a href="#events-EventException">EventException</a>, 
                                   DOMException);
                                   
};
                </code></pre>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-EventTarget-addEventListener">addEventListener</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">Registers an event listener, depending on the <code>useCapture</code> parameter, on the capture phase of the DOM event flow or its target and bubbling phases.
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">type</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies the <a href="#events-event-type-type"><code>Event.type</code></a> associated with the event for which the user is registering.</p></dd>
                            
                            <dt><code class="parameter-name">listener</code> of type <a href="#events-EventListener"><code>EventListener</code></a></dt>
                            <dd>
                              <p>The <code>listener</code> parameter must be an object which implements the <a href="#events-EventListener"><code>EventListener</code></a> interface, such as a reference to a .</p>
                              
                              <p>The <code>listener</code> parameter must be either an object that implements the <a href="#events-EventListener"><code>EventListener</code></a> interface, or a function.  If <code>listener</code> is a function then it must be used as the callback for the event; otherwise, if <code>listener</code> implements <a href="#events-EventTarget"><code>EventTarget</code></a>, then its <a href="#events-EventListener-handleEvent">handleEvent</a> method must be used as the callback.</p>
                              <p>The <code>listener</code> parameter takes an object defined by the author which implements the <a href="#events-EventListener"><code>EventListener</code></a> interface and contains the method to be called when the event occurs.</p>
                              <p class="note" id="addEventListener_function"><strong>Note:</strong>  The <code>listener</code> may be a reference to a function object or an inline function object literal.</p>
                            </dd>
                            
                            <dt><a id="addEventListener_useCapture"><code class="parameter-name">useCapture</code></a> of type <code>boolean</code></dt>
                            <dd>
                              <p>If true, <code>useCapture</code> indicates that the user wishes to add the event listener for the <a class="def" href="#glossary-capture-phase">capture</a> and <a class="def" href="#glossary-target-phase">target</a> phases only, i.e., this event listener will not be triggered during the <a class="def" href="#glossary-bubbling-phase">bubbling</a> phase.  If <code>false</code>, the event listener must only be triggered during the <a class="def" href="#glossary-target-phase">target</a> and <a class="def" href="#glossary-bubbling-phase">bubbling</a> phases.</p>
                              <p>This parameter may be optional, on an implementation-specific basis.  If not provided, the <a href="#events-EventTarget-addEventListener">EventTarget.addEventListener</a> method must behave as if <a href="#addEventListener_useCapture"><code class="parameter-name">useCapture</code></a> were specified to be <code>false</code>.  See the non-normative <a href="#webidl-events-EventTarget">Interface EventTarget</a> WebIDL definition for a formal description.</p>
                              <p class="note" id="addEventListener_useCapture-java"><strong>Note:</strong>  For programming languages which do not allow optional method parameters, such as Java, the implementation may provide two <a href="#events-EventTarget-addEventListener">EventTarget.addEventListener</a> methods, one with 2 parameters, and one with 3 parameters.</p>
                              <p class="note" id="addEventListener_useCapture-author"><strong>Authoring Note:</strong>  The <a href="#events-EventTarget-addEventListener"><code class="parameter-name">useCapture</code></a> parameter was required in DOM2 Events [<a href="#references-DOM2Events">DOM2 Events</a>], and omitting this parameter may cause an error in older implementations.</p>
                            </dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>

                  <dt>
                    <code class="method-name">
                      <a id="events-EventTarget-removeEventListener">removeEventListener</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">Removes an event listener. Calling <code>removeEventListener</code> with arguments which do not identify any currently registered <a href="#events-EventListener"><code>EventListener</code></a> on the <code>EventTarget</code> has no effect. 
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">type</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies the <a href="#events-event-type-type"><code>Event.type</code></a> for which the user registered the event listener.</p></dd>
                            <dt><code class="parameter-name">listener</code> of type <a href="#events-EventListener"><code>EventListener</code></a></dt>
                            <dd><p>The <a href="#events-EventListener"><code>EventListener</code></a> to be removed.</p></dd>
                            <dt><code id="removeEventListener_useCapture" class="parameter-name">useCapture</code> of type <code>boolean</code></dt>
                            <dd>
                              <p>Specifies whether the <a href="#events-EventListener"><code>EventListener</code></a> being removed was registered for the capture phase or not. If a listener was registered twice, once for the capture and target phases and once for the target and bubbling phases, each must be removed separately. Removal of an event listener registered for the capture and target phases does not affect the same event listener registered for the target and bubbling phases, and vice versa.</p>
                              <p>This parameter may be optional, on an implementation-specific basis.  If not provided, the <a href="#events-EventTarget-removeEventListener">EventTarget.removeEventListener</a> method must behave as if <a href="#removeEventListener_useCapture"><code class="parameter-name">useCapture</code></a> were specified to be <code>false</code>, including the removal of event listeners which had an <a href="#events-EventTarget-addEventListener">EventTarget.addEventListener</a> <a href="#events-EventTarget-addEventListener"><code class="parameter-name">useCapture</code></a> value of <code>false</code>.  See the non-normative <a href="#webidl-events-EventTarget">Interface EventTarget</a> WebIDL definition for a formal description</p>
                              <p class="note" id="removeEventListener_useCapture-java"><strong>Note:</strong>  For programming languages which do not allow optional method parameters, such as Java, the implementation may provide two <a href="#events-EventTarget-removeEventListener">EventTarget.removeEventListener</a> methods, one with 2 parameters, and one with 3 parameters.</p>
                              <p class="note" id="removeEventListener_useCapture-author"><strong>Authoring Note:</strong>  The <a href="#removeEventListener_useCapture"><code class="parameter-name">useCapture</code></a> parameter was required in DOM2 Events [<a href="#references-DOM2Events">DOM2 Events</a>], and omitting this parameter may cause an error in older implementations.</p>
                            </dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>

                  <dt><code class="method-name"><a id="events-EventTarget-dispatchEvent">dispatchEvent</a></code> modified in <strong class="version">DOM Level 3</strong></dt>
                  <dd>
                    <div class="method">Dispatches an event into the implementation's event model. The <a class="def" href="#glossary-event-target">event target</a> of the event must be the <code>EventTarget</code> object on which <code>dispatchEvent</code> is called.
                      <p class="warning" id="warning-dispatchEvent-untrusted"><strong>Warning!</strong>  For security reasons, events dispatched using <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> must have a <code class="attribute-name"><a href="#events-event-type-isTrusted">isTrusted</a></code> attribute value of <code>false</code>.  See <a href="#trusted-events">trusted events</a> for more details.</p>

                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">evt</code> of type <a href="#events-Event"><code>Event</code></a></dt>
                            <dd><p>The event to be dispatched.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div class="return"><strong>Return Value</strong><div class="returntable"><table summary="Layout table: the first cell contains the type of the return value, the second contains a short description" border="0"><tr><td><p><code>boolean</code></p></td><td><p>Indicates whether any of the listeners which handled the event called <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a>. If <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> was called the returned value must be <code>false</code>, else it must be <code>true</code>.</p></td></tr></table></div></div>
                      <!-- return -->
                      <div class="exceptions"><strong>Exceptions</strong><div class="exceptiontable"><table summary="Layout table: the first cell contains the type of the exception, the second contains the specific error code and a short description" border="0"><tr><td><p><a href="#events-EventException"><code>EventException</code></a></p></td><td><p>UNSPECIFIED_EVENT_TYPE_ERR: Raised if the <a href="#events-event-type-type"><code>Event.type</code></a> was not specified by initializing the event before <code>dispatchEvent</code> was called. </p><p>DISPATCH_REQUEST_ERR: Raised if the <a href="#events-Event"><code>Event</code></a> object is already being dispatched.</p></td></tr><tr><td><p><code>DOMException</code></p></td><td><p>NOT_SUPPORTED_ERR: Raised if the <a href="#events-Event"><code>Event</code></a> object has not been created using <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent()</code></a>.</p><p>INVALID_CHARACTER_ERR: Raised if <a href="#events-event-type-type"><code>Event.type</code></a> is not a <code>DOMString</code> as conforming to the restrictions in <a href="#events-event-type-type"><code>Event.type</code></a>.</p></td></tr></table></div></div>
                      <!-- exceptions --></div>
<!-- method -->
                  </dd>

                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        
        
        <h3><a id="interface-EventListener" href="#interface-EventListener">4.4 Interface EventListener</a></h3>

        <dl>
          <dt><strong>Interface <em><a id="events-EventListener">EventListener</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
          <dd>
            <p>The <code>EventListener</code> interface is the primary way to handle events.  Content authors must define on object, such as a function, which the <code>EventListener</code> interface and register their event listener on an <a href="#events-EventTarget"><code>EventTarget</code></a>. The content authors should also remove their <code>EventListener</code> from its <a href="#events-EventTarget"><code>EventTarget</code></a> after they have completed using the listener.</p>
            <p>
              <span class="assert must">Copying a <code>Node</code>, with methods such as <code>Node.cloneNode</code> or <code>Range.cloneContents</code>, must not copy the event listeners attached to it.</span>
              <span class="assert must">Event listeners must be attached to the newly created <code>Node</code> afterwards, if so desired.</span>
            </p>
            <p>
              <span class="assert mustnot">Moving a <code>Node</code>, with methods <code>Document.adoptNode</code>, <code>Node.appendChild</code>, or <code>Range.extractContents</code>, must not affect the event listeners attached to it.</span>
            </p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-EventListener"><code>
// Introduced in DOM Level 2:
interface <a href="#events-EventListener">EventListener</a> {
  void               <a href="#events-EventListener-handleEvent">handleEvent</a>(in <a href="#events-Event">Event</a> evt);
};
                </code></pre>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-EventListener-handleEvent">handleEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>This method must be called whenever an event occurs of the event type for which the <code>EventListener</code> interface was registered.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">evt</code> of type <a href="#events-Event"><code>Event</code></a></dt>
                            <dd><p>The <a href="#events-Event"><code>Event</code></a> contains contextual information about the <a class="def" href="#glossary-event">event</a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>

          <dt><strong>Exception <em><a id="events-EventException">EventException</a></em></strong> introduced in <strong class="version">DOM Level 2</strong></dt>
          <dd>
            <p>Event operations may throw an <a href="#events-EventException"><code>EventException</code></a> as specified in their method descriptions.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-EventException"><code>
// Introduced in DOM Level 2:
exception <a href="#events-EventException">EventException</a> {
  // EventExceptionCode
  const unsigned short      <a href="#events-UNSPECIFIED_EVENT_TYPE_ERR">UNSPECIFIED_EVENT_TYPE_ERR</a>     = 0;
  // Introduced in DOM Level 3:
  const unsigned short      <a href="#events-DISPATCH_REQUEST_ERR">DISPATCH_REQUEST_ERR</a>           = 1;

  // Introduced in DOM Level 2:
  unsigned short            code;
};
                </code></pre>
              </dd>

              <dt>
                <strong>Definition group <em><a id="events-EventException-EventExceptionCode">EventExceptionCode</a></em></strong>
              </dt>
              <dd>
                <p>An integer indicating the type of error generated.</p>
                <dl>
                  <dt><strong>Defined Constants</strong></dt>
                  <dd>
                    <dl>
                      <dt><a id="events-DISPATCH_REQUEST_ERR"><code class="constant-name">DISPATCH_REQUEST_ERR</code></a>, introduced in <strong class="version">DOM Level 3</strong>.</dt>
                      <dd>If the <a href="#events-Event"><code>Event</code></a> object is already dispatched in the tree.</dd>

                      <dt><a id="events-UNSPECIFIED_EVENT_TYPE_ERR"><code class="constant-name">UNSPECIFIED_EVENT_TYPE_ERR</code></a></dt>
                      <dd>If the <a href="#events-event-type-type"><code>Event.type</code></a> was not specified by initializing the event before the method was called. Specification of the <a href="#events-event-type-type"><code>Event.type</code></a> as <code>null</code> or an <a class="def" href="#glossary-empty-string">empty string</a> must also trigger this exception.</dd>

                    </dl>
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        
        
        <div>
          <h3><a id="interface-DocumentEvent" href="#interface-DocumentEvent">4.5 Interface DocumentEvent</a></h3>

          <dl>
            <dt><strong>Interface <em><a id="events-DocumentEvent">DocumentEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
            <dd>
              <p>The <code>DocumentEvent</code> interface provides a mechanism by which the user can create an <a href="#events-Event"><code>Event</code></a> object of a type supported by the implementation. If the feature “Events” is supported by the <code>Document</code> object, the <code>DocumentEvent</code> interface must be implemented on the same object.   Language-specific type casting may be required.</p>
              <dl>
                <dt>
                  <br />
                  <strong>IDL Definition</strong>
                </dt>
                <dd>
                  <pre class="idl" id="idl-interface-DocumentEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-DocumentEvent">DocumentEvent</a> {
  // Modified in DOM Level 3:
  <a href="#events-Event">Event</a>                     <a href="#events-DocumentEvent-createEvent">createEvent</a>(in DOMString eventInterface)
                                        raises(DOMException);
};
                  </code></pre>
                </dd>

                <dt><strong>Methods</strong></dt>
                <dd>
                  <dl>
                    <dt>
                      <code class="method-name">
                        <a id="events-DocumentEvent-createEvent">createEvent</a>
                      </code>
                    </dt>
                    <dd>
                      <div class="method">Creates an event object of the type specified.
                        <div class="parameters">
                          <strong>Parameters</strong>
                          <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">eventInterface</code> of type <code>DOMString</code></dt>
                            <dd>
                              <p>The <code>eventInterface</code> parameter specifies the name of the DOM Events interface to be supported by the created event object, e.g., <code>"Event"</code>, <code>"MouseEvent"</code>, <code>"MutationEvent"</code>, and so on. If the <a href="#events-Event"><code>Event</code></a> is to be dispatched via the <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> method, the appropriate event initialization method must be called after creation in order to initialize the <a class="noxref" href="#events-Event"><code>Event</code></a>'s values.</p>
                              <p class="example" id="example-createEvent"><strong>Example:</strong>  A content author wishing to synthesize some kind of <a href="#events-UIEvent"><code>UIEvent</code></a> would invoke <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("UIEvent")</code></a>. The <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method could then be called on the newly created <a class="noxref" href="#events-UIEvent"><code>UIEvent</code></a> object to set the specific type of user interface event to be dispatched, <a class="eventtype" href="#event-type-scroll"><code>scroll</code></a> for example, and set its context information, e.g., <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a>.</p>
                              <p>For backward compatibility reason, <code>"UIEvents"</code>, <code>"MouseEvents"</code>, <code>"MutationEvents"</code>, and <code>"HTMLEvents"</code> feature names are valid values for the parameter <code>eventInterface</code> and represent respectively the interfaces <a href="#events-UIEvent"><code>UIEvent</code></a>, <a href="#events-MouseEvent"><code>MouseEvent</code></a>, <a href="#events-MutationEvent"><code>MutationEvent</code></a>, and <a href="#interface-Event"><code>Event</code></a>, and the characters <code>'a'..'z'</code> are considered equivalent to the characters <code>'A'..'Z'</code>.</p>
                              <p>If the parameter does not match an event interface name supported by the implementation, the implementation must raise a <code>NOT_SUPPORTED_ERR</code>  <code>DOMException</code></p><p class="warning" id="warning-createEvent-untrusted"><strong>Warning!</strong>  For security reasons, events generated using <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("Event")</code></a> must have a <code class="attribute-name"><a href="#events-event-type-isTrusted">isTrusted</a></code> attribute value of <code>false</code>.  See <a href="#trusted-events">trusted events</a> for more details.</p>
                            </dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div class="return">
                        <strong>Return Value</strong>
                        <div class="returntable">
                          <table summary="Layout table: the first cell contains the type of the return value, the second contains a short description" border="0"><tr><td><p><a href="#events-Event"><code>Event</code></a></p></td><td><p>The newly created event object.</p></td></tr></table>
                        </div>
                      </div>
                      <!-- return -->
                      <div class="exceptions">
                        <strong>Exceptions</strong>
                        <div class="exceptiontable">
                          <table summary="Layout table: the first cell contains the type of the exception, the second contains the specific error code and a short description" border="0"><tr><td><p><code>DOMException</code></p></td><td><p>NOT_SUPPORTED_ERR: Raised if the implementation does not support the <a href="#events-Event"><code>Event</code></a> interface requested.</p></td></tr></table>
                        </div>
                      </div>
                      <!-- exceptions -->
                    </div>
<!-- method -->
                    </dd>
                  </dl>
                </dd>
              </dl>
            </dd>
          </dl>
          <h4><a id="event-creation" href="#event-creation">4.5.1 Event creation</a></h4>

          <p>In most cases, the events dispatched by the DOM Events implementation are also created by the implementation.  However, it is possible to simulate events, such as mouse events, by creating the <a href="#events-Event"><code>Event</code></a> objects and dispatch them using the DOM Events implementation.</p>
          <p>Creating <a href="#events-Event"><code>Event</code></a> objects that are known to the DOM Events implementation is done using <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent()</code></a>. The content author must then initialize the <a href="#events-Event"><code>Event</code></a> object by directly setting the <a href="#events-Event"><code>Event</code></a>'s property values, by using the generic <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method, or by using any existing event initialization method for that interface, before invoking <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a>. The <a href="#events-Event"><code>Event</code></a> objects created must be known by the DOM Events implementation; otherwise an event exception must be thrown.</p>
          <!-- <p class="example" id="example-create-event">
            <strong>Example:</strong>
            <i class="note" id="_6"><strong>To Do:</strong> Create examples of creating and dispatching an event.</i>
          </p> -->
        </div>
<!-- div3 Events-document -->
      </div>
<!-- div2 Events-interface -->
    </div>
<!-- div2 Events-types -->
    <div>
      <h2><a id="events-module" href="#events-module">5. Events Module</a></h2>

      <h3><a id="event-types" href="#event-types">5.1 Event Types</a></h3>

      <p>Each event must be associated with a type, called <em>event type</em> and available as the <a href="#events-event-type-type"><code class="interface-attribute">type</code></a> attribute on the event object. The event type must be of type <code>DOMString</code>.</p>
      <div>
        <h4><a id="event-types-list" href="#event-types-list">5.1.1 List of DOM3 Event Types</a></h4>

        <p>Depending on the level of DOM support, or the devices used for display (e.g., screen) or interaction (e.g., mouse, keyboard, touch screen, or voice), these event types can be generated by the implementation. When used with an [<cite><a class="informative" href="#references-XML">XML 1.0</a></cite>] or [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>] application, the specifications of those languages may restrict the semantics and scope (in particular the possible <a class="def" href="#glossary-proximal-event-target">proximal event targets</a>) associated with an event type. Refer to the specification defining the language used in order to find those restrictions or to find event types that are not defined in this document.</p>
        <p>The following table provides a non-normative summary of the event types defined in this specification.  All events must accomplish the capture and target phases, but not all of them must accomplish the bubbling phase (see also <a href="#event-flow">Event dispatch and DOM event flow</a>). Some events are not <a href="#events-dt-cancelable-event">cancelable</a> (see <a href="#event-flow-default-cancel">Default actions and cancelable events</a>). Some events must only be dispatched to a specific set of possible targets in the DOM event flow, specified using node types. Contextual information related to the event type must be accessible using DOM interfaces.</p>
        <table class="data-table" id="table-event-summary" summary="This table contains the complete list of event types defined by DOM Level 3 Events. The first column contains the local name of the event type. The second column indicates if the event accomplish the bubbling phase or not (all events accomplish the capture and target phases). The third column indicates if the default action associated with the event can be canceled. The fourth column indicates the nodes that can be target of the event. the fifth (and last) column indicates the DOM interface implemented by the event object.">
<!-- border="1" cellpadding="2" cellspacing="0"  -->
          <tr>
            <th>Event Type</th>
            <th>Sync / Async</th>
            <th>Bubbling phase</th>
            <th>Trusted proximal event target types</th>
            <th>DOM interface</th>
            <th>Cancelable</th>
            <th>Default Action</th>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-abort">
              <code>abort</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-Event"><code>Event</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-blur">
              <code>blur</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-click">
              <code>click</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td><a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-compositionstart">
              <code>compositionstart</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td>
            <td>Yes</td>
            <td>Launch <a class="def" href="#glossary-text-composition-system">text composition system</a></td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-compositionupdate">
              <code>compositionupdate</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-compositionend">
              <code>compositionend</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-dblclick">
              <code>dblclick</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMActivate">
              <code>DOMActivate</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-UIEvent"><code>UIEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMAttributeNameChanged">
              <code>DOMAttributeNameChanged</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMAttrModified">
              <code>DOMAttrModified</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMCharacterDataModified">
              <code>DOMCharacterDataModified</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>ProcessingInstruction</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMElementNameChanged">
              <code>DOMElementNameChanged</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMFocusIn">
              <code>DOMFocusIn</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMFocusOut">
              <code>DOMFocusOut</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMNodeInserted">
              <code>DOMNodeInserted</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument">
              <code>DOMNodeInsertedIntoDocument</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMNodeRemoved">
              <code>DOMNodeRemoved</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument">
              <code>DOMNodeRemovedFromDocument</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-DOMSubtreeModified">
              <code>DOMSubtreeModified</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>DocumentFragment</code>, <code>Element</code>, <code>Attr</code></td>
            <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-error">
              <code>error</code>
            </a></td>
            <td>Async</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-Event"><code>Event</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-focus">
              <code>focus</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-focusIn">
              <code>focusin</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-focusout">
              <code>focusout</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-keydown">
              <code>keydown</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Document</code>, <code>Element</code></td>
            <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td>
            <td>Yes</td>
            <td>Varies: <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-keypress">
              <code>keypress</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Document</code>, <code>Element</code></td>
            <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td>
            <td>Yes</td>
            <td>Varies: <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-keyup">
              <code>keyup</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Document</code>, <code>Element</code></td>
            <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-load">
              <code>load</code>
            </a></td>
            <td>Async</td>
            <td>No</td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td>
            <td><a href="#events-Event"><code>Event</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mousedown">
              <code>mousedown</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mouseenter">
              <code>mouseenter</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mouseleave">
              <code>mouseleave</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mousemove">
              <code>mousemove</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mouseout">
              <code>mouseout</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mouseover">
              <code>mouseover</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-mouseup">
              <code>mouseup</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-resize">
              <code>resize</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code></td>
            <td><a href="#events-UIEvent"><code>UIEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-scroll">
              <code>scroll</code>
            </a></td>
            <td>Async</td>
            <td>No / <a href="#scroll-document">Yes</a></td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td>
            <td><a href="#events-UIEvent"><code>UIEvent</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-select">
              <code>select</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-Event"><code>Event</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-textinput">
              <code>textinput</code>
            </a></td>
            <td>Sync</td>
            <td>Yes</td>
            <td><code>Element</code></td>
            <td><a href="#events-TextEvent"><code>TextEvent</code></a></td>
            <td>Yes</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-unload">
              <code>unload</code>
            </a></td>
            <td>Sync</td>
            <td>No</td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td>
            <td><a href="#events-Event"><code>Event</code></a></td>
            <td>No</td>
            <td>none</td>
          </tr>
          <tr>
            <td><a class="eventtype" href="#event-type-wheel">
              <code>wheel</code>
            </a></td>
            <td>Async</td>
            <td>Yes</td>
            <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td>
            <td><a href="#events-WheelEvent"><code>WheelEvent</code></a></td>
            <td>Yes</td>
            <td>Scroll (or zoom) the document</td>
          </tr>
        </table>
        <p>As an example of interpreting of this table, the event <a class="eventtype" href="#event-type-load"><code>load</code></a> is required to trigger event listeners attached on <code>Element</code> nodes for that event and on the capture and target phases. This event cannot be cancelled. If an event listener for the <a class="eventtype" href="#event-type-load"><code>load</code></a> event is attached to a node other than <a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, or <code>Element</code> nodes, or if it is attached to the bubbling phase only, this event listener is required not be triggered.</p>
        <p>The event objects associated with the event types described above may contain context information. Refer to the description of the DOM interfaces for further information.</p>
      </div>
<!-- div3 Events-EventTypes-complete -->
    </div>
<!-- div2 Events-definitions -->
    <div>
      <h2><a id="event-definitions" href="#event-definitions">5.2 Event Module Definitions</a></h2>

      <p>The DOM Event Model allows a DOM implementation to support multiple modules of events. The model has been designed to allow addition of new event modules if required. This document does not attempt to define all possible events. For purposes of interoperability, the DOM defines a module of user interface events including lower level device dependent events and a module of document mutation events.</p>
      <div>
        <h3><a id="events-uievents" href="#events-uievents">5.2.1 User Interface Event Types</a></h3>

        <p>This module defines the feature UIEvents 3.0 and depends on the features Events 3.0 and Views 2.0.</p>
        <p>The User Interface event module contains basic event types associated with user interfaces and document manipulation.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-UIEvent">UIEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
          <dd>
            <p>The <code>UIEvent</code> interface provides specific contextual information associated with User Interface events.</p>
            <p>To create an instance of the <code>UIEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("UIEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-UIEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-UIEvent">UIEvent</a> : <a href="#events-Event">Event</a> {
  readonly attribute views::AbstractView <a href="#events-UIEvent-view">view</a>;
  readonly attribute long            <a href="#events-UIEvent-detail">detail</a>;
  void                               <a href="#events-event-type-initUIEvent">initUIEvent</a>(in DOMString typeArg, 
                                                 in boolean canBubbleArg, 
                                                 in boolean cancelableArg, 
                                                 in views::AbstractView viewArg, 
                                                 in long detailArg);
};
                </code></pre>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-UIEvent-detail">detail</a></code> of type <code>long</code>, readonly</dt>
                  <dd><p>Specifies some detail information about the <a href="#events-Event"><code>Event</code></a>, depending on the type of event.</p></dd>

                  <dt><code class="attribute-name"><a id="events-UIEvent-view">view</a></code> of type <code>views::AbstractView</code>, readonly</dt>
                  <dd><p>The <code>view</code> attribute identifies the <code>AbstractView</code> from which the event was generated.</p></dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initUIEvent">initUIEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of an <code>UIEvent</code> object. This method has the same behavior as <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a>.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                            <dd><p>Specifies <a href="#events-UIEvent-view"><code>UIEvent.view</code></a>. This value may be <code>null</code>.</p></dd>
                            
                            <dt><code class="parameter-name">detailArg</code> of type <code>long</code></dt>
                            <dd><p>Specifies <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p>The User Interface event types are listed below.  Some of these events use the <a href="#events-UIEvent"><code>UIEvent</code></a> interface if generated from a user interface, but the <a href="#events-Event"><code>Event</code></a> interface otherwise, as detailed in each event.</p>

<!-- DOMActivate -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMActivate"><dfn>
                <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMActivate</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element being activated</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a button, link, or other state-changing element is activated.  Refer to <a href="#event-flow-activation">Activation triggers and behavior</a> for more details.</p>
              <p class="warning" id="DOMActivate-deprecated"><strong>Warning!</strong> The <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related <a class="def" href="#glossary-event-type">event type</a> <a class="eventtype" href="#event-type-click"><code>click</code></a>.  Other specifications may define and maintain their own <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> for backwards compatibility.</p>
              <p class="note" id="DOMActivate-click"><strong>Note:</strong>   While <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> and <a class="eventtype" href="#event-type-click"><code>click</code></a> are not completely equivalent, implemented behavior for the <a class="eventtype" href="#event-type-click"><code>click</code></a> <a class="def" href="#glossary-event-type">event type</a> has developed to encompass the most critical accessibility aspects for which the <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> <a class="def" href="#glossary-event-type">event type</a> was designed, and is more widely implemented.  Content authors are encouraged to use the <a class="eventtype" href="#event-type-click"><code>click</code></a> <a class="def" href="#glossary-event-type">event type</a> rather than the related <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> or <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> <a class="def" href="#glossary-event-type">event type</a> to ensure maximum accessibility.</p>
              
<!--    
From DOM2 Events, but not implemented:
[[
  The activate event occurs when an element is activated, for instance, thru a mouse click or a <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a>. A numerical argument is provided to give an indication of the type of activation that occurs: 1 for a simple activation (e.g., a simple click or Enter), 2 for hyperactivation (for instance a double click or Shift Enter). 
]]          
-->
              
            </dd>
          </dl>
        </div>

<!-- load -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-load"><dfn>
                <a class="eventtype" href="#event-type-load"><code>load</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>load</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Async</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: common object whose contained resources have loaded</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM implementation finishes loading the resource (such as the document) and any dependent resources (such as images, style sheets, or scripts). Dependent resources that fail to load must not prevent this event from firing if the resource that loaded them is still accessible via the DOM. If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node.</p>
<!-- This event differs from the <a class="eventtype" href="#event-type-DOMContentLoaded"><code>DOMContentLoaded</code></a> event in that it is not dispatched until all external resources are loaded.  -->
            </dd>
          </dl>
        </div>
        
<!-- DOMContentLoaded -->
<!-- <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMContentLoaded"><dfn><a class="eventtype" href="#event-type-DOMContentLoaded"><code>DOMContentLoaded</code></a></dfn></dt>
            <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMContentLoaded</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> <i class="issue"><strong>Issue:</strong> define event target</i></li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM implementation finishes loading the resource (such as the document), but before any dependent resources (such as images, style sheets, or scripts) are necessary loaded.  If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node.  This event differs from the <a class="eventtype" href="#event-type-load"><code>load</code></a> event in that it is dispatched immediately when the document markup is loaded, rather than waiting on external resources.</p>
            </dd>
          </dl>
        </div>
 -->

<!-- unload -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-unload"><dfn>
                <a class="eventtype" href="#event-type-unload"><code>unload</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>unload</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: common object whose contained resources have been removed</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the DOM Implementation removes from the environment the resource (such as the document) or any dependent resources (such as images, style sheets, scripts). The document must be unloaded after the dispatch of this event type. If this event type is dispatched, implementations are required to dispatch this event at least on the <code>Document</code> node.</p>
            </dd>
          </dl>
        </div>

<!-- abort -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-abort"><dfn>
                <a class="eventtype" href="#event-type-abort"><code>abort</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>abort</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element whose resources have been stopped from loading without error</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when the loading of a resource has been aborted, such as by a user canceling the load while it is still in progress.</p>
            </dd>
          </dl>
        </div>

<!-- error -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-error"><dfn>
                <a class="eventtype" href="#event-type-error"><code>error</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>error</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Async</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element whose resources have been stopped from loading due to an error</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a resource failed to load, or has been loaded but cannot be interpreted according to its semantics, such as an invalid image, a script execution error, or non-well-formed XML.</p>
            </dd>
          </dl>
        </div>

<!-- select -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-select"><dfn>
                <a class="eventtype" href="#event-type-select"><code>select</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>select</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a> if generated from a user interface, <a href="#events-Event"><code>Event</code></a> otherwise.</td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element whose text content has been selected</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a user selects some text.  This event is dispatched after the selection has occurred.</p>
              
              <p>This specification does not provide contextual information to access the selected text.  Where applicable, a <a class="def" href="#glossary-host-language">host language</a> should define rules for how a user may select content (with consideration for international language conventions), at what point the <a class="eventtype" href="#event-type-select"><code>select</code></a> event is dispatched, and how a content author may access the user-selected content.</p>
              
              <p class="note" id="note-get-select"><strong>Note:</strong>  In order to access to user-selected content, content authors should use native capabilities of the <a class="def" href="#glossary-host-language">host languages</a>, such as HTML's text selection API [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>].</p>
              
              <p class="note" id="note-select-na"><strong>Note:</strong> The <a class="eventtype" href="#event-type-select"><code>select</code></a> event may not be available for all elements in all languages.  For example, in [<cite><a class="informative" href="#references-HTML5">HTML5</a></cite>], <a class="eventtype" href="#event-type-select"><code>select</code></a> events can be dispatched only on form <code>input</code> and <code>textarea</code> elements.  Implementations can dispatch <a class="eventtype" href="#event-type-select"><code>select</code></a> events in any context deemed appropriate, including text selections outside of form controls, or image or markup selections such as in SVG.</p>              
              
            </dd>
          </dl>
        </div>

<!-- resize -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-resize"><dfn>
                <a class="eventtype" href="#event-type-resize"><code>resize</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>resize</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: object which has been resized</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a document view has been resized. This event type is dispatched after all effects for that occurrence of resizing of that particular <a class="def" href="#glossary-event-target">event target</a> have been executed by the <a class="def" href="#glossary-user-agent">user agent</a>.</p>
              <p><a class="def" href="#glossary-user-agent">User agents</a> which support continuous reflow of the document's layout during user-initiated resizing must dispatch this event synchronously after each reflow of the document.</p>
              <p>The <a class="def" href="#glossary-defaultView"><code>defaultView</code></a> object should always be resizable.  A <a class="def" href="#glossary-host-language">host language</a> may define certain elements to be resizable, and under what conditions (e.g., specific elements like <code class="element">iframe</code>, or elements with particular characteristics like width and height); however, this specification does not define the behavior for elements.</p>
              <p class="note" id="note-resize-zoom"><strong>Note:</strong>  The <a class="eventtype" href="#event-type-resize"><code>resize</code></a> event is distinct from the SVG <code class="eventtype">zoom</code> event types, though both may occur at the same time, or as the consequence of the same user action.  In particular, browser “font zooming” or “page zooming” should not necessarily trigger a <a class="eventtype" href="#event-type-resize"><code>resize</code></a> event.</p>
              <p class="note" id="note-resize-bubbling"><strong>Note:</strong> In previous DOM Events specifications, the <a class="eventtype" href="#event-type-resize"><code>resize</code></a> event type was defined to have a <a class="def" href="#glossary-bubbling-phase">bubbling phase</a>, but for performance reasons, this was not implemented in most user agents, and this specification removes the <a class="def" href="#glossary-bubbling-phase">bubbling phase</a> for this event.</p>
            </dd>
          </dl>
        </div>

<!-- scroll -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-scroll"><dfn>
                <a class="eventtype" href="#event-type-scroll"><code>scroll</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>scroll</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-UIEvent"><code>UIEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Async</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No / <a href="#scroll-document">Yes</a></td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: object which has been scrolled</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    </ul>
                   </td>
                 </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a document view or an element has been scrolled.  This event type is dispatched after the scroll has occurred.</p>
              
              <p id="scroll-document">When dispatched on the <code>Document</code> element, this event type must bubble to the <a class="def" href="#glossary-defaultView"><code>defaultView</code></a> object.</p>
            </dd>
          </dl>
        </div>

      </div>
    </div>
<!-- interface events-focusevents -->
    <div>
      <h3><a id="events-focusevent" href="#events-focusevent">5.2.2 Focus Event Types</a></h3>

      <p>This module defines the feature FocusEvents 3.0 and depends on the feature UIEvents 3.0.</p>
      
      <p class="note" id="note-focus-uaag"><strong>Note:</strong> This interface and its associated event types and <a href="#events-focusevent-event-order">focus event order</a> were designed in accordance to the concepts and guidelines defined in <a href="http://www.w3.org/WAI/UA/2010/ED-UAAG20-20100308/">User Agent Accessibility Guidelines 2.0</a> [<a href="#references-UAAG2">UAAG 2.0</a>], with particular attention on the <a href="http://www.w3.org/WAI/UA/2010/ED-UAAG20-20100308/#gl-focus-mechanism">focus mechanism</a> and the terms defined in the <a href="http://www.w3.org/WAI/UA/2010/ED-UAAG20-20100308/#def-focus">glossary entry for focus</a>.</p>

      <dl>
        <dt><strong>Interface <em><a id="events-FocusEvent">FocusEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
        <dd>
          <p>The <code>FocusEvent</code> interface provides specific contextual information associated with Focus events.</p>
          <p>To create an instance of the <code>FocusEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("FocusEvent")</code></a> method call.</p>
          <dl>
            <dt>
              <br />
              <strong>IDL Definition</strong>
            </dt>
            <dd>
              <pre class="idl" id="idl-interface-FocusEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-FocusEvent">FocusEvent</a> : <a href="#events-UIEvent">UIEvent</a> {
  readonly attribute <a href="#events-EventTarget">EventTarget</a>   <a href="#events-FocusEvent-relatedTarget">relatedTarget</a>;
  void                             <a href="#events-event-type-initFocusEvent">initFocusEvent</a>(in DOMString typeArg, 
                                                  in boolean canBubbleArg, 
                                                  in boolean cancelableArg, 
                                                  in views::AbstractView viewArg, 
                                                  in long detailArg, 
                                                  in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg);
};
              </code></pre>
            </dd>

            <dt><strong>Attributes</strong></dt>
            <dd>
              <dl>
                <dt><code class="attribute-name"><a id="events-FocusEvent-relatedTarget">relatedTarget</a></code> of type <a href="#events-EventTarget"><code>EventTarget</code></a>, readonly</dt>
                <dd>
                  <p>Used to identify a secondary <a href="#events-EventTarget"><code>EventTarget</code></a> related to a Focus event, depending on the type of event.</p>
                  <p>For security reasons with nested browsing contexts, when tabbing into or out of a nested context, the relevant EventTarget should be <code>null</code>.</p>
                  
                  <!-- <p class="issue" id="issue-relatedTarget-null-document"><strong>Issue:</strong> Alternate approach:  
                    <br/>
                    For security reasons with nested browsing contexts, when tabbing into or out of a nested context, the relevant EventTarget should be the element containing browsing context (e.g., the <code>iframe</code>), even if that element cannot normally receive focus.
                    <br/>
                    See [<a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0010.html">Comments from Olli Pettay</a>]
                    </p> -->
                </dd>

              </dl>
            </dd>

            <dt><strong>Methods</strong></dt>
            <dd>
              <dl>
                <dt>
                  <code class="method-name">
                    <a id="events-event-type-initFocusEvent">initFocusEvent</a>
                  </code>
                </dt>
                <dd>
                  <div class="method">Initializes attributes of a <code>FocusEvent</code> object. This method has the same behavior as <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>.
                    <div class="parameters">
                      <strong>Parameters</strong>
                      <div class="paramtable">
                        <dl>
                          <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">detailArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">relatedTargetArg</code> of type <a href="#events-EventTarget"><code>EventTarget</code></a></dt>
                          <dd><p>Specifies <a href="#events-FocusEvent-relatedTarget"><code>FocusEvent.relatedTarget</code></a>. This value may be <code>null</code>.</p>                            
                          </dd>
                        </dl>
                      </div>
                    </div>
                    <!-- parameters -->
                    <div><strong>No Return Value</strong></div>

                    <div><strong>No Exceptions</strong></div>
                  </div>
<!-- method -->
                </dd>
              </dl>
            </dd>
          </dl>
        </dd>
      </dl>
      <p>The Focus event types are listed below.</p>
      <h4 class="needswork">
        <a id="events-focusevent-event-order" href="#events-focusevent-event-order">5.2.2.1 Focus Event Order</a>
      </h4>
      <p>The focus events defined in this specification occur in a set order relative to one another.  The following is the typical sequence of events when a focus is shifted between elements (this order assumes that no element is initially focused):</p>
      <ol>
        <li><em>[user shifts focus]</em> <a class="eventtype" href="#event-type-focusIn"><code>focusin</code></a> (before first target element receives focus)</li>
        <li><a class="eventtype" href="#event-type-focus"><code>focus</code></a> (after first target element receives focus)</li>
        <li><a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a> (if supported)</li>
        <li><em>[user shifts focus]</em> <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a> (before first target element loses focus)</li>
        <li><a class="eventtype" href="#event-type-focusIn"><code>focusin</code></a> (before second target element receives focus)</li>
        <li><a class="eventtype" href="#event-type-blur"><code>blur</code></a> (after first target element loses focus)</li>
        <li><a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code></a> (if supported)</li>
        <li><a class="eventtype" href="#event-type-focus"><code>focus</code></a> (after second target element receives focus)</li>
        <li><a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a> (if supported)</li>
      </ol>
      
      <p class="note" id="note-focus-blur"><strong>Note:</strong>  This specification does not define the behavior of focus events when interacting with methods such as <code>focus()</code> or <code>blur()</code>; see the relevant specifications where those methods are defined for such behavior.</p>      
      <!-- <p class="issue"><strong>Issue:</strong> Behavior of focus events when interacting with focus()/blur() methods needs to be defined.  See [<a href="http://www.w3.org/2008/webapps/track/issues/102">ISSUE-102</a>]</p> -->
      
      <h4 class="needswork">
        <a id="events-focusevent-doc-focus" href="#events-focusevent-doc-focus">5.2.2.2 Document Focus and Focus Context</a>
      </h4>
      <p>This event module includes event types for notification of changes in document <a class="def" href="#glossary-event-focus">focus</a>.  Depending on the environment, document focus may be distinct from <a class="def" href="#glossary-user-agent">user agent</a> focus and operating system focus; this is referred to as focus context.  For example, in a typical desktop browser environment, the operating system context focus might be on one of many different applications, one of which is the browser; when the browser has focus, the user can shift the application context focus (such as with the tab key) among different browser user interface fields (e.g., the Web site location bar, a search field, etc.) before or after achieving document focus; once the document itself has focus, sequential shifting of focus will step through the focusable elements in the document.  The event types defined in this specification deal exclusively with document focus, and the <a class="def" href="#glossary-event-target">event target</a> identified in the event details must only be part of the document or documents in the window, never a part of the browser or operating system, even when switching from one focus context to another.</p>
      <p>Normally, a document always has a focused element, even if it is the document element itself, and a persistent <a class="def" href="#glossary-event-focus-ring">focus ring</a>; when switching between focus contexts, the document's currently focused element and focus ring normally remain in their current state; for example, if a document has three focusable elements, with the second element focused, when a user changes operating system focus to another application and then back to the browser, the second element will still be focused within the document, and tabbing will change the focus to the third element.  A <a class="def" href="#glossary-host-language">host language</a> may define specific elements which may or may not receive focus, the conditions user which an element may receive focus, the means by which focus may be changed, and the order in which the focus changes.  For example, in some cases an element might be given focus by moving a pointer over it, while other circumstances might require a mouse click; some elements might not be focusable at all, and some might be focusable only by special means (clicking on the element), but not by tabbing to it.  Documents may contain multiple focus rings.  Other specifications may define a more complex focus model than is described in this specification, including allowing multiple elements to have the current focus.</p>

<!-- blur -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-blur"><dfn>
              <a class="eventtype" href="#event-type-blur"><code>blur</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>blur</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> loses focus. The focus must be taken from the element before the dispatch of this event type.  This event type is similar to <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>, but is dispatched after focus is shifted, and does not bubble.</p>
          </dd>
        </dl>
      </div>

<!-- DOMFocusIn -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-DOMFocusIn"><dfn>
              <a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMFocusIn</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> receives focus. The focus must be given to the element before the dispatch of this event type. This event type must be dispatched after the event type <a class="eventtype" href="#event-type-focus"><code>focus</code></a>.</p>
            <p class="warning" id="_7"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusIn"><code>DOMFocusIn</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-focus"><code>focus</code></a> and <a class="eventtype" href="#event-type-focusIn"><code>focusin</code></a>.</p>
          </dd>
        </dl>
      </div>

<!-- DOMFocusOut -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-DOMFocusOut"><dfn>
              <a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMFocusOut</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> loses focus. The focus must be taken from the element before the dispatch of this event type. This event type must be dispatched after the event type <a class="eventtype" href="#event-type-blur"><code>blur</code></a>.</p>
            <p class="warning" id="_8"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMFocusOut"><code>DOMFocusOut</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the related event types <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>.</p>
          </dd>
        </dl>
      </div>

<!-- focus -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-focus"><dfn>
              <a class="eventtype" href="#event-type-focus"><code>focus</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>focus</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> receives focus. The focus must be given to the element before the dispatch of this event type.  This event type is similar to <a class="eventtype" href="#event-type-focusIn"><code>focusin</code></a>, but is dispatched after focus is shifted, and does not bubble.</p>
          </dd>
        </dl>
      </div>

<!-- focusin -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-focusIn"><dfn>
              <a class="eventtype" href="#event-type-focusIn"><code>focusin</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>focusin</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus  (if any).</li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> is about to receive focus. This event type must be dispatched before the element is given focus.  The <a class="def" href="#glossary-event-target">event target</a> must be the element which is about to receive focus.  This event type is similar to <a class="eventtype" href="#event-type-focus"><code>focus</code></a>, but is dispatched before focus is shifted, and does bubble.</p>
            <p class="note" id="_9"><strong>Note:</strong> When using this event type, the content author may use the event's <code class="attribute-name"><a href="#events-FocusEvent-relatedTarget">FocusEvent.relatedTarget</a></code> attribute (or a host-language-specific method or means) to get the currently focused element before the focus shifts to the next focus <a class="def" href="#glossary-event-target">event target</a>, thus having optional access to both the element losing focus and the element gaining focus without the use of the <a class="eventtype" href="#event-type-blur"><code>blur</code></a> or <a class="eventtype" href="#event-type-focusout">focusout</a> event types.</p>
          </dd>
        </dl>
      </div>

<!-- focusout -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-focusout"><dfn>
              <a class="eventtype" href="#event-type-focusout"><code>focusout</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>focusout</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-FocusEvent"><code>FocusEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-event-target">event target</a> losing focus</li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a>, <code>null</code></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-FocusEvent-relatedTarget"><code class="attribute-name">FocusEvent.relatedTarget</code></a>: <a class="def" href="#glossary-event-target">event target</a> receiving focus.</li>
                  </ul>
                 </td>
               </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when an <a class="def" href="#glossary-event-target">event target</a> is about to lose focus. This event type must be dispatched before the element loses focus.  The <a class="def" href="#glossary-event-target">event target</a> must be the element which is about to lose focus.  This event type is similar to <a class="eventtype" href="#event-type-blur"><code>blur</code></a>, but is dispatched before focus is shifted, and does bubble.</p>
          </dd>
        </dl>
      </div>
    </div>
<!-- interface events-focusevents -->


<!-- interface events-mouseevents -->
    <div>
      <h3><a id="events-mouseevents" href="#events-mouseevents">5.2.3 Mouse Event Types</a></h3>

      <p>This module defines the feature MouseEvents 3.0 and depends on the feature UIEvents 3.0.</p>
      <p>The Mouse event module originates from the [<cite><a class="informative" href="#references-HTML40">HTML 4.01</a></cite>] <code>onclick</code>, <code>ondblclick</code>, <code>onmousedown</code>, <code>onmouseup</code>, <code>onmouseover</code>, <code>onmousemove</code>, and <code>onmouseout</code> attributes. This event module is specifically designed for use with pointing input devices, such as a mouse or a trackball.</p>
      <dl>
        <dt><strong>Interface <em><a id="events-MouseEvent">MouseEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
        <dd>
          <p>The <code>MouseEvent</code> interface provides specific contextual information associated with Mouse events.</p>
          <p>In the case of nested elements mouse events are always targeted at the most deeply nested element. Ancestors of the targeted element may use bubbling to obtain notification of mouse events which occur within their descendent elements.</p>
          <p>To create an instance of the <code>MouseEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("MouseEvent")</code></a> method call.</p>
          <p class="note" id="_10"><strong>Note:</strong> When initializing <code>MouseEvent</code> objects using <code>initMouseEvent</code> or <code>initMouseEventNS</code>, implementations should use the client coordinates <code>clientX</code> and <code>clientY</code> for calculation of other coordinates (such as target coordinates exposed by <a class="def" href="#glossary-DOM-Level-0">DOM Level 0</a> implementations or other proprietary attributes, e.g., <code>pageX</code>).</p>
          <dl>
            <dt>
              <br />
              <strong>IDL Definition</strong>
            </dt>
            <dd>
              <pre class="idl" id="idl-interface-MouseEvent"><code>
// Modified in DOM Level 3:
interface <a href="#events-MouseEvent">MouseEvent</a> : <a href="#events-UIEvent">UIEvent</a> {
  readonly attribute long            <a href="#events-MouseEvent-screenX">screenX</a>;
  readonly attribute long            <a href="#events-MouseEvent-screenY">screenY</a>;
  readonly attribute long            <a href="#events-MouseEvent-clientX">clientX</a>;
  readonly attribute long            <a href="#events-MouseEvent-clientY">clientY</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-ctrlKey">ctrlKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-shiftKey">shiftKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-altKey">altKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-metaKey">metaKey</a>;
  readonly attribute unsigned short  <a href="#events-MouseEvent-button">button</a>;  
  readonly attribute unsigned short  <a href="#events-MouseEvent-buttons">buttons</a>;
  readonly attribute                 <a href="#events-EventTarget">EventTarget</a>     <a href="#events-MouseEvent-relatedTarget">relatedTarget</a>;
  void                               <a href="#events-event-type-initMouseEvent">initMouseEvent</a>(in DOMString typeArg, 
                                                in boolean canBubbleArg, 
                                                in boolean cancelableArg, 
                                                in views::AbstractView viewArg, 
                                                in long detailArg, 
                                                in long screenXArg, 
                                                in long screenYArg, 
                                                in long clientXArg, 
                                                in long clientYArg, 
                                                in boolean ctrlKeyArg, 
                                                in boolean altKeyArg, 
                                                in boolean shiftKeyArg, 
                                                in boolean metaKeyArg, 
                                                in unsigned short buttonArg,										
                                                in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg);
  // Introduced in DOM Level 3:
  boolean                            <a href="#events-MouseEvent-getModifierState">getModifierState</a>(in DOMString keyArg);
};
              </code></pre>
            </dd>

            <dt><strong>Attributes</strong></dt>
            <dd>
              <dl>
                <dt><code class="attribute-name"><a id="events-MouseEvent-altKey">altKey</a></code> of type <code>boolean</code>, readonly</dt>
                <dd><p>Refer to the <a href="#events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a> attribute.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-button">button</a></code> of type <code>unsigned short</code>, readonly</dt>
                <dd>
                  During mouse events caused by the depression or release of a mouse button, <code>button</code> must be used to indicate which pointer device button changed state. 
                  <p>The value of the <a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> attribute must be as follows:</p>
                  <ul>
                    <li><code>0</code> must indicate the primary button of the device (in general, the left button  or the only button on single-button devices, used to activate a user interface control or select text).</li>
                    <li><code>1</code> must indicate the auxiliary button (in general, the middle button, often combined with a mouse wheel).</li>
                    <li><code>2</code> must indicate the secondary button (in general, the right button, often used to display a context menu).</li>
                  </ul>
                  <p>Some pointing devices may provide or simulate more buttons, and values higher than <code>2</code> may be used to represent such buttons.</p>
                </dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-buttons">buttons</a></code> of type <code>unsigned short</code>, readonly</dt>
                <dd>During mouse events caused by the depression or release of a mouse button, <code>buttons</code> must be used to indicate which combination of mouse buttons are currently being pressed, expressed as a bitmask.  <span class="note" id="_11"><strong>Note:</strong> This should not be confused with the <a href="#events-MouseEvent-button">button</a> attribute.</span>
                <p>The value of the <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attribute must be as follows:</p>
                <ul>
                  <li><code>0</code> must indicates no button is currently active.</li>
                  <li><code>1</code> must indicate the primary button of the device (in general, the left button or the only button on single-button devices, used to activate a user interface control or select text).</li>
                  <li><code>2</code> must indicate the secondary button (in general, the right button, often used to display a context menu), if present.</li>
                  <li><code>4</code> must indicate the auxiliary button (in general, the middle button, often combined with a mouse wheel).</li>
                </ul>
                <p>Some pointing devices may provide or simulate more buttons.  To represent such buttons, the value must be doubled for each successive button (in the binary series <code>8</code>, <code>16</code>, <code>32</code>, ... ), and the buttons should alternate sides of the device, from left to right.  For example, with a 5-button mouse, the primary button (on the left) would have the value <code>1</code>, the secondary button (on the right) would have the value <code>2</code>, the auxiliary button (in the middle) would have the value <code>4</code>, the fourth button (on the left) would have the value <code>8</code>, and the fifth button (on the right) would have the value <code>16</code>.</p>              
                <p class="note" id="buttons-mask"><strong>Note:</strong> Because the sum of any set of button values is a unique number, a content author can use a bitwise operation to determine how many buttons are currently being pressed and which buttons they are, for an arbitrary number of mouse buttons on a device, e.g., the value <code>3</code> indicates that the left and right button are currently both pressed, while the value <code>5</code> indicates that the left and middle button are currently both pressed.</p>
                </dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-clientX">clientX</a></code> of type <code>long</code>, readonly</dt>
                <dd><p>The horizontal coordinate at which the event occurred relative to the viewport associated with the event.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-clientY">clientY</a></code> of type <code>long</code>, readonly</dt>
                <dd><p>The vertical coordinate at which the event occurred relative to the viewport associated with the event.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-ctrlKey">ctrlKey</a></code> of type <code>boolean</code>, readonly</dt>
                <dd><p>Refer to the <a href="#events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a> attribute.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-metaKey">metaKey</a></code> of type <code>boolean</code>, readonly</dt>
                <dd><p>Refer to the <a href="#events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a> attribute.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-relatedTarget">relatedTarget</a></code> of type <a href="#events-EventTarget"><code>EventTarget</code></a>, readonly</dt>
                <dd><p>Used to identify a secondary <a href="#events-EventTarget"><code>EventTarget</code></a> related to a UI event, depending on the type of event.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-screenX">screenX</a></code> of type <code>long</code>, readonly</dt>
                <dd><p>The horizontal coordinate at which the event occurred relative to the origin of the screen coordinate system.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-screenY">screenY</a></code> of type <code>long</code>, readonly</dt>
                <dd><p>The vertical coordinate at which the event occurred relative to the origin of the screen coordinate system.</p></dd>

                <dt><code class="attribute-name"><a id="events-MouseEvent-shiftKey">shiftKey</a></code> of type <code>boolean</code>, readonly</dt>
                <dd><p>Refer to the <a href="#events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a> attribute.</p></dd>

              </dl>
            </dd>

            <dt><strong>Methods</strong></dt>
            <dd>
              <dl>
                <dt><code class="method-name"><a id="events-MouseEvent-getModifierState">getModifierState</a></code> introduced in <strong class="since">DOM Level 3</strong></dt>
                <dd>
                  <div class="method">Queries the state of a modifier using a key value. See also <a href="#keys-Modifiers">Modifier keys</a>.
                    <div class="parameters">
                      <strong>Parameters</strong>
                      <div class="paramtable">
                        <dl>
                          <dt><code class="parameter-name">keyArg</code> of type <code>DOMString</code></dt>
                          <dd><p>Refer to the <a href="#events-KeyboardEvent-getModifierState"><code>KeyboardEvent.getModifierState()</code></a> method for a description of this parameter.</p></dd>
                        </dl>
                      </div>
                    </div>
                    <!-- parameters -->
                    <div class="return"><strong>Return Value</strong><div class="returntable"><table summary="Layout table: the first cell contains the type of the return value, the second contains a short description" border="0"><tr class="assert must"><td><p><code>boolean</code></p></td><td><p><code>true</code> if it is a modifier key and the modifier is activated, <code>false</code> otherwise.</p></td></tr></table></div></div>
                    <!-- return -->
                    <div><strong>No Exceptions</strong></div>
                  </div>
                </dd>


                <dt>
                  <code class="method-name">
                    <a id="events-event-type-initMouseEvent">initMouseEvent</a>
                  </code>
                </dt>
                <dd>
                  <div class="method">
                    <p>Initializes attributes of a <code>MouseEvent</code> object. This method has the same behavior as <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>.</p>
                    <div class="parameters">
                      <strong>Parameters</strong>
                      <div class="paramtable">
                        <dl>
                          <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>

                          <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>

                          <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">detailArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">screenXArg</code> of type <code>long</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-screenX"><code>MouseEvent.screenX</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">screenYArg</code> of type <code>long</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-screenY"><code>MouseEvent.screenY</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">clientXArg</code> of type <code>long</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-clientX"><code>MouseEvent.clientX</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">clientYArg</code> of type <code>long</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-clientY"><code>MouseEvent.clientY</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">ctrlKeyArg</code> of type <code>boolean</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-ctrlKey"><code>MouseEvent.ctrlKey</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">altKeyArg</code> of type <code>boolean</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-altKey"><code>MouseEvent.altKey</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">shiftKeyArg</code> of type <code>boolean</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-shiftKey"><code>MouseEvent.shiftKey</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">metaKeyArg</code> of type <code>boolean</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-metaKey"><code>MouseEvent.metaKey</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">buttonArg</code> of type <code>unsigned short</code></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">relatedTargetArg</code> of type <a href="#events-EventTarget"><code>EventTarget</code></a></dt>
                          <dd><p>Specifies <a href="#events-MouseEvent-relatedTarget"><code>MouseEvent.relatedTarget</code></a>. This value may be <code>null</code>.</p></dd>
                        </dl>
                      </div>
                    </div>
                    <!-- parameters -->
                    <div><strong>No Return Value</strong></div>

                    <div><strong>No Exceptions</strong></div>
                  </div>
                </dd>
              </dl>
            </dd>
          </dl>
        </dd>
      </dl>
      <p>The Mouse event types are listed below. In the case of nested elements, mouse event types are always targeted at the most deeply nested element. Ancestors of the targeted element may use bubbling to obtain notification of mouse events which occur within its descendent elements.</p>
      <p id="events-dt-current-click-count">Implementations must maintain the <em>current click count</em> when generating mouse events. This must be a non-negative integer indicating the number of consecutive clicks of a pointing device button during a user action. The notion of consecutive clicks depends on the environment configuration. For example, a <code><a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a></code> event type might not happen if there is a long delay between the two clicks.
      <span class="note" id="_12"><strong>Note:</strong> The value of <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a> for a number of clicks greater than 2 is platform-dependent.  For example, on the Windows OS, the click-count series seems to be <code>1, 2, 3, 2, 3</code>, while on MacOS, the click-count series seems to be <code>1, 2, 3, 4, 5, ...</code>.</span></p>
<!-- click -->
      <h4 class="needswork">
        <a id="events-mouseevent-event-order" href="#events-mouseevent-event-order">5.2.3.2 Mouse Event Order</a>
      </h4>
      <p>Certain mouse events defined in this specification occur in a set order relative to one another.  The following is the typical sequence of events when a pointing device's cursor is moved over an element:</p>
      <ol>
        <li>
          <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a>
        </li>
        <li><a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> (multiple events)</li>
        <li>
          <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a>
        </li>
      </ol>
      <p>The following is the typical sequence of events when a button associated with a pointing device (e.g., a mouse button or trackpad) is pressed and released over an element:</p>
      <ol>
        <li>
          <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>
        </li>
        <li><a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> (optional, multiple events, some limits)</li>
        <li>
          <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-click"><code>click</code></a>
        </li>
        <li><a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> (optional, multiple events, some limits)</li>
        <li>
          <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>
        </li>
        <li><a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> (optional, multiple events, some limits)</li>
        <li>
          <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-click"><code>click</code></a>
        </li>
        <li>
          <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>
        </li>
      </ol>
      <p>Note that the lag time, degree, distance, and number of <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> events allowed between the <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events while still firing a <a class="eventtype" href="#event-type-click"><code>click</code></a> or <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event must be implementation-, device-, and platform-specific.  Each implementation should determine the appropriate hysteresis tolerance, but in general should fire <a class="eventtype" href="#event-type-click"><code>click</code></a> and <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> events when the event target of the associated <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events is the same element with no <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> or <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a> events intervening, and should not fire <a class="eventtype" href="#event-type-click"><code>click</code></a> and <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> events when the event target of the associated <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events is different.</p>
      
      <p>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> (e.g. the target element) is removed from the DOM during the mouse events sequence, the remaining events of the sequence must not be fired on that element.</p>  
      <p class="example" id="element-remove-mouse"><strong>Example:</strong> if the target element is removed from the DOM as the result of a <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> event, no events for that element will be dispatched for <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, <a class="eventtype" href="#event-type-click"><code>click</code></a>, or <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>, nor any default activation events; however, the <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> event will still be dispatched on the element that is exposed to the mouse after the removal of the initial target element. Similarly,  if the target element is removed from the DOM during the dispatch of a <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> event, the <a class="eventtype" href="#event-type-click"><code>click</code></a> and subsequent events will not be dispatched.</p>

<!-- click -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-click"><dfn>
              <a class="eventtype" href="#event-type-click"><code>click</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>click</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>Varies</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a>; the attribute value must be <code>1</code> when the user begins this action and increments by <code>1</code> for each click.</li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                </td>
              </tr>
            </table>
            
            <p>The <a class="eventtype" href="#event-type-click"><code>click</code></a> event type must be dispatched on the <a class="def" href="#glossary-topmost-event-target">topmost event target</a> indicated by the pointer, when the user presses down and releases the pointer button, or otherwise activates the pointer in a manner that simulates such an action.  The actuation method of the mouse button must depend upon the pointer device and the environment configuration, e.g., it may depend on the screen location or the delay between the press and release of the pointing device button.</p>
            <p>The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be preceded by the <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> and <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> events on the same element, disregarding changes between other node types (e.g., text nodes).  Depending upon the environment configuration, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event may be dispatched if one or more of the event types <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>, <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a>, and <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> occur between the press and release of the pointing device button.  The <a class="eventtype" href="#event-type-click"><code>click</code></a> event may also be followed by the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
            
            <p id="example-mousemove-click" class="example"><strong>Example:</strong> If a user mouses down on a text node child of a &lt;p&gt; element which has been styled with a large line-height, shifts the mouse slightly such that it is no longer over an area containing text but is still within the containing block of that &lt;p&gt; element (i.e., the pointer is between lines of the same text block, but not over the text node per se), then subsequently mouses up, this will likely still trigger a <a class="eventtype" href="#event-type-click"><code>click</code></a> event (if it falls within the normal temporal hysteresis for a <a class="eventtype" href="#event-type-click"><code>click</code></a>), since the user has stayed within the scope of the same element; user-agent-generated mouse events are not dispatched on text nodes.</p>
            
            <!-- text nodes cannot be registered as event listeners, serve as the target of events, only element and document nodes are event targets. -->
            
            <p>In addition to being associated with pointer devices, the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type must be dispatched as part of an element activation, as described in <a href="#event-flow-activation">Activation triggers and behavior</a>.</p>
            
            <p class="note" id="click-activation"><strong>Note:</strong>  For maximum accessibility, content authors are encouraged to use the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type when defining activation behavior for custom controls, rather than other pointing-device event types such as <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a> or <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, which are more device-specific.  Though the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type has its origins in pointer devices (e.g., a mouse), subsequent implementation enhancements have extended it beyond that association, and it can be considered a device-independent event type for element activation.</p>
            
            <p>The <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type varies based on the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of the event and the value of the <a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> or <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attributes.  Typical <a class="def" href="#glossary-default-action">default actions</a> of the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type are as follows:</p>
            <ul>
              <li><em>Left click</em> (<a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> value is <code>0</code>, <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> value is <code>1</code>):
                <ul>
                  <li>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> has associated activation behavior, the <a class="def" href="#glossary-default-action">default action</a> must be to execute that activation behavior (see <a href="#event-flow-activation">Activation triggers and behavior</a>).</li>
                  <li>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> is focusable, the <a class="def" href="#glossary-default-action">default action</a> must be to give that element document focus.</li>
                </ul>
              </li>
              <li><em>Right click</em> (<a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> value is <code>1</code>, <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> value is <code>2</code>):
                <ul>
                  <li>The <a class="def" href="#glossary-default-action">default action</a> must be to provide a context menu of options related to that <a class="def" href="#glossary-proximal-event-target">proximal event target</a>.</li>
                </ul>
              </li>
              <li><em>Middle click</em> (<a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> value is <code>2</code>, <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> value is <code>4</code>):
                <ul>
                  <li>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> has associated activation behavior, the <a class="def" href="#glossary-default-action">default action</a> must be to execute that activation behavior in an alternate fashion (such as opening a link in a new tab or window).</li>
                  <li>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> has no associated activation behavior, the <a class="def" href="#glossary-default-action">default action</a> must be device- and user-defined, but when associated with a device wheel, is often to activate an alternate scrolling or panning mode.</li>
                </ul>
              </li>
            </ul>
          </dd>
        </dl>
      </div>

<!-- dblclick -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-dblclick"><dfn>
              <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>dblclick</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
                     <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                     <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is clicked twice over an element. The definition of a double click depends on the environment configuration, except that the event target must be the same between <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>, <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>, and <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a>. This event type must be dispatched after the event type <a class="eventtype" href="#event-type-click"><code>click</code></a> if a click and double click occur simultaneously, and after the event type <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a> otherwise.</p>
            <p class="note" id="_13"><strong>Note:</strong> Canceling the <a class="eventtype" href="#event-type-click"><code>click</code></a> event must not not affect the firing of a <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event.</p>
            <p>As with the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, the <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event type varies based on the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of the event and the value of the <a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> or <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> attributes.  Normally, the typical <a class="def" href="#glossary-default-action">default actions</a> of the <a class="eventtype" href="#event-type-dblclick"><code>dblclick</code></a> event type match those of the <a class="eventtype" href="#event-type-click"><code>click</code></a> event type, with the following additional behavior:</p>
            <ul>
              <li><em>Left click</em> (<a href="#events-MouseEvent-button"><code>MouseEvent.button</code></a> value is <code>0</code>, <a href="#events-MouseEvent-buttons"><code>MouseEvent.buttons</code></a> value is <code>1</code>):
                <ul>
                  <li>If the <a class="def" href="#glossary-proximal-event-target">proximal event target</a> is selectable, the <a class="def" href="#glossary-default-action">default action</a> must be to select part or all of the selectable content; subsequent clicks may select additional selectable portions of that content.</li>
                </ul>
              </li>
            </ul>
          </dd>
        </dl>
      </div>

<!-- mousedown -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mousedown"><dfn>
              <a class="eventtype" href="#event-type-mousedown"><code>mousedown</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mousedown</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one. For example, if no click happened before the mousedown, <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a> will contain the value <code>1</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                </td>
              </tr>
            </table>

            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is pressed over an element.</p>
          </dd>
        </dl>
      </div>

<!-- mouseenter -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mouseenter"><dfn>
              <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mouseenter</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved onto the boundaries of an element or one of its descendent elements.  This event type is similar to <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>, but differs in that it does not bubble, and must not be dispatched when the pointer device moves from an element onto the boundaries of one of its descendent elements.</p>
            <p class="note" id="_14"><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a> <a href="#references-CSS2">[CSS2]</a>.  See also the <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a> event type.</p>
          </dd>
        </dl>
      </div>

<!-- mouseleave -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mouseleave"><dfn>
              <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mouseleave</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved off of the boundaries of an element and all of its descendent elements.  This event type is similar to <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a>, but differs in that does not bubble, and that it must not be dispatched until the pointing device has left the boundaries of the element and the boundaries of all of its children.</p>
            <p class="note" id="_15"><strong>Note:</strong> There are similarities between this event type and the CSS <a href="http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes" title="Selectors"><code>:hover</code> pseudo-class</a> <a href="#references-CSS2">[CSS2]</a>.  See also the <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a> event type.</p>
          </dd>
        </dl>
      </div>

<!-- mousemove -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mousemove"><dfn>
              <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mousemove</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved while it is over an element.  The frequency rate of events while the pointing device is moved must be implementation-, device-, and platform-specific, but multiple consecutive <a class="eventtype" href="#event-type-mousemove"><code>mousemove</code></a> events should be fired for sustained pointer-device movement, rather than a single event for each instance of mouse movement.  Implementations are encouraged to determine the optimal frequency rate to balance responsiveness with performance.</p>
          </dd>
        </dl>
      </div>

<!-- mouseout -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mouseout"><dfn>
              <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mouseout</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>:  indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is entering, if any.</li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved off of the boundaries of an element.  This event type is similar to <a class="eventtype" href="#event-type-mouseleave"><code>mouseleave</code></a>, but differs in that does bubble, and that it must be dispatched when the pointer device moves from an element onto the boundaries of one of its descendent elements.</p>
            <p class="note" id="_16"><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a> event type.</p>
          </dd>
        </dl>
      </div>

<!-- mouseover -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mouseover"><dfn>
              <a class="eventtype" href="#event-type-mouseover"><code>mouseover</code></a>
            </dfn></dt>
          <dd>
            <table summary="This table contains information about the semantics of the given event type" border="0" cellpadding="2" cellspacing="0">
              <tbody>
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mouseover</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                      <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                      <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                      <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                      <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: <code>0</code></li>
                      <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                      <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>:  indicates the <a class="def" href="#glossary-event-target">event target</a> a pointing device is exiting, if any.</li>
                    </ul>
                  </td>
                </tr>
              </tbody>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device is moved onto the boundaries of an element.  This event type is similar to <a class="eventtype" href="#event-type-mouseenter"><code>mouseenter</code></a>, but differs in that does bubble, and that it must be dispatched when the pointer device moves onto the boundaries of an element whose ancestor element is the <a class="def" href="#glossary-event-target">event target</a> for the same event listener instance.</p>
            <p class="note" id="_17"><strong>Note:</strong> See also the <a class="eventtype" href="#event-type-mouseout"><code>mouseout</code></a> event type.</p>
          </dd>
        </dl>
      </div>

<!-- mouseup -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-mouseup"><dfn>
              <a class="eventtype" href="#event-type-mouseup"><code>mouseup</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>mouseup</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-MouseEvent"><code>MouseEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>none</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: indicates the <a href="#events-dt-current-click-count">current click count</a> incremented by one.</li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: value based on the pointer position on the screen</li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: value based on the pointer position within the viewport</li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: value based on current button pressed</li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: <code>null</code></li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a pointing device button is released over an element.</p>
          </dd>
        </dl>
      </div>
    </div>
<!-- div2 Events-eventgroupings -->
<!-- div3 Events-eventgroupings-mouseevents -->
    <div>
      <h3><a id="events-wheelevents" href="#events-wheelevents">5.2.4 Wheel Event Types</a></h3>

      <p>This module defines the feature WheelEvents 3.0 and depends on the feature MouseEvents 3.0.</p>
      <p>Wheels are devices that can be rotated in one or more spatial dimensions, and which may or may not be associated with a pointer device. The coordinate system depends on the environment configuration. As an example, the environment might be configured to associate vertical scrolling with rotation along the y-axis, horizontal scrolling with rotation along the x-axis, and zooming with rotation along the z-axis.  The deltax, deltaY, and deltaX attributes of <a href="#events-WheelEvent"><code>WheelEvent</code></a> objects indicate the distance of the rotation, as specified in the <a class="def" href="#glossary-delta">delta</a> definition. <!--The delta attributes of <a href='#events-WheelEvent'><code>WheelEvent</code></a> objects indicate the distance of the rotation. The measurement unit depends on the environment configuration. The sign of the delta value should indicate the direction of the rotation.--></p>
      <dl>
        <dt><strong>Interface <em><a id="events-WheelEvent">WheelEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
        <dd>
          <p>The <code>WheelEvent</code> interface provides specific contextual information associated with omnidirectional mouse wheel events.</p>
          <p>To create an instance of the <code>WheelEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("WheelEvent")</code></a> method call.</p>
          <dl>
            <dt>
              <br />
              <strong>IDL Definition</strong>
            </dt>
            <dd>
              <pre class="idl" id="idl-interface-WheelEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-WheelEvent">WheelEvent</a> : <a href="#events-MouseEvent">MouseEvent</a> {

  // DeltaModeCode
  const unsigned long                <a href="#events-DOM_DELTA_PIXEL">DOM_DELTA_PIXEL</a>       = 0x00;
  const unsigned long                <a href="#events-DOM_DELTA_LINE">DOM_DELTA_LINE</a>        = 0x01;
  const unsigned long                <a href="#events-DOM_DELTA_PAGE">DOM_DELTA_PAGE</a>        = 0x02;

  readonly attribute float            <a href="#events-WheelEvent-deltaX">deltaX</a>;
  readonly attribute float            <a href="#events-WheelEvent-deltaY">deltaY</a>;
  readonly attribute float            <a href="#events-WheelEvent-deltaZ">deltaZ</a>;
  readonly attribute unsigned long   <a href="#events-WheelEvent-deltaMode">deltaMode</a>;    
  void                               <a href="#events-event-type-initWheelEvent">initWheelEvent</a>(in DOMString typeArg, 
                                                    in boolean canBubbleArg, 
                                                    in boolean cancelableArg, 
                                                    in views::AbstractView viewArg, 
                                                    in long detailArg, 
                                                    in long screenXArg, 
                                                    in long screenYArg, 
                                                    in long clientXArg, 
                                                    in long clientYArg, 
                                                    in unsigned short buttonArg, 
                                                    in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg, 
                                                    in DOMString modifiersListArg, 
                                                    in float deltaXArg, 
                                                    in float deltaYArg, 
                                                    in float deltaZArg, 
                                                    in unsigned long deltaMode);
};
              </code></pre>
            </dd>

            <dt>
              <strong>Definition group <em><a id="events-ID-WheelEvent-DeltaModeCode">DeltaModeCode</a></em></strong>
            </dt>
            <dd>
              <p>This set of constants must be used to indicate the units of measurement for the <a href="#glossary-delta"><code>delta</code></a> values.  The precise measurement is specific to device, operating system, and application configurations.</p>
              <dl>
                <dt><strong>Defined Constants</strong></dt>
                <dd>
                  <dl>
                    <dt><a id="events-DOM_DELTA_PIXEL"><code class="constant-name">DOM_DELTA_PIXEL</code></a></dt>
                    <dd>The units of measurement for the <a href="#glossary-delta"><code>delta</code></a> must be pixels.  This is the most typical case in most operating system and implementation configurations.</dd>

                    <dt><a id="events-DOM_DELTA_LINE"><code class="constant-name">DOM_DELTA_LINE</code></a></dt>
                    <dd>The units of measurement for the <a href="#glossary-delta"><code>delta</code></a> must be individual lines of text.  This is the case for many form controls.</dd>

                    <dt><a id="events-DOM_DELTA_PAGE"><code class="constant-name">DOM_DELTA_PAGE</code></a></dt>
                    <dd>The units of measurement for the <a href="#glossary-delta"><code>delta</code></a> must be pages, either defined as a single screen or as a demarcated page.</dd>

                  </dl>
                </dd>
              </dl>
            </dd>

            <dt><strong>Attributes</strong></dt>
            <dd>
              <dl>
                <dt><code class="attribute-name"><a id="events-WheelEvent-deltaX">deltaX</a></code> of type <code>float</code>, readonly</dt>
                <dd><p>The distance the wheel has rotated around the x-axis.</p></dd>

                <dt><code class="attribute-name"><a id="events-WheelEvent-deltaY">deltaY</a></code> of type <code>float</code>, readonly</dt>
                <dd><p>The distance the wheel has rotated around the y-axis.</p></dd>

                <dt><code class="attribute-name"><a id="events-WheelEvent-deltaZ">deltaZ</a></code> of type <code>float</code>, readonly</dt>
                <dd><p>The distance the wheel has rotated around the z-axis.</p></dd>

                <dt><code class="attribute-name"><a id="events-WheelEvent-deltaMode">deltaMode</a></code> of type <code>unsigned long</code>, readonly</dt>
                <dd>
                  The <code>deltaMode</code> attribute contains an indication of to indicate the units of measurement for the <a href="#glossary-delta"><code>delta</code></a> values.  The default value is <a href="#events-DOM_DELTA_PIXEL"><code class="constant-name">DOM_DELTA_PIXEL</code></a> (pixels).  The value of <code>deltaMode</code> may be different for each of <code class="attribute-name"><a href="#events-WheelEvent-deltaX">deltaX</a></code>, <code class="attribute-name"><a href="#events-WheelEvent-deltaY">deltaY</a></code>, and <code class="attribute-name"><a href="#events-WheelEvent-deltaZ">deltaZ</a></code>, based on system configuration.<br />
                  <!-- <p class="issue"><strong>Issue:</strong> deltaMode is the proposed solution for <a href="http://www.w3.org/2008/webapps/track/issues/9" title="ISSUE-9 - Web Applications Working Group Tracker">ISSUE-9</a>.</p> -->
                </dd>
              </dl>
            </dd>

            <dt><strong>Methods</strong></dt>
            <dd>
              <dl>
                <dt><code class="method-name"><a id="events-event-type-initWheelEvent">initWheelEvent</a></code> introduced in <strong class="since">DOM Level 3</strong></dt>
                <dd>
                  <div class="method">
                    <p>Initializes attributes of a <code>WheelEvent</code> object. This method has the same behavior as <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a>.</p>
                    <div class="parameters">
                      <strong>Parameters</strong>
                      <div class="paramtable">
                        <dl>
                          <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">detailArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">screenXArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">screenYArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">clientXArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">clientYArg</code> of type <code>long</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">buttonArg</code> of type <code>unsigned short</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">relatedTargetArg</code> of type <a href="#events-EventTarget"><code>EventTarget</code></a></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">modifiersListArg</code> of type <code>DOMString</code></dt>
                          <dd><p>Refer to the <a href="#events-event-type-initMouseEvent"><code>MouseEvent.initMouseEvent()</code></a> method for a description of this parameter.</p></dd>
                          
                          <dt><code class="parameter-name">deltaXArg</code> of type <code>float</code></dt>
                          <dd><p>Specifies <a href="#events-WheelEvent-deltaX"><code>WheelEvent.deltaX</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">deltaYArg</code> of type <code>float</code></dt>
                          <dd><p>Specifies <a href="#events-WheelEvent-deltaY"><code>WheelEvent.deltaY</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">deltaZArg</code> of type <code>float</code></dt>
                          <dd><p>Specifies <a href="#events-WheelEvent-deltaZ"><code>WheelEvent.deltaZ</code></a>.</p></dd>
                          
                          <dt><code class="parameter-name">deltaModeArg</code> of type <code>unsigned long</code></dt>
                          <dd><p>Specifies <a href="#events-WheelEvent-deltaMode"><code>WheelEvent.deltaMode</code></a>.</p></dd>
                        </dl>
                      </div>
                    </div>
                    <!-- parameters -->
                    <div><strong>No Return Value</strong></div>

                    <div><strong>No Exceptions</strong></div>
                  </div>
<!-- method -->
                </dd>
              </dl>
            </dd>
          </dl>
        </dd>
      </dl>

<!-- wheel -->
      <div class="event-definition assert must">
        <dl>
          <dt id="event-type-wheel"><dfn>
              <a class="eventtype" href="#event-type-wheel"><code>wheel</code></a>
            </dfn></dt>
          <dd>
            <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
              <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>wheel</code></strong></td></tr>
              <tr class="assert must"><th>Interface</th> <td><a href="#events-WheelEvent"><code>WheelEvent</code></a></td></tr>
              <tr class="assert must"><th>Sync / Async</th> <td>Async</td></tr>
              <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>Element</code></td></tr>
              <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
              <tr class="assert must"><th>Default action</th> <td>scroll (or zoom) the document</td></tr>
              <tr class="assert must"><th>Context info</th>
                <td>
                  <ul>
                    <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <a class="def" href="#glossary-topmost-event-target">topmost event target</a></li>
                    <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                    <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenX"><code class="attribute-name">MouseEvent.screenX</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position on the screen, otherwise <code>0</code></li>
                    <li><a href="#events-MouseEvent-screenY"><code class="attribute-name">MouseEvent.screenY</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position on the screen, otherwise <code>0</code></li>
                    <li><a href="#events-MouseEvent-clientX"><code class="attribute-name">MouseEvent.clientX</code></a>: if the wheel is associated with a pointing device, the value based on the pointer position within the viewport, otherwise <code>0</code></li>
                    <li><a href="#events-MouseEvent-clientY"><code class="attribute-name">MouseEvent.clientY </code></a>: if the wheel is associated with a pointing device, the value based on the pointer position within the viewport, otherwise <code>0</code></li>
                    <li><a href="#events-MouseEvent-altKey"><code class="attribute-name">MouseEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-ctrlKey"><code class="attribute-name">MouseEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-shiftKey"><code class="attribute-name">MouseEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-metaKey"><code class="attribute-name">MouseEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                    <li><a href="#events-MouseEvent-button"><code class="attribute-name">MouseEvent.button</code></a>: if wheel is associated with a pointing device, value based on current button pressed, otherwise <code>0</code></li>
                    <li><a href="#events-MouseEvent-buttons"><code class="attribute-name">MouseEvent.buttons</code></a>: if wheel is associated with a pointing device, value based on all buttons current depressed, <code>0</code> if no buttons pressed</li>
                    <li><a href="#events-MouseEvent-relatedTarget"><code class="attribute-name">MouseEvent.relatedTarget</code></a>: indicates the <a class="def" href="#glossary-event-target">event target</a> the pointing device is pointing at, if any.</li>
                    <li><a href="#events-WheelEvent-deltaX"><code class="attribute-name">WheelEvent.deltaX</code></a>: distance the wheel has rotated around the x-axis</li>
                    <li><a href="#events-WheelEvent-deltaY"><code class="attribute-name">WheelEvent.deltaY</code></a>: distance the wheel has rotated around the y-axis</li>
                    <li><a href="#events-WheelEvent-deltaZ"><code class="attribute-name">WheelEvent.deltaZ</code></a>: distance the wheel has rotated around the z-axis</li>
                  </ul>
                </td>
              </tr>
            </table>
            <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a mouse wheel has been rotated around any axis, or when an equivalent input device (such as a mouse-ball, certain tablets or touchpads, etc.) has emulated such an action. Depending on the platform and input device, diagonal wheel deltas may be delivered either as a single wheel event with multiple non-zero axes or as separate wheel events for each non-zero axis.</p>
            <p>The typical default action of the <a class="eventtype" href="#event-type-wheel"><code>wheel</code></a> event type is to scroll (or in some cases, zoom) the document by the indicated amount.  If this event is canceled, the implementation must not scroll or zoom the document (or perform whatever other implementation-specific default action is associated with this event type).</p>
            <p class="note" id="note-delta-speed"><strong>Note:</strong> In some <a class="def" href="#glossary-user-agent">user agents</a>, or with some input devices, the speed that the wheel has been turned may affect the <a href="#glossary-delta"><code>delta</code></a> values, with a faster speed producing a higher <a href="#glossary-delta"><code>delta</code></a> value.</p>
            <p class="note" id="note-no-scroll-default"><strong>Note:</strong> The <a class="def" href="#glossary-default-action">default action</a> of a <a class="eventtype" href="#event-type-wheel"><code>wheel</code></a> event may be to scroll or zoom.</p>
          </dd>
        </dl>
      </div>
      
    
<!-- div3 Events-eventgroupings-textevents -->
      <div>
        <h3><a id="events-textevents" href="#events-textevents">5.2.5 Text Event Types</a></h3>

        <p>This module defines the feature TextEvents 3.0 and depends on the feature UIEvents 3.0.</p>
        <p>The text event module originates from the [<cite><a class="informative" href="#references-HTML40">HTML 4.01</a></cite>] <code>onkeypress</code> attribute. Unlike this attribute, the event type <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> applies only to characters and is designed for use with any text input devices, not just keyboards. Refer to <a href="#keys">Keyboard events and key values</a> for examples on how text events are used in combination with keyboard events.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-TextEvent">TextEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
          <dd>
            <p>The <code>TextEvent</code> interface provides specific contextual information associated with Text Events.</p>
            <p>To create an instance of the <code>TextEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("TextEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-TextEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-TextEvent">TextEvent</a> : <a href="#events-UIEvent">UIEvent</a> {

  // InputMethodCode
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_UNKNOWN">DOM_INPUT_METHOD_UNKNOWN</a>       = 0x00;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_KEYBOARD">DOM_INPUT_METHOD_KEYBOARD</a>      = 0x01;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_PASTE">DOM_INPUT_METHOD_PASTE</a>         = 0x02;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_DROP">DOM_INPUT_METHOD_DROP</a>          = 0x03;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_IME">DOM_INPUT_METHOD_IME</a>           = 0x04;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_OPTION">DOM_INPUT_METHOD_OPTION</a>        = 0x05;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_HANDWRITING">DOM_INPUT_METHOD_HANDWRITING</a>   = 0x06;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_VOICE">DOM_INPUT_METHOD_VOICE</a>         = 0x07;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_MULTIMODAL">DOM_INPUT_METHOD_MULTIMODAL</a>    = 0x08;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_SCRIPT">DOM_INPUT_METHOD_SCRIPT</a>        = 0x09;

  readonly attribute DOMString       <a href="#events-TextEvent-data">data</a>;
  readonly attribute unsigned long   <a href="#events-TextEvent-inputMethod">inputMethod</a>;  
  readonly attribute DOMString       <a href="#events-TextEvent-locale">locale</a>;
  void                               <a href="#events-event-type-initTextEvent">initTextEvent</a>(in DOMString typeArg, 
                                                   in boolean canBubbleArg, 
                                                   in boolean cancelableArg, 
                                                   in views::AbstractView viewArg, 
                                                   in DOMString dataArg, 
                                                   in unsigned long inputMethod, 
                                                   in DOMString localeArg);
};
                </code></pre>
              </dd>

              <dt>
                <strong>Definition group <em><a id="events-ID-TextEvent-InputMethodCode">InputMethodCode</a></em></strong>
              </dt>
              <dd>
                <p>This set of constants must be used to indicate the origin of the text input. In case a DOM implementation wishes to provide a new origin information, a value different from the following constant values must be used.</p>
                <dl>
                  <dt><strong>Defined Constants</strong></dt>
                  <dd>
                    <dl>
                      <dt><a id="events-DOM_INPUT_METHOD_UNKNOWN"><code class="constant-name">DOM_INPUT_METHOD_UNKNOWN</code></a></dt>
                      <dd>The text string was input by an unknown means.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_KEYBOARD"><code class="constant-name">DOM_INPUT_METHOD_KEYBOARD</code></a></dt>
                      <dd>The text string was input through a keyboard.  This may be associated with one or more of <code>keypress</code>,  <code>keydown</code>, or <code>keyup</code> events.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_PASTE"><code class="constant-name">DOM_INPUT_METHOD_PASTE</code></a></dt>
                      <dd>The text string was pasted in from a clipboard.  This may be associated with a <code>paste</code> event, specified elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_DROP"><code class="constant-name">DOM_INPUT_METHOD_DROP</code></a></dt>
                      <dd>The text string was inserted as part of a drag-and-drop operation.  This may be associated with a <code>drop</code> event, specified elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_IME"><code class="constant-name">DOM_INPUT_METHOD_IME</code></a></dt>
                      <dd>The text string was entered through an Input Method Editor.  This may be associated with a <code>compositionend</code> event.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_OPTION"><code class="constant-name">DOM_INPUT_METHOD_OPTION</code></a></dt>
                      <dd>The text string was selected from a set of options presented, such as from a form.  This may be associated with various other events, specified elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_HANDWRITING"><code class="constant-name">DOM_INPUT_METHOD_HANDWRITING</code></a></dt>
                      <dd>The text string was input through a pen/tablet device and processed by handwriting recognition software.  This may be associated with a specific event defined elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_VOICE"><code class="constant-name">DOM_INPUT_METHOD_VOICE</code></a></dt>
                      <dd>The text string was input by a voice device and interpreted by speech recognition software.  This may be associated with a specific event defined elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_MULTIMODAL"><code class="constant-name">DOM_INPUT_METHOD_MULTIMODAL</code></a></dt>
                      <dd>The text string was inserted as part of an operation involving multiple input modalities in combination, such as pointer-enhanced speech.  This may be associated with various other events, specified elsewhere.</dd>

                      <dt><a id="events-DOM_INPUT_METHOD_SCRIPT"><code class="constant-name">DOM_INPUT_METHOD_SCRIPT</code></a></dt>
                      <dd>The text string was inserted via a script operation on the DOM.  This may be associated with one or more  <code>mutation</code> events.</dd>

                    </dl>
                  </dd>
                </dl>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-TextEvent-data">data</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>data</code> holds the value of the characters generated by the character device. This may be a single Unicode character or a non-empty sequence of Unicode characters [<cite><a class="normative" href="#references-Unicode">Unicode</a></cite>]. Characters should be normalized as defined by the Unicode normalization form <em>NFC</em>, defined in [<cite><a class="normative" href="#references-UnicodeNormalization">UAX #15</a></cite>]. This attribute cannot be null or contain the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-TextEvent-inputMethod">inputMethod</a></code> of type <code>unsigned long</code>, readonly</dt>
                  <dd><p>The <code>inputMethod</code> attribute contains an indication of the origin of the text input, as described in <a href="#events-ID-TextEvent-InputMethodCode">InputMethodCode</a>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-TextEvent-locale">locale</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd>
                    <p>The <code>locale</code> attribute contains a BCP-47 tag [<a href="#ref-BCP-47">BCP-47</a>] indicating the locale for which the origin of the event (whether keyboard, IME, handwriting recognition software, or other input mode) is configured, e.g. "en-US". May be the <a class="def" href="#glossary-empty-string">empty string</a> when inapplicable or unknown, e.g. for pasted text, or when this information is not exposed by the underlying platform.</p>
                    <p class="note" id="note_TextEvent-locale"><strong>Note:</strong> <code>locale</code> does not necessarily indicate the locale of the data or the context in which it is being entered.  For example, a French user often might not switch to an English keyboard setting when typing English, in which case the <code>locale</code> will still indicate French, even though the data is actually English.</p>
                  </dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initTextEvent">initTextEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of a <code>TextEvent</code> object. This method has the same behavior as <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>. The value of <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a> remains undefined.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">dataArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-TextEvent-data"><code>TextEvent.data</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">inputMethodArg</code> of type <code>unsigned long</code></dt>
                            <dd><p>Specifies <a href="#events-TextEvent-inputMethod"><code>TextEvent.inputMethod</code></a>.</p></dd>

                            <dt><code class="parameter-name">localeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-TextEvent-locale"><code>TextEvent.locale</code></a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p>The text event type is listed below.</p>

<!-- textinput -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-textinput"><dfn>
                <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>textinput</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-TextEvent"><code>TextEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element receiving the text input</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-TextEvent-data"><code class="attribute-name">TextEvent.data</code></a>: the value of the text string being input</li>
                      <li><a href="#events-TextEvent-inputMethod"><code class="attribute-name">TextEvent.inputMethod</code></a>: the numerical code corresponding to the most applicable <em><a href="#events-ID-TextEvent-InputMethodCode">InputMethodCode</a></em></li>
                      <li><a href="#events-TextEvent-locale"><code class="attribute-name">TextEvent.locale</code></a>: the language code for the text input, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when one or more characters have been entered. These characters may originate from a variety of sources, e.g., characters resulting from a key being pressed or released on a keyboard device, from the processing of an <a class="def" href="#glossary-ime">input method editor</a>, or resulting from a voice command.  Where a “paste” operation generates a simple sequence of characters, i.e., a text passage without any structure or style information, this event type should be generated as well.</p>
            </dd>
          </dl>
        </div>
      </div>
<!-- div3 Events-TextEvents-Interfaces -->
      <div>
        <h3><a id="events-keyboardevents" href="#events-keyboardevents">5.2.6 Keyboard Event Types</a></h3>

        <p>This module defines the feature KeyboardEvents 3.0 and depends on the feature UIEvents 3.0.</p>
        <p>Keyboard events are device dependent, i.e., they rely on the capabilities of the input devices and how they are mapped in the operating systems. It is therefore highly recommended to rely on <a href="#events-TextEvent">Text event types</a> when dealing with character input.  Refer to <a href="#keys">Keyboard events and key values</a> for more details, including examples on how Keyboard Events are used in combination with Composition Events. Depending on the character generation device, keyboard events may or may not be generated.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-KeyboardEvent">KeyboardEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
          <dd>
            <p>The <code>KeyboardEvent</code> interface provides specific contextual information associated with keyboard devices. Each keyboard event references a key using a value. Keyboard events are commonly directed at the element that has the focus.</p>
            <p>The <code>KeyboardEvent</code> interface provides convenient attributes for some common modifiers keys: <a href="#events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a>, <a href="#events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a>, <a href="#events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a>, <a href="#events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a>. These attributes are equivalent to using the method <a href="#events-KeyboardEvent-getModifierState"><code>KeyboardEvent.getModifierState(keyArg)</code></a> with <code class="value">'Control'</code>, <code class="value">'Shift'</code>, <code class="value">'Alt'</code>, or <code class="value">'Meta'</code> respectively.</p>
            <p>To create an instance of the <code>KeyboardEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("KeyboardEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-KeyboardEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-KeyboardEvent">KeyboardEvent</a> : <a href="#events-UIEvent">UIEvent</a> {

  // KeyLocationCode
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_STANDARD">DOM_KEY_LOCATION_STANDARD</a>      = 0x00;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_LEFT">DOM_KEY_LOCATION_LEFT</a>          = 0x01;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_RIGHT">DOM_KEY_LOCATION_RIGHT</a>         = 0x02;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_NUMPAD">DOM_KEY_LOCATION_NUMPAD</a>        = 0x03;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_MOBILE">DOM_KEY_LOCATION_MOBILE</a>        = 0x04;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_JOYSTICK">DOM_KEY_LOCATION_JOYSTICK</a>      = 0x05;

  readonly attribute DOMString       <a href="#events-KeyboardEvent-char">char</a>;
  readonly attribute DOMString       <a href="#events-KeyboardEvent-key">key</a>;
  readonly attribute unsigned long   <a href="#events-KeyboardEvent-location">location</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-ctrlKey">ctrlKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-shiftKey">shiftKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-altKey">altKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-metaKey">metaKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-repeat">repeat</a>;
  readonly attribute DOMString       <a href="#events-KeyboardEvent-locale">locale</a>;
  boolean                            <a href="#events-KeyboardEvent-getModifierState">getModifierState</a>(in DOMString keyArg);
  void                               <a href="#events-KeyboardEvent-initKeyboardEvent">initKeyboardEvent</a>(in DOMString typeArg, 
                                                       in boolean canBubbleArg, 
                                                       in boolean cancelableArg, 
                                                       in views::AbstractView viewArg, 
                                                       in DOMString charArg, 
                                                       in DOMString keyArg, 
                                                       in unsigned long locationArg, 
                                                       in DOMString modifiersListArg,
                                                       in boolean repeat,
                                                       in DOMString localeArg); 
};
                </code></pre>
              </dd>
              <!-- readonly attribute unsigned long   <a href="#events-KeyboardEvent-supplemental-keyCode">keyCode</a>; -->

              <dt>
                <strong>Definition group <em><a id="events-ID-KeyboardEvent-KeyLocationCode">KeyLocationCode</a></em></strong>
              </dt>
              <dd>
                <p>This set of constants must be used to indicate the location of a key on the device. In case a DOM implementation wishes to provide a new location information, a value different from the following constant values must be used.</p>
                <dl>
                  <dt><strong>Defined Constants</strong></dt>
                  <dd>
                    <dl>
					  <dt><a id="events-DOM_KEY_LOCATION_STANDARD"><code class="constant-name">DOM_KEY_LOCATION_STANDARD</code></a></dt>
                      <dd>The key activation must not be distinguished as the left or right version of the key, and did not originate from the numeric keypad (or did not originate with a virtual key corresponding to the numeric keypad). <i class="example" id="_22"><strong>Example:</strong> the <code class="value">'Q'</code> key on a PC 101 Key US keyboard.</i></dd>

                      <dt><a id="events-DOM_KEY_LOCATION_LEFT"><code class="constant-name">DOM_KEY_LOCATION_LEFT</code></a></dt>
                      <dd>The key activated originated from the left key location (there is more than one possible location for this key). <i class="example" id="_18"><strong>Example:</strong> the left <code class="value">'Control'</code> key on a PC 101 Key US keyboard.</i></dd>
					  
					  <dt><a id="events-DOM_KEY_LOCATION_RIGHT"><code class="constant-name">DOM_KEY_LOCATION_RIGHT</code></a></dt>
                      <dd>The key activation originalted from the right key location (there is more than one possible location for this key). <i class="example" id="_21"><strong>Example:</strong> the right <code class="value">'Shift'</code> key on a PC 101 Key US keyboard.</i></dd>

                      <dt><a id="events-DOM_KEY_LOCATION_NUMPAD"><code class="constant-name">DOM_KEY_LOCATION_NUMPAD</code></a></dt>
                      <dd>The key activation originated on the numeric keypad or with a virtual key corresponding to the numeric keypad. <i class="example" id="_19"><strong>Example:</strong> the <code class="value">'1'</code> key on a PC 101 Key US keyboard located on the numeric pad.</i></dd>

                      <dt><a id="events-DOM_KEY_LOCATION_MOBILE"><code class="constant-name">DOM_KEY_LOCATION_MOBILE</code></a></dt>
                      <dd>The key activation originated on a mobile device, either on a physical keypad or a virtual keyboard. <i class="example" id="_23"><strong>Example:</strong> the <code class="value">'#'</code> key or softkey on a mobile device.</i></dd>

                      <dt><a id="events-DOM_KEY_LOCATION_JOYSTICK"><code class="constant-name">DOM_KEY_LOCATION_JOYSTICK</code></a></dt>
                      <dd>The key activation originated on a game controller or a joystick on a mobile device. <i class="example" id="_24"><strong>Example:</strong> the <code class="value">'DownLeft'</code> key on a game controller.</i></dd>

                    </dl>
                  </dd>
                </dl>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-altKey">altKey</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><code>true</code> if the <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> (alternative) or <code class="value keyname">'Option'</code> key modifier was active.</dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-ctrlKey">ctrlKey</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><p><code>true</code> if the <a href="#key-Ctrl"><code class="value keyname">'Ctrl'</code></a> (control) key modifier was active.</p></dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-char">char</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>char</code> holds the character value of the key pressed.  If the key press has a printed representation, then the value must be a non-empty Unicode character string, conforming to the <a href="#key-algorithm">algorithm for determining the key value</a> defined in this specification.  For a key associated with a macro to insert multiple characters, the value of the <code>char</code> attribute will hold the entire sequence of characters.  For a key which does not have a character representation, the value must be the <a class="def" href="#glossary-empty-string">empty string</a>.</p>
                    <p class="note" id="note-char-charCode"><strong>Note:</strong> the <code>char</code> attribute is not related to the legacy <code>charCode</code> attribute and does not have the same set of values.</p>
                  </dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-key">key</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>key</code> holds the key value of the key pressed.  If the value is has a printed representation, it must match the value of the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute; if the value is a control key which has no printed representation, it must be one of the key values defined in the <a href="#keys-keyvalues">key values set</a>, as determined by the <a href="#key-algorithm">algorithm for determining the key value</a>. Implementations that are unable to identify a key must use the key value <a href="#key-Unidentified"><code class="value keyname">'Unidentified'</code></a>.</p>
                    <p class="note" id="note-key-keyCode"><strong>Note:</strong> the <code>key</code> attribute is not related to the legacy <code>keyCode</code> attribute and does not have the same set of values.</p>
                    <!-- <p class="note" id="note-key-keyCode"><strong>Note:</strong> the <code>key</code> attribute is not related to the legacy <a href="#events-KeyboardEvent-supplemental-keyCode"><code>KeyboardEvent.keyCode</code></a> attribute and does not have the same set of values.</p> -->
                   </dd>

                  <!-- <dt><code class="attribute-name"><a id="events-KeyboardEvent-supplemental-keyCode">keyCode</a></code> of type <code>unsigned long</code>, readonly</dt>
                  <dd><p><code>keyCode</code> holds a system- and implementation-dependent numerical code signifying the unmodified identifier associated with the key pressed.  Unlike the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> or <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes, the set of possible values are not defined in this specification; typically, these value of the <code class="attr-name">keyCode</code> should represent the decimal codepoint in ASCII [<a href="#ref-rfc20">RFC20</a>][<a href="#ref-US-ASCII">US-ASCII</a>] or Windows 1252 [<a href="#ref-WIN1252">WIN1252</a>], but may be drawn from a different appropriate character set.  Implementations that are unable to identify a key must use the key value <code class="value">0</code>.</p></dd> -->

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-location">location</a></code> of type <code>unsigned long</code>, readonly</dt>
                  <dd><p>The <code>location</code> attribute contains an indication of the location of the key on the device, as described in <a href="#events-ID-KeyboardEvent-KeyLocationCode">Keyboard event types</a>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-metaKey">metaKey</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><code>true</code> if the meta (Meta) key modifier was active.
                    <p class="note" id="_26"><strong>Note:</strong> The <code>'Command'</code> key modifier on Macintosh systems must be represented using this key modifier.</p>
                  </dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-shiftKey">shiftKey</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><p><code>true</code> if the shift (Shift) key modifier was active.</p></dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-repeat">repeat</a></code> of type <code>boolean</code>, readonly</dt>
                  <dd><code>true</code> if the key has been pressed in a sustained manner.  Holding down a key must result in the repeating the events <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>, <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> (when supported by the user agent), and <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> (when the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> results in text input) in this order, at a rate determined by the system configuration. For mobile devices which have <em>long-key-press</em> behavior, the first key event with a <a href="#events-KeyboardEvent-repeat">repeat</a> attribute value of <code>'true'</code> must serve as an indication of a <em>long-key-press</em>.  The length of time that the key must be pressed in order to begin repeating is configuration-dependent.</dd>

                  <dt><code class="attribute-name"><a id="events-KeyboardEvent-locale">locale</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd>
                    <p>The <code>locale</code> attribute contains a BCP-47 tag [<a href="#ref-BCP-47">BCP-47</a>] indicating the locale for which the keyboard originating the event is configured, e.g. "en-US". May be the <a class="def" href="#glossary-empty-string">empty string</a> when inapplicable or unknown, e.g. when this information is not exposed by the underlying platform.</p>
                    <p class="note" id="note_KeyboardEvent-locale"><strong>Note:</strong> <code>locale</code> does not necessarily indicate the locale of the data or the context in which it is being entered.  For example, a French user often might not switch to an English keyboard setting when typing English, in which case the <code>locale</code> will still indicate French.  Nor can it be used to definitively calculate the "physical" or "virtual" key associated with the event, or the character printed on that key.</p>
                  </dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-KeyboardEvent-getModifierState">getModifierState</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      Queries the state of a modifier using a key value. See also <a href="#keys-Modifiers">Modifier keys</a>.
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">keyArg</code> of type <code>DOMString</code></dt>
                            <dd>
                              <p>A modifier key value.  Modifier keys defined in this specification are 
                                <a href="#key-Alt"><code class="value keyname">'Alt'</code></a>
                                <a href="#key-AltGraph"><code class="value keyname">'AltGraph'</code></a>
                                <a href="#key-CapsLock"><code class="value keyname">'CapsLock'</code></a>
                                <a href="#key-Control"><code class="value keyname">'Control'</code></a>
                                <a href="#key-Fn"><code class="value keyname">'Fn'</code></a>
                                <a href="#key-Meta"><code class="value keyname">'Meta'</code></a>
                                <a href="#key-NumLock"><code class="value keyname">'NumLock'</code></a>
                                <a href="#key-Scroll"><code class="value keyname">'Scroll'</code></a>
                                <a href="#key-Shift"><code class="value keyname">'Shift'</code></a>
                                <a href="#key-SymbolLock"><code class="value keyname">'SymbolLock'</code></a>, and 
                                <a href="#key-Win"><code class="value keyname">'Win'</code></a>
                                User agents may support additional implementation-specific modifier keys depending on the environment.</p>
                              <p class="note" id="_27"><strong>Note:</strong> If an application wishes to distinguish between right and left modifiers, this information could be deduced using keyboard events and <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>.</p>
                            </dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div class="return"><strong>Return Value</strong><div class="returntable"><table summary="Layout table: the first cell contains the type of the return value, the second contains a short description" border="0"><tr><td><p><code>boolean</code></p></td><td><p><code>true</code> if it is a modifier key and the modifier is activated, <code>false</code> otherwise.</p></td></tr></table></div></div>
                      <!-- return -->
                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>

                  <dt>
                    <code class="method-name">
                      <a id="events-KeyboardEvent-initKeyboardEvent">initKeyboardEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of a <code>KeyboardEvent</code> object. This method has the same behavior as <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>. The value of <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a> remains undefined.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">charArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">keyArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">locationArg</code> of type <code>unsigned long</code></dt>
                            <dd><p>Specifies <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">modifiersListArg</code> of type <code>DOMString</code></dt>
                            <dd><p>A <a class="normative" href="http://www.w3.org/TR/2004/REC-xml-20040204/#NT-S"><em>white space</em></a> separated list of modifier key values to be activated on this object. As an example, <code>"Control Alt"</code> marks the control and alt modifiers as activated.</p></dd>
                            
                            <dt><code class="parameter-name">repeatArg</code> of type <code>boolean</code></dt>
                            <dd><p>Specifies whether the key event is repeating; see <a href="#events-KeyboardEvent-repeat"><code>KeyboardEvent.repeat</code></a>.</p></dd>

                            <dt><code class="parameter-name">localeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-KeyboardEvent-locale"><code>KeyboardEvent.locale</code></a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p class="warning" id="keycode-charcode"><strong>Warning!</strong>  Legacy keyboard event implementations may include three additional attributes, <code>keyCode</code>, <code>charCode</code>, and <code>which</code>.  The <code>keyCode</code> attribute indicates a numeric value associated with a particular key on a computer keyboard, while the <code>charCode</code> attribute indicates the <acronym title="American Standard Code for Information Interchange">ASCII</acronym> value of the character associated with that key (which may or may not be the same as the <code>keyCode</code> value) and is applicable only to keys that produce a <a class="def" href="#glossary-character-value">character value</a>.  In practice, <code>keyCode</code> and <code>charCode</code> are inconsistent across platforms and even the same implementation on different operating systems or using different localizations.  DOM Level 3 Events  does not define values for either <code>keyCode</code> or <code>charCode</code>, or behavior for <code>charCode</code>; content authors should use <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> or <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> instead, in conforming DOM Level 3 Events implementations.  <em>For more information, see the informative appendix on <a href="#legacy-key-attributes">Legacy key attributes: keyCode, charCode, and which</a>.</em></p>
        <p class="note" id="note-virtual-keyboards"><strong>Note:</strong>  For compatibility with existing content, virtual keyboards, such as software keyboards on screen-based input devices, should produce the normal range of keyboard events, even though they do not possess physical keys.</p>
        
        
        <p class="note" id="key-IME-suppress"><strong>Note:</strong>  In some implementations or system configurations, some key events, or their values, might be suppressed by the <a class="def" href="#glossary-ime">IME</a> in use.</p>
        
        <p>The keyboard event types are listed below.</p>
        
        <h4 class="needswork">
          <a id="events-keyboard-event-order" href="#events-keyboard-event-order">5.2.6.1 Keyboard Event Order</a>
        </h4>
        <p>The keyboard events defined in this specification occur in a set order relative to one another, for any given key:</p>
        <ol>
          <li>
            <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>
          </li>
          <li><a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> (only for keys which produce a <a class="def" href="#glossary-character-value">character value</a>)</li>
          <li>If the key is depressed for a sustained period, the following events may repeat at an environment-dependent rate:
            <!-- and the key should seek counseling -->
            <ul>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> (with <a href="#events-KeyboardEvent-repeat">repeat</a> attribute set to <code class="value">true</code>)</li>
              <li><a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> (with <a href="#events-KeyboardEvent-repeat">repeat</a> attribute set to <code class="value">true</code>; only for keys which produce a <a class="def" href="#glossary-character-value">character value</a>)</li>
            </ul>
          </li>
          <li>
            <em>Any <a class="def" href="#glossary-default-action">default actions</a> related to this key</em>
          </li>
          <li>
            <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>
          </li>
        </ol>
        <p>Keys associated with a <a class="def" href="#glossary-character-value">character value</a> must, under normal circumstances, produce a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event as well.  The order of text events relative to keyboard events is as follows:</p>
        <ol>
          <li>
            <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>
          </li>
          <li><a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> (only for keys which produce a <a class="def" href="#glossary-character-value">character value</a>)</li>
          <li>If a <a class="def" href="#glossary-character-value">character value</a> is produced, <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a></li>
          <li>If the key is depressed for a sustained period,<!-- the key should seek counseling, and --> the following events may repeat at an environment-dependent rate:
            <ul>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> (with <a href="#events-KeyboardEvent-repeat">repeat</a> attribute set to <code class="value">true</code>)</li>
              <li><a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> (with <a href="#events-KeyboardEvent-repeat">repeat</a> attribute set to <code class="value">true</code>; only for keys which produce a <a class="def" href="#glossary-character-value">character value</a>)</li>
              <li>If a <a class="def" href="#glossary-character-value">character value</a> is produced, <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a></li>
            </ul>
          </li>
          <li>
            <em>Any <a class="def" href="#glossary-default-action">default actions</a> associated with this key</em>
          </li>
          <li>
            <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>
          </li>
        </ol>
        <p class="note" id="key-default"><strong>Note:</strong>  Typically, any <a class="def" href="#glossary-default-action">default actions</a> associated with any particular key must be completed before the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event is dispatched, which may delay the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event slightly (though this is not likely to be a perceptible delay).</p>
        
        <p class="warning" id="_28"><strong>Warning!</strong> Because of hardware limitations, on some keyboard devices, the order between the text event and keyboard events may differ.  For example, some mobile devices might dispatch the <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event after the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event.</p>
        
        <p>The <a class="def" href="#glossary-event-target">target</a> of a key event is the currently focused element which is processing the keyboard activity; this is often an HTML <code>input</code> element or a textual element which is editable, but may be an element defined by the <a class="def" href="#glossary-host-language">host language</a> to accept keyboard input for non-text purposes, such as the activation of a hotkey or trigger of some other behavior; if no suitable element is in focus, the event target will be the root element.</p>
        
        <p class="note" id="key-focus"><strong>Note:</strong>  The <a class="def" href="#glossary-event-target">event target</a> may change between different key events; for example, a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event on the <a href="#key-Tab"><code class="value keyname">'Tab'</code></a> key will likely have a different <a class="def" href="#glossary-event-target">event target</a> than the  <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event on the same keystroke.</p>

<!-- keydown -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-keydown"><dfn>
                <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>keydown</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>Varies: <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the key event, root element if no suitable input element focused</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-KeyboardEvent-char"><code class="attribute-name">KeyboardEvent.char</code></a>: the character value of the key pressed.</li>
					  <li><a href="#events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: the key value of the key pressed.</li>
                      <li><a href="#events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: the location of the key on the device.</li>
                      <li><a href="#events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-repeat"><code class="attribute-name">KeyboardEvent.repeat</code></a>:  <code>true</code> if a key has been depressed long enough to trigger key repetition, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-locale"><code class="attribute-name">KeyboardEvent.locale</code></a>: the language code for the key event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is pressed down. The <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. This event type must be generated after the <a class="def" href="#glossary-key-mapping">key mapping</a> but before the processing of an <a class="def" href="#glossary-ime">input method editor</a>, normally associated with the dispatching of a <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>, <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>, or <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event. This event type must be dispatched before the <a class="eventtype" href="#event-type-compositionstart"><code>keypress</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events event associated with the same key.</p>
              <p>The default action of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event depends upon the key:</p>
              <ul>
                <li>if the key is associated with a character, the default action must be to dispatch a <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event; in the case where the key which is associated with multiple characters (such as with a macro or certain sequences of dead keys), the default action must be to dispatch one <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event for each character
					<ul>
						<li>if the user agent does not support the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event, then the default action must be to dispatch a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event with the <a href="#events-TextEvent-data"><code class="attribute-name">data</code></a> attribute set to the value of the <a href="#events-KeyboardEvent-char"><code class="attribute-name">char</code></a> attribute of the <a class="eventtype" href="#event-type-keypress"><code>keydown</code></a> event; in the case where the key which is associated with multiple characters, the value of the <a href="#events-TextEvent-data"><code class="attribute-name">data</code></a> attribute of the <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event must be that string of characters</li>
					</ul>
                 </li>
                <li>if the key is associated with a <a class="def" href="#glossary-text-composition-system">text composition system</a>, the default action must be to launch that system</li>
                <li>if the key is the <a href="#key-Tab"><code class="value keyname">'Tab'</code></a> key, the default action must be to shift the document focus from the currently focused element (if any) to the new focused element, as described in <a href="#events-focusevent">Focus Event Types</a></li>
                <li>if the key is the <a href="#key-Enter"><code class="value keyname">'Enter'</code></a> or <a href="#key-Spacebar"><code class="value keyname">'Space'</code></a> key and the current focus is on a state-changing element, the default action must be to dispatch a <a class="eventtype" href="#event-type-click"><code>click</code></a> event, and a <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event if that event type is supported by the <a class="def" href="#glossary-user-agent">user agent</a> (refer to <a href="#event-flow-activation">activation triggers and behavior</a> for more details)</li>
                <!-- <li>if the key is associated with any other event type, such as the <a class="eventtype" href="#event-type-scroll"><code>scroll</code></a> event, the default action must be to dispatch an event of that type.</li> -->
              </ul>
              <p>If this event is canceled, the associated event types must not be dispatched, and the associated actions must not be performed.</p>
              <p class="note" id="_29"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
            </dd>
          </dl>
        </div>

<!-- keypress -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-keypress"><dfn>
                <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>keypress</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>Varies: <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event; launch <a class="def" href="#glossary-text-composition-system">text composition system</a>; <a class="eventtype" href="#event-type-blur"><code>blur</code></a> and <a class="eventtype" href="#event-type-focus"><code>focus</code></a> events; <a class="eventtype" href="#event-type-DOMActivate"><code>DOMActivate</code></a> event; other event</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the key event, root element if no suitable input element focused</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-KeyboardEvent-char"><code class="attribute-name">KeyboardEvent.char</code></a>: the character value of the key pressed.</li>
					  <li><a href="#events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: the key value of the key pressed.</li>
                      <li><a href="#events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: the location of the key on the device.</li>
                      <li><a href="#events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-repeat"><code class="attribute-name">KeyboardEvent.repeat</code></a>:  <code>true</code> if a key has been depressed long enough to trigger key repetition, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-locale"><code class="attribute-name">KeyboardEvent.locale</code></a>: the language code for the key event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is pressed down, if and only if that key normally produces a <a class="def" href="#glossary-character-value">character value</a>. The <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. This event type must be generated after the <a class="def" href="#glossary-key-mapping">key mapping</a> but before the processing of an <a class="def" href="#glossary-ime">input method editor</a>, normally associated with the dispatching of a <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>, <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>, or <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event. This event type must be dispatched after the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event and before the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event associated with the same key.</p>
			  <p>The default action of the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event must be to dispatch a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event with the <a href="#events-TextEvent-data"><code class="attribute-name">data</code></a> attribute set to the value of the <a href="#events-KeyboardEvent-char"><code class="attribute-name">char</code></a> attribute of the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event.</p>
              <p class="note" id="_31"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event is traditionally associated with detecting a <a class="def" href="#glossary-character-value">character value</a> rather than a physical key, and may not be available on all keys in some configurations.</p>
              <p class="warning" id="_32"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type in favor of the <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event type.</p>
            </dd>
          </dl>
        </div>

<!-- keyup -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-keyup"><dfn>
                <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>keyup</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Document</code>, <code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the key event, root element if no suitable input element focused</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-KeyboardEvent-char"><code class="attribute-name">KeyboardEvent.char</code></a>: the character value of the key pressed.</li>
					  <li><a href="#events-KeyboardEvent-key"><code class="attribute-name">KeyboardEvent.key</code></a>: the key value of the key pressed.</li>
                      <li><a href="#events-KeyboardEvent-location"><code class="attribute-name">KeyboardEvent.location</code></a>: the location of the key on the device.</li>
                      <li><a href="#events-KeyboardEvent-altKey"><code class="attribute-name">KeyboardEvent.altKey</code></a>: <code>true</code> if <a href="#key-Alt"><code class="value keyname">'Alt'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-shiftKey"><code class="attribute-name">KeyboardEvent.shiftKey</code></a>:  <code>true</code> if <a href="#key-Shift"><code class="value keyname">'Shift'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-ctrlKey"><code class="attribute-name">KeyboardEvent.ctrlKey</code></a>:  <code>true</code> if <a href="#key-Control"><code class="value keyname">'Control'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-metaKey"><code class="attribute-name">KeyboardEvent.metaKey</code></a>:  <code>true</code> if <a href="#key-Meta"><code class="value keyname">'Meta'</code></a> modifier was active, otherwise <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-repeat"><code class="attribute-name">KeyboardEvent.repeat</code></a>: <code>false</code></li>
                      <li><a href="#events-KeyboardEvent-locale"><code class="attribute-name">KeyboardEvent.locale</code></a>: the language code for the key event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a key is released.  The <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system.  This event type must be generated after the <a class="def" href="#glossary-key-mapping">key mapping</a>. This event type must be dispatched after the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> events event associated with the same key.</p>
              <p class="note" id="_33"><strong>Note:</strong> the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events are traditionally associated with detecting any key, not just those which produce a <a class="def" href="#glossary-character-value">character value</a>.</p>
            </dd>
          </dl>
        </div>
      </div>
<!-- div3 Events-eventgroupings-compositionevents -->
      <div>
        <h3><a id="events-compositionevents" href="#events-compositionevents">5.2.7 Composition Event Types</a></h3>

        <p>This module defines the feature CompositionEvents 3.0 and depends on the feature UIEvents 3.0.</p>
        <p>Composition Events provide a means for inputing text in a supplementary or alternate manner than by Keyboard Events, in order to allow the use of characters that may not be commonly available on keyboard. For example, Composition events might be used to add accents to characters despite their absence from standard US keyboards, to build up logograms of many Asian languages from their base components or categories, to select word choices from a combination of key presses on a mobile device keyboard, or to convert voice commands into text using a speech recognition processor.  Refer to <a href="#keys">Keyboard events and key values</a> for examples on how Composition Events are used in combination with keyboard events.</p>
        <p>Conceptually, a composition session consists of one <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a> event, one or more <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a> events, and one <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event, with the value of the <a href="#events-CompositionEvent-data">data</a> attribute persisting between each “stage” of this event chain during each session.  While a composition session is active, keyboard events should not be dispatched to the DOM (i.e., the <a class="def" href="#glossary-text-composition-system">text composition system</a> “swallows” the keyboard events), and only <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a> events may be dispatched to indicate the composition process.</p>
        <p>Not all <a class="def" href="#glossary-ime">IME</a> systems or devices expose the necessary data to the DOM, so the active composition string (the “Reading Window” or “candidate selection menu option”) may not be available through this interface, in which case the selection may be represented by the <a class="def" href="#glossary-empty-string">empty string</a>.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-CompositionEvent">CompositionEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
          <dd>
            <p>The <code>CompositionEvent</code> interface provides specific contextual information associated with Composition Events.</p>
            <p>To create an instance of the <code>CompositionEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("CompositionEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-CompositionEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-CompositionEvent">CompositionEvent</a> : <a href="#events-UIEvent">UIEvent</a> {
  readonly attribute DOMString       <a href="#events-CompositionEvent-data">data</a>;
  readonly attribute DOMString       <a href="#events-CompositionEvent-locale">locale</a>;
  void                               <a href="#events-event-type-initCompositionEvent">initCompositionEvent</a>(in DOMString typeArg, 
                                                          in boolean canBubbleArg, 
                                                          in boolean cancelableArg, 
                                                          in views::AbstractView viewArg, 
                                                          in DOMString dataArg,
                                                          in DOMString localeArg);
};
                </code></pre>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-CompositionEvent-data">data</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>data</code> holds the value of the characters generated by an input method. This may be a single Unicode character or a non-empty sequence of Unicode characters [<cite><a class="normative" href="#references-Unicode">Unicode</a></cite>]. Characters should be normalized as defined by the Unicode normalization form <em>NFC</em>, defined in [<cite><a class="normative" href="#references-UnicodeNormalization">UAX #15</a></cite>]. This attribute may be null or contain the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-CompositionEvent-locale">locale</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd>
                    <p>The <code>locale</code> attribute contains a BCP-47 tag [<a href="#ref-BCP-47">BCP-47</a>] indicating the locale for which the IME originating the event is configured, e.g. "ja", "zh-Hans", "ko". May be the <a class="def" href="#glossary-empty-string">empty string</a> when inapplicable or unknown, e.g. when this information is not exposed by the underlying platform or application.</p>
                    <p class="note" id="note_CompositionEvent-locale"><strong>Note:</strong> <code>locale</code> does not necessarily indicate the locale of the data or the context in which it is being entered.  For example, a French user often might not switch to an English keyboard setting when typing English, in which case the <code>locale</code> will still indicate French, even though the data is actually English.  Similarly, an IME application may not distinguish between the locale of Chinese and Kanji characters.</p>
                  </dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initCompositionEvent">initCompositionEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">Initializes attributes of a <code>CompositionEvent</code> object. This method has the same behavior as <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>. The value of <a href="#events-UIEvent-detail"><code>UIEvent.detail</code></a> remains undefined.
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">viewArg</code> of type <code>views::AbstractView</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">dataArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-CompositionEvent-data"><code>CompositionEvent.data</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">localeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-CompositionEvent-locale"><code>CompositionEvent.locale</code></a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p>The composition event types are listed below.</p>
        <h4 class="needswork">
          <a id="events-composition-event-order" href="#events-composition-event-order">5.2.7.1 Composition Event Order</a>
        </h4>
        <p>The composition events defined in this specification occur in a set order relative to one another:</p>
        <ol>
          <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a></li>
          <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a> (multiple events)</li>
          <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a></li>
        </ol>
        <p>Composition events which are not canceled and which do not have the <a class="def" href="#glossary-empty-string">empty string</a> as a value produce a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event as well.  The order of text events relative to composition events is as follows:</p>
        <ol>
          <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a></li>
          <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a> (multiple events)</li>
          <li>If a <a class="def" href="#glossary-character-value">character value</a> is produced, <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a></li>
          <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a></li>
        </ol>

<!-- compositionstart -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-compositionstart"><dfn>
                <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>compositionstart</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Default action</th> <td>Launch <a class="def" href="#glossary-text-composition-system">text composition system</a></td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the composition</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: the original string being edited, otherwise the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-CompositionEvent-locale"><code class="attribute-name">CompositionEvent.locale</code></a>: the language code for the composition event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> is invoked in preparation for composing a passage of text.  This event type is device-dependent, and may rely upon the capabilities of the text conversion system and how it is mapped into the operating system.  When a keyboard is used to feed an input method editor, this event type is generated after a <code>keydown</code> event, but speech or handwriting recognition systems may send this event type without keyboard events.  Some implemenations may populate the <a href="#events-CompositionEvent-data"><code>data</code></a> attribute of the <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a> event with the text currently selected in the document (for editing and replacement); otherwise, the value of the <a href="#events-CompositionEvent-data"><code>data</code></a> attribute must be  the <a class="def" href="#glossary-empty-string">empty string</a>.</p>
              <p>This event must be dispatched immediately before a <a class="def" href="#glossary-text-composition-system">text composition system</a> is launched, and before the DOM is modified due to the composition process.  The default action of this event is to launch the appropriate <a class="def" href="#glossary-text-composition-system">text composition system</a>.  If this event is canceled, the <a class="def" href="#glossary-text-composition-system">text composition system</a> must not be launched.  Note that canceling the <a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a> <em>event type</em> is distinct from canceling the <a class="def" href="#glossary-text-composition-system">text composition system</a> session (e.g., by hitting a cancel button or closing an <a class="def" href="#glossary-ime">IME</a> window).</p>
              <!-- <p>(<i class="issue" id="issue-composition_events"><strong>Issue:</strong> see <a href="http://lists.w3.org/Archives/Public/www-dom/2009JulSep/0143.html" title="Extra notes on composition events from Daniel Danilatos on 2009-08-07 (www-dom@w3.org from July to September 2009)">Extra notes on composition events</a> for more details.</i>)</p> -->
            </dd>
          </dl>
        </div>

<!-- compositionupdate -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-compositionupdate"><dfn>
                <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>compositionupdate</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the composition, <code>null</code> if not accessible</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: the string comprising the current results of the composition session, which may be the <a class="def" href="#glossary-empty-string">empty string</a> if the content has been deleted</li>
                      <li><a href="#events-CompositionEvent-locale"><code class="attribute-name">CompositionEvent.locale</code></a>: the language code for the composition event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> should dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> updates its active text passage with a new character, which is added to the string in <a href="#events-CompositionEvent-data"><code>CompositionEvent.data</code></a>.  Note that some <a class="def" href="#glossary-text-composition-system">text composition systems</a> may not expose this information to the DOM, in which case this event will not fire during the composition process.  If the composition session is canceled, this event will be fired immediately before the <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event, and the <a href="#events-CompositionEvent-data"><code>CompositionEvent.data</code></a> attribute will be set to the <a class="def" href="#glossary-empty-string">empty string</a>.</p>
            </dd>
          </dl>
        </div>

<!-- compositionend -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-compositionend"><dfn>
                <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>compositionend</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-CompositionEvent"><code>CompositionEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: focused element processing the composition</li>
                      <li><a href="#events-UIEvent-view"><code class="attribute-name">UIEvent.view</code></a>: <a class="def" href="#glossary-defaultView"><code class="attribute-value">defaultView</code></a></li>
                      <li><a href="#events-UIEvent-detail"><code class="attribute-name">UIEvent.detail</code></a>: <code>0</code></li>
                      <li><a href="#events-CompositionEvent-data"><code class="attribute-name">CompositionEvent.data</code></a>: the string comprising the final result of the composition session, which may be the <a class="def" href="#glossary-empty-string">empty string</a> if the content has been deleted or if the composition process has been canceled</li>
                      <li><a href="#events-CompositionEvent-locale"><code class="attribute-name">CompositionEvent.locale</code></a>: the language code for the composition event, if available; otherwise, the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a <a class="def" href="#glossary-text-composition-system">text composition system</a> completes the composition of its active text passage, or cancels the composition process.  If the result of the <a class="def" href="#glossary-text-composition-system">text composition system</a> is not null and does not contain the <a class="def" href="#glossary-empty-string">empty string</a>, this event type will be preceded by a <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event type with the appropriate 
                <a href="#events-TextEvent-inputMethod">inputMethod</a> value, such as 
                <a href="#events-DOM_INPUT_METHOD_IME">DOM_INPUT_METHOD_IME</a>, 
                <a href="#events-DOM_INPUT_METHOD_HANDWRITING">DOM_INPUT_METHOD_HANDWRITING</a>, 
                <a href="#events-DOM_INPUT_METHOD_VOICE">DOM_INPUT_METHOD_VOICE</a>, or 
                <a href="#events-DOM_INPUT_METHOD_MULTIMODAL">DOM_INPUT_METHOD_MULTIMODAL</a>.</p>
              <p>This event is dispatched immediately after the <a class="def" href="#glossary-text-composition-system">text composition system</a> is completed (e.g., the <a class="def" href="#glossary-ime">IME</a> closed, minimized, switched out of focus, or otherwise dismissed, with the focus switched back to the <a class="def" href="#glossary-user-agent">user agent</a>).</p>
            </dd>
          </dl>
        </div>

        <div>
          <h4><a id="handwriting" href="#handwriting">5.2.7.2 Handwriting Recognition Systems</a></h4>

          <p>The following example describes a possible sequence of events when composing a text passage “text” with a handwriting recognition system, such as on a pen tablet, as modeled using Composition Events.</p>
          <div class="example" id="example-composition-selection">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>: <code class="value">''</code></li>
              <li><em>[User writes word on tablet surface]</em>
                <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'test'</code></li>
              <li><em>[User rejects first word-match suggestion, selects different match]</em>
                <a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'text'</code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'text'</code> (<code>"inputMethod"</code>: <code class="value">'DOM_INPUT_METHOD_HANDWRITING'</code>)</li>
              <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>: <code class="value">'text'</code></li>
            </ol>
          </div>
        </div>
      </div>

      <div>
        <h3><a id="events-mutationevents" href="#events-mutationevents">5.2.8 Mutation Events</a></h3>

        <p>This module defines the feature MutationEvents 3.0 and depends on the feature Events 3.0.</p>
        <p>The mutation and mutation name event modules are designed to allow notification of any changes to the structure of a document, including attribute, text, or name modifications. It may be noted that none of the event types associated with the modules are designated as cancelable. This stems from the fact that it is very difficult to make use of existing DOM interfaces which cause document modifications if any change to the document might or might not take place due to cancelation of the resulting event. Although this is still a desired capability, it was decided that it would be better left until the addition of transactions into the DOM.</p>
<!-- <p class="issue">Note that nodes that are not in the document, such as elements freshly created, or elements removed from the DOM, must not fire mutation events when changed.  For example, if an element is created but not yet inserted into the document, then an existing element located in the document must be moved from its current location to be a child of the new element, there must be one mutation event, for removing the existing element from its previous location, but no event must fire for insertion of the element into the new element, regardless of any assigned mutation event listeners.</p>
          <p class="issue">?What happens to event listeners on an element when it is removed from the tree, or moved elsewhere in the tree?</p> -->
        <p>Many single modifications of the tree can cause multiple mutation events to be dispatched. Rather than attempt to specify the ordering of mutation events due to every possible modification of the tree, the ordering of these events is left to the implementation.</p>
        <p class="warning" id="_34"><strong>Warning!</strong>  The <a href="#events-MutationEvent">MutationEvent interface</a> was introduced in DOM Level 2 Events, but has not yet been completely and interoperably implemented across <a class="def" href="#glossary-user-agent">user agents</a>.  In addition, there have been critiques that the interface, as designed, introduces a performance and implementation challenge.  A new specification is under development with the aim of addressing the use cases that mutation events solves, but in more performant manner.  Thus, this specification describes mutation events for reference and completeness of legacy behavior, but <a class="def" href="#glossary-deprecated">deprecates</a> the use of both the <a href="#events-MutationEvent"><code>MutationEvent</code></a> interface and the <a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a> interface.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-MutationEvent">MutationEvent</a></em></strong> (introduced in <strong class="since">DOM Level 2</strong>)</dt>
          <dd>
            <p>The <code>MutationEvent</code> interface provides specific contextual information associated with Mutation events.</p>
            <p>To create an instance of the <code>MutationEvent</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("MutationEvent")</code></a> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-MutationEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-MutationEvent">MutationEvent</a> : <a href="#events-Event">Event</a> {

  // attrChangeType
  const unsigned short      <a href="#events-MODIFICATION">MODIFICATION</a>                   = 1;
  const unsigned short      <a href="#events-ADDITION">ADDITION</a>                       = 2;
  const unsigned short      <a href="#events-REMOVAL">REMOVAL</a>                        = 3;

  readonly attribute Node            <a href="#events-MutationEvent-relatedNode">relatedNode</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-prevValue">prevValue</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-newValue">newValue</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-attrName">attrName</a>;
  readonly attribute unsigned short  <a href="#events-MutationEvent-attrChange">attrChange</a>;
  void               <a href="#events-event-type-initMutationEvent">initMutationEvent</a>(in DOMString typeArg, 
                                       in boolean canBubbleArg, 
                                       in boolean cancelableArg, 
                                       in Node relatedNodeArg, 
                                       in DOMString prevValueArg, 
                                       in DOMString newValueArg, 
                                       in DOMString attrNameArg, 
                                       in unsigned short attrChangeArg);
};
                </code></pre>
              </dd>

              <dt>
                <strong>Definition group <em><a id="events-MutationEvent-attrChangeType">attrChangeType</a></em></strong>
              </dt>
              <dd>
                <p>An integer indicating in which way the <code>Attr</code> was changed.</p>
                <dl>
                  <dt><strong>Defined Constants</strong></dt>
                  <dd>
                    <dl>
                      <dt><a id="events-ADDITION"><code class="constant-name">ADDITION</code></a></dt>
                      <dd>The <code>Attr</code> was just added.</dd>

                      <dt><a id="events-MODIFICATION"><code class="constant-name">MODIFICATION</code></a></dt>
                      <dd>The <code>Attr</code> was modified in place.</dd>

                      <dt><a id="events-REMOVAL"><code class="constant-name">REMOVAL</code></a></dt>
                      <dd>The <code>Attr</code> was just removed.</dd>

                    </dl>
                  </dd>
                </dl>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-MutationEvent-attrChange">attrChange</a></code> of type <code>unsigned short</code>, readonly</dt>
                  <dd><p><code>attrChange</code> indicates the type of change which triggered the <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event. The values can be <code>MODIFICATION</code>, <code>ADDITION</code>, or <code>REMOVAL</code>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-MutationEvent-attrName">attrName</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>attrName</code> indicates the name of the changed <code>Attr</code> node in a <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event.</p></dd>

                  <dt><code class="attribute-name"><a id="events-MutationEvent-newValue">newValue</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>newValue</code> indicates the new value of the <code>Attr</code> node in <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> events, and of the <code>CharacterData</code> node in <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a> events.</p></dd>

                  <dt><code class="attribute-name"><a id="events-MutationEvent-prevValue">prevValue</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p><code>prevValue</code> indicates the previous value of the <code>Attr</code> node in <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> events, and of the <code>CharacterData</code> node in <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a> events.</p></dd>

                  <dt><code class="attribute-name"><a id="events-MutationEvent-relatedNode">relatedNode</a></code> of type <code>Node</code>, readonly</dt>
                  <dd><p><code>relatedNode</code> must be used to identify a secondary node related to a mutation event. For example, if a mutation event is dispatched to a node indicating that its parent has changed, the <code>relatedNode</code> will be the changed parent. If an event is instead dispatched to a subtree indicating a node was changed within it, the <code>relatedNode</code> must be the changed node. In the case of the <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event it indicates the <code>Attr</code> node which was modified, added, or removed.</p></dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt>
                    <code class="method-name">
                      <a id="events-event-type-initMutationEvent">initMutationEvent</a>
                    </code>
                  </dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of a <code>MutationEvent</code> object. This method has the same behavior as <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a>.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initEvent"><code>Event.initEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">relatedNodeArg</code> of type <code>Node</code></dt>
                            <dd><p>Specifies <a href="#events-MutationEvent-relatedNode"><code>MutationEvent.relatedNode</code></a>.</p></dd>
                            
                            <dt><code class="parameter-name">prevValueArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-MutationEvent-prevValue"><code>MutationEvent.prevValue</code></a>. This value may be the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>
                            
                            <dt><code class="parameter-name">newValueArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-MutationEvent-newValue"><code>MutationEvent.newValue</code></a>. This value may be the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>
                            
                            <dt><code class="parameter-name">attrNameArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-MutationEvent-attrName"><code>MutationEvent.attrName</code></a>. This value may be the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>
                            
                            <dt><code class="parameter-name">attrChangeArg</code> of type <code>unsigned short</code></dt>
                            <dd><p>Specifies <a href="#events-MutationEvent-attrChange"><code>MutationEvent.attrChange</code></a>. This value may be <code>0</code>.</p></dd>
                          </dl>
                        </div>
                      </div>

                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p>The mutation event types are listed below.</p>

<!-- DOMAttrModified -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMAttrModified"><dfn>
                <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMAttrModified</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element whose attribute is being modified</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the name of the changed <code>Attr</code> node</li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: the numerical code corresponding to the most applicable <a href="#events-MutationEvent-attrChangeType">attrChangeType</a></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>:  the <code>Attr</code> node that has been modified, added, or removed.</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: new value of the attribute, if the <code>Attr</code> node has been added or modified</li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: previous value of the attribute, if the <code>Attr</code> node has been removed or modified</li>
                    </ul>
                  </td>
                </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after an <code>Attr.value</code> has been modified and after an <code>Attr</code> node has been added to or removed from an <code>Element</code>. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the <code>Element</code> node where the change occurred. It is implementation dependent whether this event type occurs when the children of the <code>Attr</code> node are changed in ways that do not affect the value of <code>Attr.value</code>.</p>
              <p class="warning" id="_44"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttrModified"><code>DOMAttrModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>

<!-- DOMCharacterDataModified -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMCharacterDataModified"><dfn>
                <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMCharacterDataModified</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>ProcessingInstruction</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: object whose content is being modified</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: parent node of the object whose content is being modified</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: new value of the object</li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: previous value of the object</li>
                    </ul>
                  </td>
                </tr>
              </table>
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after <code>CharacterData.data</code> or <code>ProcessingInstruction.data</code> have been modified, but the node itself has not been inserted or deleted.  The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the <code>CharacterData</code> node or the <code>ProcessingInstruction</code> node.</p>
              <p class="warning" id="_45"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMCharacterDataModified"><code>DOMCharacterDataModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>


<!-- DOMNodeInserted -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMNodeInserted"><dfn>
                <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMNodeInserted</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element which is being inserted</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>:  parent node of the node that has been inserted, or the <code>ownerElement</code> in the case of <code>Attr</code> nodes</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event type when a node other than an <code>Attr</code> node has been added as a child of another node.  A <a class="def" href="#glossary-user-agent">user agent</a> may dispatch this event when an <code>Attr</code> node has been added to an <code>Element</code> node (see <a href="#DOMNodeInserted-attr">note</a> below). This event must be dispatched after the insertion has taken place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the node being inserted.</p>
              <p class="note" id="DOMNodeInserted-attr"><strong>Note:</strong> for detecting attribute insertion, the <a href="#event-type-DOMAttrModified">DOMAttrModified</a> event type should be used instead.</p>
              <p class="warning" id="_36"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>

<!-- DOMNodeInsertedIntoDocument -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMNodeInsertedIntoDocument"><dfn>
                <a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument"><code>DOMNodeInsertedIntoDocument</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMNodeInsertedIntoDocument</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element which is being inserted</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>:  parent node of the node that has been inserted, or the <code>ownerElement</code> in the case of <code>Attr</code> nodes</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node has been inserted into a document, either through direct insertion of the node or insertion of a subtree in which it is contained; a <a class="def" href="#glossary-user-agent">user agent</a> may optionally treat an <code>Attr</code> node as part of an <code>Element</code>'s subtree. This event must be dispatched after the insertion has taken place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the node being inserted. If the node is being directly inserted, the event type <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> must occur before this event type.</p>
              <p class="warning" id="_39"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeInsertedIntoDocument"><code>DOMNodeInsertedIntoDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>


<!-- DOMNodeRemoved -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMNodeRemoved"><dfn>
                <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMNodeRemoved</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element which is being removed</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the parent node of the node being removed, or the <code>ownerElement</code> in the case of <code>Attr</code> nodes</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>

              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node other than an <code>Attr</code> node is being removed from its parent node.  A <a class="def" href="#glossary-user-agent">user agent</a> may dispatch this event when an <code>Attr</code> node is being removed from its <code>ownerElement</code> (see <a href="#DOMNodeRemoved-attr">note</a> below). This event must be dispatched before the removal takes place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the node being removed.</p>
              <p class="note" id="DOMNodeRemoved-attr"><strong>Note:</strong> for reliably detecting attribute removal, the <a href="#event-type-DOMAttrModified">DOMAttrModified</a> event type should be used instead.</p>
              <p class="warning" id="_37"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>

<!-- DOMNodeRemovedFromDocument -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMNodeRemovedFromDocument"><dfn>
                <a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument"><code>DOMNodeRemovedFromDocument</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMNodeRemovedFromDocument</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>No</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code>, <code>Attr</code>, <code>Text</code>, <code>Comment</code>, <code>CDATASection</code>, <code>DocumentType</code>, <code>EntityReference</code>, <code>ProcessingInstruction</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: element which is being removed</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the parent node of the node being removed, or the <code>ownerElement</code> in the case of <code>Attr</code> nodes</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event when a node is being removed from a document, either through direct removal of the node or removal of a subtree in which it is contained; a <a class="def" href="#glossary-user-agent">user agent</a> may optionally treat an <code>Attr</code> node as part of an <code>Element</code>'s subtree. This event must be dispatched before the removal takes place. The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event type must be the node being removed. If the node is being directly removed, the event type <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> must occur before this event type.</p>
              <p class="note" id="DOMNodeRemovedFromDocument-attr"><strong>Note:</strong> for reliably detecting attribute removal, the <a href="#event-type-DOMAttrModified">DOMAttrModified</a> event type should be used instead.</p>
              <p class="warning" id="_38"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMNodeRemovedFromDocument"><code>DOMNodeRemovedFromDocument</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>


<!-- DOMSubtreeModified -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMSubtreeModified"><dfn>
                <a class="eventtype" href="#event-type-DOMSubtreeModified"><code>DOMSubtreeModified</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMSubtreeModified</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationEvent"><code>MutationEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><a class="def" href="#glossary-defaultView"><code>defaultView</code></a>, <code>Document</code>, <code>DocumentFragment</code>, <code>Element</code>, <code>Attr</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: parent node of subtree being modified</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                    </ul>
                  </td>
                </tr>
              </table>

              <p>This is a general event for notification of all changes to the document. It can be used instead of the more specific mutation and mutation name events. It may be dispatched after a single modification to the document or, at the implementation's discretion, after multiple changes have occurred. The latter case should generally be used to accommodate multiple changes which occur either simultaneously or in rapid succession. The target of this event must be the lowest common parent of the changes which have taken place. This event must be dispatched after any other events caused by the mutation(s) have occurred.</p>
              <p class="warning" id="_35"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMSubtreeModified"><code>DOMSubtreeModified</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>

      </div>
<!-- div3 Events-eventgroupings-mutationevents -->
      <div>
        <h3><a id="events-mutationnameevents" href="#events-mutationnameevents">5.2.9 Mutation Name Event Types</a></h3>

        <p>This module defines the feature MutationNameEvents 3.0 and depends on the features MutationEvents 3.0 and Core 3.0.</p>
        <p class="warning" id="_46"><strong>Warning!</strong>  The <code>MutationNameEvent</code> interface, introduced in an earlier draft of this specification, derives from the <a href="#events-mutationevents"><code>MutationEvent</code></a> interface, which is deprecated in this specification.  Thus, this specification describes the mutation name event types for completeness, but <a class="def" href="#glossary-deprecated">deprecates</a> their use.</p>
        <dl>
          <dt><strong>Interface <em><a id="events-MutationNameEvent">MutationNameEvent</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)</dt>
          <dd>
            <p>The <code>MutationNameEvent</code> interface provides specific contextual information associated with Mutation name event types.</p>
            <p>To create an instance of the <code>MutationNameEvent</code> interface, use the <code>Document.createEvent("MutationNameEvent")</code> method call.</p>
            <dl>
              <dt>
                <br />
                <strong>IDL Definition</strong>
              </dt>
              <dd>
                <pre class="idl" id="idl-interface-MutationNameEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-MutationNameEvent">MutationNameEvent</a> : <a href="#events-MutationEvent">MutationEvent</a> {
  readonly attribute DOMString       <a href="#events-MutationNameEvent-prevNamespaceURI">prevNamespaceURI</a>;
  readonly attribute DOMString       <a href="#events-MutationNameEvent-prevNodeName">prevNodeName</a>;
  // Introduced in DOM Level 3:
  void                               <a href="#events-event-type-initMutationNameEvent">initMutationNameEvent</a>(in DOMString typeArg, 
                                                           in boolean canBubbleArg, 
                                                           in boolean cancelableArg, 
                                                           in Node relatedNodeArg, 
                                                           in DOMString prevNamespaceURIArg, 
                                                           in DOMString prevNodeNameArg);
};
                </code></pre>
              </dd>

              <dt><strong>Attributes</strong></dt>
              <dd>
                <dl>
                  <dt><code class="attribute-name"><a id="events-MutationNameEvent-prevNamespaceURI">prevNamespaceURI</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p>The previous value of the <code>relatedNode</code>'s <code>namespaceURI</code>.</p></dd>

                  <dt><code class="attribute-name"><a id="events-MutationNameEvent-prevNodeName">prevNodeName</a></code> of type <code>DOMString</code>, readonly</dt>
                  <dd><p>The previous value of the <code>relatedNode</code>'s <code>nodeName</code>.</p></dd>

                </dl>
              </dd>

              <dt><strong>Methods</strong></dt>
              <dd>
                <dl>
                  <dt><code class="method-name"><a id="events-event-type-initMutationNameEvent">initMutationNameEvent</a></code> introduced in <strong class="since">DOM Level 3</strong></dt>
                  <dd>
                    <div class="method">
                      <p>Initializes attributes of a <code>MutationNameEvent</code> object. This method has the same behavior as <a href="#events-event-type-initMutationEvent"><code>MutationEvent.initMutationEvent()</code></a>.</p>
                      <div class="parameters">
                        <strong>Parameters</strong>
                        <div class="paramtable">
                          <dl>
                            <dt><code class="parameter-name">typeArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initMutationEvent"><code>MutationEvent.initMutationEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">canBubbleArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initMutationEvent"><code>MutationEvent.initMutationEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">cancelableArg</code> of type <code>boolean</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initMutationEvent"><code>MutationEvent.initMutationEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">relatedNodeArg</code> of type <code>Node</code></dt>
                            <dd><p>Refer to the <a href="#events-event-type-initMutationEvent"><code>MutationEvent.initMutationEvent()</code></a> method for a description of this parameter.</p></dd>
                            
                            <dt><code class="parameter-name">prevNamespaceURIArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-MutationNameEvent-prevNamespaceURI"><code>MutationNameEvent.prevNamespaceURI</code></a>. This value may be the <a class="def" href="#glossary-empty-string">empty string</a>.</p></dd>
                            
                            <dt><code class="parameter-name">prevNodeNameArg</code> of type <code>DOMString</code></dt>
                            <dd><p>Specifies <a href="#events-MutationNameEvent-prevNodeName"><code>MutationNameEvent.prevNodeName</code></a>.</p></dd>
                          </dl>
                        </div>
                      </div>
                      <!-- parameters -->
                      <div><strong>No Return Value</strong></div>

                      <div><strong>No Exceptions</strong></div>
                    </div>
<!-- method -->
                  </dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <p>The mutation name event types are listed below.</p>

<!-- DOMElementNameChanged -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMElementNameChanged"><dfn>
                <a class="eventtype" href="#event-type-DOMElementNameChanged"><code>DOMElementNameChanged</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMElementNameChanged</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>: <code>Element</code>  being renamed</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: <code>null</code></li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationNameEvent-prevNamespaceURI"><code class="attribute-name">MutationNameEvent.prevNamespaceURI</code></a>: the element's previous <a class="def" href="#glossary-namespaceURI">namespace URI</a></li>
                      <li><a href="#events-MutationNameEvent-prevNodeName"><code class="attribute-name">MutationNameEvent.prevNodeName</code></a>:  the element's previous name</li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after the <code>namespaceURI</code> and/or the <code>nodeName</code> of an <code>Element</code> node have been modified (e.g., the element was renamed using <code>Document.renameNode()</code>). The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the renamed <code>Element</code> node.</p>
              <p class="warning" id="_47"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMElementNameChanged"><code>DOMElementNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>

<!-- DOMAttributeNameChanged -->
        <div class="event-definition assert must">
          <dl>
            <dt id="event-type-DOMAttributeNameChanged"><dfn>
                <a class="eventtype" href="#event-type-DOMAttributeNameChanged"><code>DOMAttributeNameChanged</code></a>
              </dfn></dt>
            <dd>
              <table border="0" summary="This table contains information about the semantics of the given event type" cellpadding="2" cellspacing="0">
                <tr class="assert must"><th>Type</th><td class="eventname"><strong><code>DOMAttributeNameChanged</code></strong></td></tr>
                <tr class="assert must"><th>Interface</th> <td><a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a></td></tr>
                <tr class="assert must"><th>Sync / Async</th> <td>Sync</td></tr>
                <tr class="assert must"><th>Bubbles</th> <td>Yes</td></tr>
                <tr class="assert must"><th>Target</th> <td><code>Element</code></td></tr>
                <tr class="assert must"><th>Cancelable</th> <td>No</td></tr>
                <tr class="assert must"><th>Default action</th> <td>none</td></tr>
                <tr class="assert must"><th>Context info</th>
                  <td>
                    <ul>
                      <li><a href="#events-event-type-target"><code class="attribute-name">Event.target</code></a>:  <code>Element</code> whose <code>Attr</code> node has been renamed</li>
                      <li><a href="#events-MutationEvent-attrName"><code class="attribute-name">MutationEvent.attrName</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-attrChange"><code class="attribute-name">MutationEvent.attrChange</code></a>: <code>0</code></li>
                      <li><a href="#events-MutationEvent-relatedNode"><code class="attribute-name">MutationEvent.relatedNode</code></a>: the renamed <code>Attr</code> node</li>
                      <li><a href="#events-MutationEvent-newValue"><code class="attribute-name">MutationEvent.newValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationEvent-prevValue"><code class="attribute-name">MutationEvent.prevValue</code></a>: the <a class="def" href="#glossary-empty-string">empty string</a></li>
                      <li><a href="#events-MutationNameEvent-prevNamespaceURI"><code class="attribute-name">MutationNameEvent.prevNamespaceURI</code></a>: the <code>Attr</code> node's previous <a class="def" href="#glossary-namespaceURI">namespace URI</a></li>
                      <li><a href="#events-MutationNameEvent-prevNodeName"><code class="attribute-name">MutationNameEvent.prevNodeName</code></a>: the <code>Attr</code> node's previous name</li>
                    </ul>
                  </td>
                </tr>
              </table>
              
              <p>A <a class="def" href="#glossary-user-agent">user agent</a> must dispatch this event after the <code>namespaceURI</code> and/or the <code>nodeName</code> of a <code>Attr</code> node have been modified (e.g., the attribute was renamed using <code>Document.renameNode()</code>). The <a class="def" href="#glossary-proximal-event-target">proximal event target</a> of this event must be the <code>Element</code> node whose <code>Attr</code> has been renamed.</p>
              <p class="warning" id="_48"><strong>Warning!</strong> the <a class="eventtype" href="#event-type-DOMAttributeNameChanged"><code>DOMAttributeNameChanged</code></a> event type is defined in this specification for reference and completeness, but this specification <a class="def" href="#glossary-deprecated">deprecates</a> the use of this event type.</p>
            </dd>
          </dl>
        </div>
      </div>
<!-- div3 Events-eventgroupings-mutationnameevents -->
    </div>
<!-- div1 Events -->
    <div>
      <h2><a id="keys" href="#keys">6. Keyboard events and key values</a></h2>

      <p>This section contains necessary information regarding keyboard events:</p>
      <ul>
        <li>Explanation of keyboard layout, mapping, and key values.</li>
        <li>Relations between keys, such as <a class="def" href="#glossary-dead-key">dead keys</a> or modifiers keys.</li>
        <li>Relations between keyboard events, their default actions, and text events.</li>
        <li>The set of key values, and guidelines on how to extend this set.</li>
      </ul>
      <p class="note" id="_49"><strong>Note:</strong> This section uses Serbian and Kanji characters which may be misrepresented or unavailable in the PDF version or printed version of this specification.</p>
      <div>
        <h3><a id="keyboard-input" href="#keyboard-input">6.1 Keyboard Input</a></h3>

        <p><em>This section is informative</em></p>
        <p>The relationship of each key to the complete keyboard has three separate aspects, each of which vary among different models and configurations of keyboards, particularly for locale-specific reasons:</p>
        <ul>
          <li><strong>Visual markings:</strong> the labels (or <em>legends</em>) that mark each key</li>
          <li><strong>Mechanical layout:</strong> the dimensions, size, and placement of the physical keys on the keyboard</li>
          <li><strong>Functional mapping:</strong> the abstract key-value association of each key.</li>
        </ul>
        <p>This specification only defines the functional mapping, in terms of <a href="#keys-keyvalues">key values</a>, but briefly describes <a href="#key-legends">key legends</a> and <a href="#keyboard-layout">keyboard layout</a> for background.</p>
        <h4><a id="key-legends" href="#key-legends">6.1.1 Key Legends</a></h4>

        <p><em>This section is informative</em></p>
        <p>The visual markings normally consist of one or more characters which a keystroke on that key will produce (such as <code class="value">'F'</code>, <code class="value">'8'</code>, or <code class="value">'ш'</code>), or names or symbols which indicate that key's function (such as an upward-pointing arrow &#x21E7; indicating <code class="value">'Shift'</code>, or the string <code class="value">'Enter'</code>).  Keys are often referred to by this marking (e.g., “Press the <code class="value">'Shift'</code> and <code class="value">'F'</code> keys.”).  However, the visual appearance of the key has no bearing on its digital representation, and in many configurations may be completely inaccurate; even the control and function keys, such as <code class="value">'Enter'</code>, may be mapped to different functionality, or even mapped as character keys.</p>
        <p>For historical reasons, the character keys are typically marked with the capital-letter equivalents of the character value they produce, e.g., the <code class="value">'F'</code> key (the key marked with the glyph <code class="value">'F'</code>), will produce the character value <code class="value">'f'</code> when pressing without an active modifier key (<code class="value">'Shift'</code>) or modifier state (<code class="value">'CapsLock'</code>).</p>
        <p>Note that the key legends for function keys do not normally produce any characters, although the symbol may have a Unicode equivalent; for example, the <code class="value">'Shift'</code> key might bear the symbol &#x21E7;, which has the <a class="def" href="#glossary-unicode-code-point">Unicode code point</a> <code class="value">'21E7'</code>, but pressing the <code class="value">'Shift'</code> key will not produce this character value, and there is no <a class="def" href="#glossary-unicode-code-point">Unicode code point</a> for <code class="value">'Shift'</code>.</p>
        <h4><a id="keyboard-layout" href="#keyboard-layout">6.1.2 Keyboard Layout</a></h4>

        <p><em>This section is informative</em></p>
        <p>As with the key labels, the physical layout of the keys on the keyboard does not not affect the digital key value for any given key.  It is outside the scope of this specification to provide key values based on keyboard layout, particularly since there are so many possible layouts for a keyboard, and since users can change the mapping of keys in their operating system, e.g., by selecting a Dvorak <a class="def" href="#glossary-key-mapping">key mapping</a>.</p>
        <p>To illustrate the concept of keyboard layout mappings and its relation with keyboard events and key values, on the same keyboard (a PC/AT US keyboard), pressing the key labeled <code>Q</code> (with no modifier key activated) will produce different key values based on the mapping.  With a typical US <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard layout mapping, it will produce the character <code class="value">'q'</code> (<code class="value">U+0071</code>, Latin Small Letter Q).  If the keyboard layout mapping is switched to a French mapping, pressing the same key will produce the character <code class="value">'a'</code> (<code class="value">U+0041</code>, Latin Capital Letter A).  If the keyboard layout mapping is switched to a Serbian (Cyrillic) mapping, pressing the same key will produce the character <code class="value">'&#x459;'</code> (<code class="value">U+0459</code>, Cyrillic Small Letter LJE).</p>
        <p>However, the physical layout of the keys may be of interest to content authors developing games or other applications in which the location of the keys has an ergonomic relationship as the desired user interface controls, with little or no attention paid to the representational value of the key itself.  For example, many games might use the keys <code class="value">'A'</code>, <code class="value">'S'</code>, <code class="value">'D'</code>, and <code class="value">'W'</code> for <code class="value">'left'</code>, <code class="value">'down'</code>, <code class="value">'right'</code>, and <code class="value">'up'</code> respectively.  Content authors should provide a means for the user to assign such controller keys to a custom setting appropriate to their keyboard configurations.  Implementations may provide a means for the user to more comprehensively map the keyboard to their customized keyboard layout, but this is beyond the scope of this specification.</p>
        <p class="note" id="_60"><strong>Note:</strong> Key values should not be confused with <em>scan codes</em>, which are the low-level hexadecimal signals produced for each key by the keyboard driver software, and which are mapped at the operating system to a <acronym title="Virtual Key">VK</acronym> ("virtual key"), which in turn may be mapped to the user-defined key configuration.  Key values are a high-level abstraction of that final mapping.</p>
        
        <div id="keyboard-desktop-section">
          <h5><a id="keyboard-desktop" href="#keyboard-desktop">6.1.2.1 Desktop and Laptop Keyboards</a></h5>

          <p>In the case where a content author wishes to rely on the mechanical layout of a desktop or laptop keyboard, this specification suggests the keyboard configuration specified in ISO/IEC 9995, parts 2 and 3 [<cite><a class="informative" href="#references-ISO-9995-2-3">ISO-9995-2/3</a></cite>], which defines a common layout for primary, secondary, and auxiliary <a class="def" href="#glossary-key-mapping">key mappings</a> on a typical alphanumeric keyboard, as a common layout appropriate to some international uses.</p>
          <p class="note" id="_51"><strong>Note:</strong> This keyboard layout is still, in essence, a <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard, and will not match the keyboards or configurations of many users.  Content authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
          <div id="figure-keyboard" class="figure" style="text-align: center">
            <object type="image/svg+xml" data="images/ISOIEC-9995-3-FCD-2009A.svg" width="900" height="300">
              <img src="images/ISOIEC-9995-3-FCD-2009A.png" alt="A graphical depiction of an ISO standard defining layouts of computer keyboards, ISO/IEC 9995, parts 2 and 3" />
            </object>
            <p style="text-align:left">
              <em>Figure 3: A graphical depiction of an ISO standard defining layouts of computer keyboards, ISO 9995, parts 2 and 3</em>
            </p>
          </div>
        </div>
        

        <div id="keyboard-mobile-section">

          <div id="figure-numberpad" class="figure" style="float:right; width:220px; margin:0px 20px 0px 20px;">
            <object type="image/svg+xml" data="images/ISOIEC-9995-8-2006.svg" width="180" height="240">
              <img src="images/ISOIEC-9995-8-2006.png" alt="A graphical depiction of an ISO standard defining layouts of numeric keypads, with distribution of letters on the keys, ISO/IEC 9995-8:2006" />
            </object>
            <p style="text-align:left">
              <em>Figure 4: A graphical depiction of an ISO standard defining layouts of numeric keypads, with distribution of letters on the keys, ISO/IEC 9995-8:2006</em>
            </p>
          </div>

          <h5><a id="keyboard-mobile" href="#keyboard-mobile">6.1.2.2 Mobile Keypads</a></h5>

          <p>In the case where a content author wishes to rely on the mechanical layout of a mobile keypad, this specification suggests the keyboard configuration specified in ISO/IEC 9995-8:2006 [<cite><a class="informative" href="#references-ISO-9995-8">ISO-9995-8</a></cite>], which defines a numeric keypad layout and secondary assignment of Unicode characters in the range <abbr title="a-z">\u0061..\u007A</abbr> to the number keys <code>2</code> through <code>9</code>, as a common layout appropriate to some international uses.</p>
          <p class="note" id="_52"><strong>Note:</strong> This keypad layout, and in particular the distribution of letters is for English devices, and will not match the keypads or configurations of many users.  Content authors cannot rely upon any particular configuration, and should create content in an internationalized and localizable manner.</p>
        </div>
        
        
        <div id="remote-control-section" style="clear:right;">

          <div id="figure-remotecontrol" class="figure" style="float:right; width:220px; margin:0px 20px 0px 20px;">
            <object type="image/svg+xml" data="images/remote-control.svg" width="102" height="422">
              <img src="images/remote-control.png" alt="A graphical depiction of a media remote control, with buttons mapped to specific keys values" />
            </object>
            <p style="text-align:left">
              <em>Figure 5: A graphical depiction of a media remote control, with buttons mapped to specific keys values</em>
            </p>
          </div>

          <h5><a id="remote-control" href="#remote-control">6.1.2.3 Media Remote Controls</a></h5>

          <p>Many keyboards contain special keys to control media functions.  Increasingly, many media devices, especially televisions, are Web-enabled.  Hybrid keyboard/remote-control devices are becoming more common.  To meet the needs of these hybrid Web/media devices, this specification defines keys that are common as remote control buttons, in addition to traditional keyboard keys.</p>
          
          <p>Because of the smaller form factor, keys (or buttons) on a remote control will often be modal, with one key performing different functions based on the context of the on-screen content.  Additionally, many keys serve as toggles, to change back and forth between two or more states (see toggling keys).</p>
          
          <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
        </div>
        
        
        <div style="clear:right;">
          <h5><a id="keyboard-chording-virtual" href="#keyboard-chording-virtual">6.1.2.4 Virtual Keyboards and Chording Keyboards</a></h5>

          <p>Virtual keyboards are software-based sets of keys, in a variety of different arrangements, commonly found on touch-screen devices; they are often modal, with the ability to switch between different dynamic sets of keys, such as alphabetic, numeric, or symbolic keys.  Because of the lack of physical constraints, these keyboards may present the widest range of characters, including emoticons and other symbols, and may have keys not represented by Unicode [<a href="#references-Unicode">Unicode</a>] or by the <a href="#key-values">key values set</a> defined in this specification.  Wherever possible, however, virtual keyboards should produce the normal range of keyboard events and values, for ease of authoring and compatibility with existing content.</p>
        
          <p>Chording keyboards, also know as chorded keysets or chord keyboards, are key input devices which produce values by pressing several keys in combination or sequence, normally to simulate a full range of characters or commands on a reduced set of keys, often for single-handed use.  A chording keyboard may have additional mode keys to switch between key values, and the number and type of keys pressed to produce a key value will vary, but the final key values produced by such keyboards should match the range of key values described in this specification.</p>
          
          <p>For these and other alternative modal keyboards, the key values <a href="#key-Alphanumeric"><code class="value keyname">'Alphanumeric'</code></a>, <a href="#key-CapsLock"><code class="value keyname">'CapsLock'</code></a>, <a href="#key-NumLock"><code class="value keyname">'NumLock'</code></a>, and <a href="#key-SymbolLock"><code class="value keyname">'SymbolLock'</code></a> are recommended for the keys which switch between different modes.</p>
        </div>

      </div>

      <div>
        <h3><a id="keys-keyvalues" href="#keys-keyvalues">6.2 Key Values</a></h3>

        <p>A key value is a <code>DOMString</code> that can be used to indicate any given key on a keyboard, regardless of position or state, by the value it produces.  These key values may be used as return values for keyboard events generated by the implementation, or as input values by the content author to specify desired input (such as for keyboard shortcuts).  This specification defines a set of common key values (called the <a href="#key-values">Key Values Set</a>), and rules for production of new key values.</p>
        
        <!-- <p class="issue" id="issue-keyvalues-textinput"><strong>Issue:</strong> Add mention of textinput and it's relationship to key values, per <a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0052.html">Ishida</a></p> -->
        <!-- It is therefore highly recommended to rely on <a href="#events-TextEvent">Text event types</a> when dealing with character input. -->
        
        <p>Key values can be used to detect the value of a key which has been pressed, using the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> or <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes.  Content authors can retrieve the <a class="def" href="#glossary-character-value">character value</a> of upper- or lower-case letters, number, symbols, or other character-producing keys, and also the <a class="def" href="#glossary-key-value">key value</a> of control keys, modifier keys, function keys, or other keys that do not generate characters; these values can be used for monitoring particular input strings, for detecting and acting on modifier key input in combination with other inputs (such as a mouse), for creating virtual keyboards, or for any number of other purposes.</p>
        <p>Key values can also be used by content authors in string comparisons, as values for markup attributes (such as the HTML <code>accesskey</code>) in conforming <a class="def" href="#glossary-host-language">host languages</a>, or for other related purposes.   A conforming <a class="def" href="#glossary-host-language">host language</a> should allow content authors to use either of the two equivalent string values for a key value: the <a class="def" href="#glossary-character-value">character value</a>, or the <a class="def" href="#glossary-key-value">key value</a>.</p>
        <!-- <p class="issue"><strong>Issue:</strong> mention that content author should use case-insensitive matching to capture both "t" and "T" for hotkeys, etc.?</p> -->
        <p class="note" id="_53"><strong>Note:</strong> While implementations are recommended to use the most relevant value for a key independently of the platform or keyboard layout mappings, content authors should not make assumption on the ability of keyboard devices to generate them.  When using keyboard events and key values for shortcut-key combinations, content authors should <q>consider using numbers and function keys (F4, F5, and so on) instead of letters</q> ([<cite><a class="informative" href="#references-DWW95">DWW95</a></cite>]) given that most keyboard layouts will provide keys for those.</p>
<!-- , and where the key used should default to the most appropriate key for the function, language, operating system, device, and other environmental factors (such as <code>ctrl+c</code> for copy operations) -->
        <p>It is important to note that a key value does not indicate a specific key on the physical keyboard, nor does it reflect the character printed on the key; a key value indicates the current value of the event with consideration to the current state of all active keys and key input modes (including shift modes and <a class="def" href="#glossary-dead-key">dead keys</a>), as reflected in the operating-system mapping of the keyboard and reported to the implementation.  In other words, the key value for the key marked <code>'O'</code> on a <a class="def" href="#glossary-qwerty">QWERTY</a> keyboard has the key value <code>'o'</code> in an unshifted state, <code>'O'</code> in a shifted state, <code>'&#xF6;'</code> in an unshifted state during a dead-key operation to add an umlaut diacritic, and <code>'&#xD6;'</code> in a shifted state during a dead-key operation to add an umlaut diacritic.  Because a user can map their keyboard to an arbitrary custom configuration, the content author is encouraged not to assume that a relationship exists between the shifted and unshifted states of a key and the majuscule form (uppercase or capital letters) and minuscule form (lowercase or small letters) of a character representation, but is encouraged instead to use the value of the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> or <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes.  The keyboard depicted in <a href="#figure-keyboard">Figure 3</a> illustrates one possible set of <a class="def" href="#glossary-key-mapping">key mappings</a> on one possible keyboard layout; many others exist, both standard and idiosyncratic.</p>
        <p>It is also important to note that there is not a one-to-one relationship between key event states and key values.  A particular key value might be associated with multiple keys; for example, many standard keyboards contain more than one key with the <code class="value">'Shift'</code> key value (normally distinguished by the <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> values <a href="#events-DOM_KEY_LOCATION_LEFT"><code class="constant-name">DOM_KEY_LOCATION_LEFT</code></a> and <a href="#events-DOM_KEY_LOCATION_RIGHT"><code class="constant-name">DOM_KEY_LOCATION_RIGHT</code></a>) or <code class="value">'8'</code> key value (normally distinguished by the <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> values <a href="#events-DOM_KEY_LOCATION_STANDARD"><code class="constant-name">DOM_KEY_LOCATION_STANDARD</code></a> and <a href="#events-DOM_KEY_LOCATION_NUMPAD"><code class="constant-name">DOM_KEY_LOCATION_NUMPAD</code></a>), and user-configured custom keyboard layouts may duplicate any key value in multiple key-state scenarios (note that <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> is intended for standard keyboard layouts, and cannot always indicate a meaningful distinction).</p>

        <p>Similarly, a given key event state may have different key values.  For most keys which represent characters, such as the letter <code>'m'</code> or the question mark (<code>'?'</code>), the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> and <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes will be the same.  However, for <em>printing control characters</em>, such as the backspace/back key, the <em>character value</em> is distinct from the <em>key value</em>, with different values for the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> and <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes; see the <a href="#key-values">Key Values Set</a> for more details.  Certain keys in some states, called <em>modifier keys</em> or <em>control keys</em>, have only a <a class="def" href="#glossary-key-value">key value</a> and no <a class="def" href="#glossary-character-value">character value</a>, such as the volume mute key, which has the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute value <code class="value">'VolumeMute'</code> and the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute value the <a class="def" href="#glossary-empty-string">empty string</a>.</p>
        
        <p>Finally, the meaning of any given character representation is context-dependent and complex.  For example, in some contexts, the asterisk (star) glyph (<code class="value">'*'</code>) represents a footnote or emphasis (when bracketing a passage of text); however, in some documents or executable programs it is equivalent to the mathematical multiplication operation, while in other documents or executable programs, that function is reserved for the multiplication symbol (<code class="value">'&#xD7;'</code>, Unicode value <code class="value">U+00D7</code>) or the Latin small letter <code class="value">'x'</code> (due to the lack of a multiplication key on many keyboards and the superficial resemblance of the glyphs <code class="value">'&#xD7;'</code> and <code class="value">'x'</code>).  Thus, the semantic meaning or function of character representations is outside the scope of this specification.</p>
        
        <div>
          <h4><a id="keys-unicode" href="#keys-unicode">6.2.1 Key Values and Unicode</a></h4>

          <p>The <a class="def" href="#glossary-character-value">character values</a> described in this specification are Unicode [<a href="#references-Unicode">Unicode</a>] codepoints, and as such, have certain advantages.</p>
          <p>The most obvious advantage is that it allows the content author to use the full range of internationalized language functionality available in the implementation, regardless of the limitations of the text input devices on the system.  This opens up possibilities for virtual keyboards and Web-application-based <a class="def" href="#glossary-ime">input method editors</a>.</p>
          <p>Another benefit is that it allows the content author to utilize the Unicode general category properties <!-- <a class="def" href="#glossary-Unicode-character-categories">Unicode character categories</a> --> programmatically.</p>
          <p>With legacy keyboard event attributes such as <code class="attr-name">keyCode</code> and <code class="attr-name">charCode</code>, content authors are forced to filter key input using cryptic, platform- and implementation-specific numeric codes, with poor internationalization, such as the following pseudocode:</p>
          <div class="example" id="example-keyCode_charCode">
            <p><strong>Example:</strong></p>
            <pre><code>
  
  if ( ( event.charCode == 45 || event.charCode == 36 ) ||
       ( event.charCode &gt;= 48 &amp;&amp; event.charCode &lt;= 57 ) || 
       ( event.charCode &gt;= 96 &amp;&amp; event.charCode &lt;= 105 ) ) {
    <em>// minus sign, dollar sign, and numeric characters from keyboard and numpad</em>
    <em>...</em> 
  }
  else if ( ( event.charCode &gt;= 65 &amp;&amp; event.charCode &lt;= 90 ) || 
            ( event.charCode &gt;= 97 &amp;&amp; event.charCode &lt;= 122 ) ) {
    <em>// alphabetic characters from Latin character set, A-Z, a-z</em>
    <em>...</em> 
  }
  else {
    <em>...</em> 
  } 
            </code></pre>
          </div>
          <p>With key values and regular expressions, however, content authors can support selective and intuitive ranges for key-based input, in a cross-platform manner with advanced internationalization support, such as the following pseudocode:</p>
          <div class="example" id="example-regex">
            <p><strong>Example:</strong></p>
            <pre><code>
  if ( event.key == "-" || 
       event.key.match("\p{Sc}") || 
       event.key.match("\p{N}") ) {
    <em>// minus sign, any currency symbol, and numeric characters (regardless of key location)</em>
    <em>...</em> 
  }
  else if ( event.key.match("\p{L}") ) {
    <em>// alphabetic characters from any language, upper and lower case</em>
    <em>...</em> 
  }
  else {
    <em>...</em> 
  } 
            </code></pre>
          </div>
          <p>In addition, because Unicode categorizes each assigned <a class="def" href="#glossary-unicode-code-point">code point</a> into a group of code points used by a particular human writing system, even more advanced capabilities are possible.  For example, a content author can match characters from a particular human script (e.g., Tibetan) using a regular expression such as <code class="example inline">\p{Tibetan}</code>, to filter out other characters, or discover if a <a class="def" href="#glossary-unicode-code-point">code point</a> is in a certain code block (range of code points), using a regular expression like <code class="example inline">\p{InCyrillic}</code>.</p>
          <p>To facilitate this, implementations should support Unicode range detection using regular expressions, in a manner such as the Perl Compatible Regular Expressions (PCRE) [<a href="#references-pcre">PCRE</a>].</p>
        </div>

        <div>
          <h4><a id="keys-Modifiers" href="#keys-Modifiers">6.2.2 Modifier keys</a></h4>

          <p>Keyboard input uses modifier keys to change the normal behavior of a key.  Like other keys, modifier keys generate <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events, as shown in the example below. Some modifiers are activated while the key is being pressed down or maintained pressed such as <code class="value">'Alt'</code>, <code class="value">'Control'</code>, <code class="value">'Shift'</code>, <code class="value">'AltGraph'</code>, or <code class="value">'Meta'</code>. Others modifiers are activated depending on their state such as <code class="value">'CapsLock'</code>, <code class="value">'NumLock'</code>, or <code class="value">'Scroll'</code>. Change in the state happens when the modifier key is being pressed down. The <a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a> interface provides convenient attributes for some common modifiers keys: <a href="#events-KeyboardEvent-ctrlKey"><code>KeyboardEvent.ctrlKey</code></a>, <a href="#events-KeyboardEvent-shiftKey"><code>KeyboardEvent.shiftKey</code></a>, <a href="#events-KeyboardEvent-altKey"><code>KeyboardEvent.altKey</code></a>, <a href="#events-KeyboardEvent-metaKey"><code>KeyboardEvent.metaKey</code></a>. Some operating systems simulate the <code class="value">'AltGraph'</code> modifier key with the combination of the <code>"Alt</code> and <code class="value">'Control'</code> modifier keys. Implementations are encouraged to use the <code class="value">'AltGraph'</code> modifier key.</p>
          <p>The following example describes a possible sequence of events associated with the generation of the Unicode character Q (Latin Capital Letter Q, <a class="def" href="#glossary-unicode-code-point">Unicode code point</a> <code class="value">U+0051</code>) on a PC/AT US keyboard using a US mapping:</p>
          <!-- <p class="issue" id="issue-keyset-Modifiers-example"><strong>Issue:</strong> Reformat example as table with "Event",   "Returned value", and "Keys involved", per <a href="http://lists.w3.org/Archives/Public/www-dom/2010JanMar/0052.html">Ishida</a>?</p> -->
          <div class="example" id="example-keyvalue_Q">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Shift'</code>, <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'Q'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Shift'</code></li>
            </ol>
          </div>
          <p>The following example describes an alternate sequence of keys to the example above, where the <code class="value">'Shift'</code> key is released before the <code class="value">'Q'</code> key.  The key value for the key labeled <code class="value">'Q'</code> will revert to its unshifted value for the <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event, after the production of the <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event, thus:</p>
          <div class="example" id="example-keyvalue_Q_keyup">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Shift'</code>, <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'Q'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Shift'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'q'</code> (<code class="value">U+0071</code>, Latin Small Letter Q key)</li>
            </ol>
          </div>
          <p>The following example describes a possible sequence of keys that does not generate a Unicode character (using the same configuration):</p>
          <div class="example" id="example-Keyvalue_noUnicode">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Control'</code>, ctrlKey</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'v'</code> (<code class="value">U+0076</code>, Latin Small Letter V key), ctrlKey</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>:  <code class="value">'v'</code> (<code class="value">U+0076</code>, Latin Small Letter V key), ctrlKey</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Control'</code></li>
            </ol>
          </div>
          <p>In some cases, modifier keys change the key value value for a key event.  For example, on some MacOS keyboards, the  key labeled <code class="value">'delete'</code> functions the same as the <code class="value">'Backspace'</code> key on the Windows OS when unmodified, but when modified by the <code class="value">'Fn'</code> key, acts as the <code class="value">'Del'</code> key, and the value of the key value will match the most appropriate function of the key in its current modified state.</p>
        </div>
<!-- div3 Modifiers -->
        <div>
          <h4><a id="keys-DeadKeys" href="#keys-DeadKeys">6.2.3 Dead keys</a></h4>

          <p>Some keyboard input uses <a class="def" href="#glossary-dead-key">dead keys</a> for the input of composed character sequences. Unlike the handwriting sequence, in which users enter the base character first, keyboard input requires to enter a special state when a <a class="def" href="#glossary-dead-key">dead key</a> is pressed and emit the character(s) only when one of a limited number of “legal” base character is entered.  (NOTE: the MacOS and Linux operating systems use input methods to process <a class="def" href="#glossary-dead-key">dead keys</a>.)</p>
          <p>The <a class="def" href="#glossary-dead-key">dead keys</a> are represented in the key values set using combining diacritical marks.   While Unicode combining characters always follow the handwriting sequence, with the combining character trailing the corresponding letter, typical deadkey input may reverse the sequence, with the combining character before the corresponding letter; for example, the word <em>naïve</em>, using the combining diacritic <em>¨</em>, would be represented sequentially in Unicode as <em>nai¨ve</em>, but may be typed <em>na¨ive</em>.  The sequence of keystrokes <code>'\u0302'</code> (Combining Circumflex Accent key) and <code>'\u0065'</code> (key marked with the Latin Small Letter E) will likely produce (on a PC/AT french keyboard using a french mapping and without any modifier activated) the Unicode character &#xEA; (Latin Small Letter E With Circumflex), as preferred by the Unicode Normalization Form <em>NFC</em>:</p>
          <div class="example" id="example-deadkey">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'ê'</code> (<code class="value">U+00EA</code>, LATIN SMALL LETTER E WITH CIRCUMFLEX) 
                <br />
                <i class="note" id="note-key-intercept"><strong>Note:</strong> the key value will not be <code class="value">'e'</code> (Latin Small Letter E key) under normal circumstances, because the value delivered to the user agent will already be modified by the dead key operation.</i>
                <br />
                <!-- <i class="issue" id="issue-key-intercept"><strong>Issue:</strong> is this correct for the case of composition events?</i> -->
              </li>
              <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>: <code class="value">'ê'</code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'ê'</code> (<code>"inputMethod"</code>: <code class="value">'DOM_INPUT_METHOD_IME'</code>)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'e'</code> (<code class="value">U+0065</code>, Latin Small Letter E key)</li>
            </ol>
          </div>
          <p>This process might be aborted when a user types an unsupported base character (that is, a base character for which the which the active diacritical mark is not available) after pressing a <a class="def" href="#glossary-dead-key">dead key</a>:</p>
          <div class="example" id="example-deadkey_abort">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">\u0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'q'</code> (<code class="value">U+0071</code>, The Latin Small Letter Q key)</li>
              <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>: <code class="value">''</code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'q'</code> (<code>"inputMethod"</code>: <code class="value">'DOM_INPUT_METHOD_KEYBOARD'</code>)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'q'</code> (<code class="value">U+0071</code>, The Latin Small Letter Q key)</li>
            </ol>
          </div>
        </div>
<!-- div3 DeadKeys -->
        <div>
          <h4><a id="keys-IME" href="#keys-IME">6.2.4 Input Method Editors</a></h4>

          <p>This specification includes a model for <a class="def" href="#glossary-ime">input method editors (IMEs)</a>, through the <a href="#events-compositionevents">CompositionEvent</a> interface and events.  However, composition events and keyboard events do not necessarily map as a one-to-one relationship.  As an example, receiving a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> for the <a href="#key-Accept"><code class="value keyname">'Accept'</code></a> key value does not necessarily imply that the text currently selected in the <a class="def" href="#glossary-ime">IME</a> is being accepted, but indicates only that a keystroke happened, disconnected from the <a class="def" href="#glossary-ime">IME</a> Accept functionality (which would normally result in a <a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a> event in most <a class="def" href="#glossary-ime">IME</a> systems).  Keyboard events cannot be used to determine the current state of the input method editor, which can be obtained through the <a href="#events-CompositionEvent-data"><code>data</code></a> attribute of the <a href="#events-compositionevents">CompositionEvent</a> interface.  Additionally, <a class="def" href="#glossary-ime">IME</a> systems and devices vary in their functionality, and in which keys are used for activating that functionality, such that the <code class="value">'Convert'</code> and <code class="value">'Accept'</code> keys may be represented by other available keys.</p>
          <p>Keyboard events correspond to the events generated by the input device after the keyboard layout mapping but before the processing of the input method editor.</p>
          <p>The following example describes a possible sequence of keys to generate the Unicode character &#x5E02; (Kanji character, part of CJK Unified Ideographs) using Japanese input methods. This example assumes that the input method editor is activated and in the Japanese-Romaji input mode. The keys <code class="value">'Convert'</code> and <code class="value">'Accept'</code> may be replaced by others depending on the input device in use and the configuration of the IME, e.g., it can be respectively <code class="value">U+0020</code> (Space key) and <code class="value">'Enter'</code>. <span class="note" id="_54"><strong>Note:</strong><code class="value">'&#x8A69;'</code> ("poem") and <code class="value">'&#x5E02;'</code> ("city") are homophones, both pronounced “shi”, so the user would use the <code class="value">'Convert'</code> key to select the proper option.</span></p>
          <div class="example" id="example-compo">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'s'</code> (<code class="value">U+0073</code>, Latin Small Letter S key)</li>
              <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>: <code class="value">''</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'s'</code> (<code class="value">U+0073</code>, Latin Small Letter S key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'i'</code> (<code class="value">U+0069</code>, Latin Small Letter I key)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'i'</code> (<code class="value">U+0069</code>, Latin Small Letter I key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'&#x8A69;'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'&#x5E02;'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Accept'</code></li>
              <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>: <code class="value">'&#x5E02;'</code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'&#x5E02;'</code> (<code>"inputMethod"</code>: <code class="value">'DOM_INPUT_METHOD_IME'</code>)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Accept'</code></li>
            </ol>
          </div>
          <p>IME composition can also be canceled as in the following example, with conditions identical to the previous example.  The key <a href="#key-Cancel"><code class="value keyname">'Cancel'</code></a> might also be replaced by others depending on the input device in use and the configuration of the IME, e.g., it could be "\u001B" (Escape key).</p>
          <div class="example" id="example-compo_cancel">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'s'</code> (<code class="value">U+0073</code>, Latin Small Letter S key)</li>
              <li><a class="eventtype" href="#event-type-compositionstart"><code>compositionstart</code></a>: <code class="value">''</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'s'</code> (<code class="value">U+0073</code>, Latin Small Letter S key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'i'</code> (<code class="value">U+0069</code>, Latin Small Letter I key)</li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'i'</code> (<code class="value">U+0069</code>, Latin Small Letter I key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'&#x8A69;'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">'&#x5E02;'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Convert'</code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Cancel'</code></li>
              <li><a class="eventtype" href="#event-type-compositionupdate"><code>compositionupdate</code></a>: <code class="value">''</code></li>
              <li><a class="eventtype" href="#event-type-compositionend"><code>compositionend</code></a>: <code class="value">''</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Cancel'</code></li>
            </ol>
          </div>
          <p>NOTE: Some <a class="def" href="#glossary-ime">input method editors</a> (such as on the MacOS operating system) might set an <a class="def" href="#glossary-empty-string">empty string</a> to the composition data attribute before canceling a composition.</p>
          <h5><a id="keys-IME_keys" href="#keys-IME_keys">6.2.4.1 Input Method Editor mode keys</a></h5>

          <p>Some keys on certain devices are intended to activate <a class="def" href="#glossary-ime">input method editor</a> functionality, or to change the mode of an active <a class="def" href="#glossary-ime">input method editor</a>.  Custom keys for this purpose can be defined for different devices or language modes; the keys defined in this specification for this purpose are: <code>Alphanumeric</code>, <code>CodeInput</code>, <code>FinalMode</code>, <code>HangulMode</code>, <code>HanjaMode</code>, <code>Hiragana</code>, <code>JapaneseHiragana</code>, <code>JapaneseKatakana</code>, <code>JapaneseRomaji</code>, <code>JunjaMode</code>, <code>KanaMode</code>, <code>KanjiMode</code>, <code>Katakana</code>, and <code>RomanCharacters</code>.  When one of these keys is pressed, and no <a class="def" href="#glossary-ime">IME</a> is currently active, the appropriate <a class="def" href="#glossary-ime">IME</a> is expected to be activated in the mode indicated by the key (if available); if an <a class="def" href="#glossary-ime">IME</a> is already active when the key is pressed, the active <a class="def" href="#glossary-ime">IME</a> might change to the indicated mode, or a different <a class="def" href="#glossary-ime">IME</a> might be launched, or the might may be ignored, on a device- and application-specific basis.</p>
          <p>This specification also defines other keys which are intended for operation specifically with <a class="def" href="#glossary-ime">input method editors</a>: <code>Accept</code>, <code>AllCandidates</code>, <code>Cancel</code>, <code>Convert</code>, <code>Compose</code>, <code>FullWidth</code>, <code>HalfWidth</code>, <code>NextCandidate</code>, <code>Nonconvert</code>, and <code>PreviousCandidate</code>.  The functions of these keys are not defined in this specification; refer to other resources for details on <a class="def" href="#glossary-ime">input method editor</a> functionality.</p>
          <p>Note that keys with <a class="def" href="#glossary-ime">input method editor</a> functions are not restricted to that purpose, and may have other device- or implementation-specific purposes, as well.</p>
        </div>
<!-- div3 IME -->
        <div>
          <h4><a id="keys-cancelable_keys" href="#keys-cancelable_keys">6.2.5 Default actions and cancelable keyboard events</a></h4>

          <p>Canceling the <a class="def" href="#glossary-default-action">default action</a> of a <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event must not affect its respective <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event, but it must prevent the respective <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event from being generated. The following example describes a possible sequence of keys to generate the Unicode character Q (Latin Capital Letter Q) on a PC/AT US keyboard using a US mapping:</p>
          <div class="example" id="example-cancel_keys">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Shift'</code>, <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li>
                <em>The <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event is prevented, e.g., by invoking <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> during the dispatch of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event object</em>
              </li>
              <li>
                <em>No <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> event is generated</em>
              </li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Shift'</code></li>
            </ol>
          </div>
          <p>If the key is a modifier key, the keystroke must still be taken into account for the modifiers states. The following example describes a possible sequence of keys to generate the Unicode character Q (Latin Capital Letter Q) on a PC/AT US keyboard using a US mapping:</p>
          <div class="example" id="example-cancel_mod">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Shift'</code>, <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li>
                <em>The <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event is prevented, e.g., by invoking <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> during the dispatch of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event object</em>
              </li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'Q'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Q'</code> (<code class="value">U+0051</code>, Latin Capital Letter Q key), <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Shift'</code></li>
            </ol>
          </div>
          <!-- <p class="issue"><strong>Issue:</strong> does this make sense? shouldn't the shift modifier attribute be canceled? needs testing...</p> -->
<!-- <p>If the key is a modifier key, the keystroke must not be taken into account for the modifiers states. The following example describes a possible sequence of keys to generate the Unicode character Q (Latin Capital Letter Q) on a PC/AT US keyboard using a US mapping:</p>
          <ol>
            <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'Shift'</code>, <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
            <li><em>The <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event is prevented, e.g., by invoking <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> during the dispatch of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event object</em></li>
            <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'q'</code> (<code class="value">U+0071</code>, Latin Small Letter Q key), no <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
            <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'q'</code></li>
            <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'q'</code> (<code class="value">U+0071</code>, Latin Small Letter Q key), no <code class="attribute-name"><a href="#events-MouseEvent-shiftKey">shiftKey</a></code></li>
            <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'Shift'</code></li>
          </ol> -->
          <p>If the key is part of a sequence of several keystrokes, whether it is a <a class="def" href="#glossary-dead-key">dead key</a> or it is contributing to an Input Method Editor sequence, the keystroke must be ignored (not taken into account) only if the <a class="def" href="#glossary-default-action">default action</a> is canceled on the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event. Canceling a <a class="def" href="#glossary-dead-key">dead key</a> on a <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> event has no effect on <a class="eventtype" href="#event-type-textinput"><code>textinput</code></a> events. The following example uses the keystrokes <code class="value">U+0302</code> (Combining Circumflex Accent key) and the key marked <code class="value">'e'</code> (<code class="value">U+0065</code>, Latin Small Letter E key) (on a PC/AT french keyboard using a french mapping and without any modifier activated):</p>
          LATIN SMALL LETTER E WITH ACUTE' (U+00E9)
          <div class="example" id="example-default_action_cancel">
            <p><strong>Example:</strong></p>
            <ol>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">U+0302</code> (Combining Circumflex Accent key)</li>
              <li>
                <em>The <a class="def" href="#glossary-default-action">default action</a> of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event is prevented, e.g., by invoking <a href="#events-event-type-preventDefault"><code>Event.preventDefault()</code></a> during the dispatch of the <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> event object</em>
              </li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">U+0302</code> (Combining Circumflex Accent key)</li>
              <li><a class="eventtype" href="#event-type-keydown"><code>keydown</code></a>: <code class="value">'é'</code> (<code class="value">U+00E9</code>, LATIN SMALL LETTER E WITH ACUTE)</li>
              <li><a class="eventtype" href="#event-type-textinput"><code>textinput</code></a>: <code class="value">'é'</code></li>
              <li><a class="eventtype" href="#event-type-keyup"><code>keyup</code></a>: <code class="value">'é'</code></li>
            </ol>
          </div>
        </div>
<!-- div3 cancelable_keys -->
        <div>
          <h4><a id="keys-Guide" href="#keys-Guide">6.2.6 Guidelines for selecting and defining key values</a></h4>

          <p class="note" id="_55"><strong>Note:</strong> This section is normative.</p>
          <p>The list of key values contained in this specification is not exhaustive, and input devices may have to define their own key values. Consider the current function of the key (i.e., with modifiers), taking into consideration the keyboard layout mapping in use, to determine if the key is represented by the set of defined key values, if a corresponding Unicode character exists from which a key value may be derived, or if a new key value must be defined.  The following algorithm determines the <em>key value</em> and <em>character value</em> to use:</p>
          
    			<ol class="algo" id="key-algorithm">
    			  <li>If the primary current function of the key is to generate a character, then:
    					<ol class="algo">
    					  <li>If there exists an appropriate character in the <a href="#keys-keyvalues">key values set</a>, then:
    					    <ol class="algo">
    					      <li>the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute must be a string consisting of the <em>key value</em> of that character; and</li>
    					      <li>the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute must be a string consisting of the <em>char value</em> of that character.</li>
    					    </ol>
                </li>

                <li>If there is no appropriate key value in the <a href="#keys-keyvalues">key values set</a>, and there exists an appropriate <a class="def" href="#glossary-unicode-code-point">Unicode code point</a>, then:
                  <ol class="algo">
    					      <li>the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute must be a string consisting of the <em>char value</em> of that character; and</li>
    					      <li>the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute must be a string consisting of the <em>char value</em> of that character.</li>
    					    </ol>
                </li>
      					  
                <!-- <li>If there is no appropriate key value in the <a href="#keys-keyvalues">key values set</a>, and no appropriate <a class="def" href="#glossary-unicode-code-point">Unicode code point</a> exists, then... uh, are you sure this is meant to produce a character?</li> -->
              </ol>
    				</li>
            <li>If the primary current function of the key is to serve as a function key, then:
    					<ol class="algo">
    					  <li>If there exists an appropriate key value in the <a href="#keys-keyvalues">key values set</a>, then:
                  <ol class="algo">
    					      <li>the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute must be a string consisting of the <em>key value</em> of that character; and</li>
    					      <li>the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute must be the <a class="def" href="#glossary-empty-string">empty string</a>.</li>
    					    </ol>
                </li>

    					    
                <li>If there is no appropriate key value in the <a href="#keys-keyvalues">key values set</a>, then a key value must be devised.  The key value should be as human friendly as possible and must not contain whitespace characters.  The value must be composed only of characters in the ranges <abbr title="0-9">\u0030..\u0039</abbr>, <abbr title="A-Z">\u0041..\u005A</abbr>, or <abbr title="a-z">\u0061..\u007A</abbr>, and must begin with a character in the range <abbr title="A-Z">\u0041..\u005A</abbr>.</li>

              </ol>
    				</li>
    			</ol>
          <!-- <p class="note" id="change-algo-examples"><strong>To Do:</strong> Update the algorithm example to match the change in the algorithm.</p> -->
            
          <div class="example" id="example-keyvalues">
            <p><strong>Examples:</strong></p>
            <ul>
              <li>On a PC/AT US keyboard with a right-handed single-hand Dvorak <a class="def" href="#glossary-key-mapping">key mapping</a>, the key labeled <code class="value">'Q'</code> maps to the key values <code class="value">'5'</code> (unmodified) and <code class="value">'%'</code> (shifted).  The primary function of this key is to generate the character <code class="value">'5'</code> (<code class="value">U+0035</code>).  Since this character is a character (in Unicode general category <abbr title="Number, Decimal Digit">Nd</abbr>), the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> and <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute values for the unmodified key will be <code class="value">'5'</code>.</li>
              <li>On a French PC keyboard with a standard French mapping, the primary function of the <code class="value">'^'</code> key is as a <a class="def" href="#glossary-dead-key">dead key</a> for the circumflex diacritical mark.  This corresponds to the combining Unicode character <code class="value">U+0302</code>.  Since this character is in general category <abbr title="Mark, Nonspacing">Mn</abbr>, the key value will be <code class="value">U+0302</code>.</li>
              <li>On a Korean PC keyboard with a standard Korean mapping, the primary function of the <code class="value">'Ha/En'</code> key is to switch between Hangul and English input.  The predefined key value list has an appropriate entry for this key, <code class="value">'HangulMode'</code>, so this will be the key value.</li>
              <li>On some models of mobile devices, the primary function of the key with a picture of a calendar on it is to launch the calendaring program. Since there is no Unicode character that corresponds to this function, and there is no appropriate entry in the predefined key value list, a new value can be devised, such as <code class="value">'Calendar'</code>.</li>
            </ul>
          </div>

        </div>
                

        <div>
          <h4><a id="key-values" href="#key-values">6.2.7 Key Values Set</a></h4>

          <p>This section defines a list of key values which implementations must support, at a minimum, in addition to support for the full range of Unicode [<a href="#references-Unicode">Unicode</a>] codepoints.  Implementations may support additional key values, in a manner conforming to the <a href="#keys-Guide">guidelines for selecting and defining key values</a>.  Each key value defines one or both of the following: a <a class="def" href="#glossary-character-value">character value</a> and a <a class="def" href="#glossary-key-value">key value</a>.  The <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute of an event must always contain one of these control key or character values (even if the value is <a href="#key-Unidentified"><code class="value keyname">'Unidentified'</code></a>), and the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute must have a value if the key represents a printable character.  If the key represents one of the set of printable control characters which has a Unicode character entry, such as the tab key, the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attribute must have the key value (e.g., <a href="#key-Tab"><code class="value keyname">'Tab'</code></a>), while the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attribute must have the Unicode character value equivalent (e.g., <a href="#key-U-0009"><code class="value charval">\u0009</code></a>).  This affords content authors the opportunity to deal with the key as a control key or as direct input into the text stream.</p>
          <!-- <p>Resource-constrained implementations may support only a subset of these key values which are appropriate to that implementation.</p>  -->
          <p>Implementations that are unable to identify a key must use the key value <a href="#key-Unidentified"><code class="value keyname">'Unidentified'</code></a>.  <span class="warning" id="_64"><strong>Warning!</strong> Conforming implementations must only use this key value when there is no way for the implementation to detect the key value; exposing only this value must not indicate a conforming implementation.</span></p>
          
          <p>The <a class="def" href="#glossary-key-value">key values</a> defined in this specification are based in part on the sets of keycodes from the <code>java.awt.event.KeyEvent</code> interface of the Java Platform, Standard Edition 6 API Specification [<cite><a class="informative" href="#references-KeyEvent">KeyEvent for Java</a></cite>], and the <code>System.Windows.Forms.Keys</code> key enumeration of the Microsoft .NET Framework 4.0 Class Library [<cite><a class="informative" href="#references-Keys">Keys enumeration for .Net</a></cite>]; 
            
            the key values for media controllers (e.g. remote controls for television, audio systems, and set-top boxes) are derived in part from the consumer electronics technical specifications DTV Application Software Environment [<cite><a href="#references-DASE">DASE</a></cite>], Open Cable Application Platform 1.1.3 [<cite><a href="#references-OCAP">OCAP</a></cite>], and ANSI/CEA-2014-B, Web-based Protocol and Framework for Remote User Interface on UPnPTM Networks and the Internet [<cite><a href="#references-WEB4CE">WEB4CE</a></cite>].
            
            The <a class="def" href="#glossary-character-value">character values</a> defined in this specification are derived from the Unicode standard [<a href="#references-Unicode">Unicode</a>].</p>
          
          <p class="note" id="_56"><strong>Note:</strong> The key names <code class="value">'NumPad0'</code>, <code class="value">'NumPad1'</code>, <code class="value">'NumPad2'</code>, <code class="value">'NumPad3'</code>, <code class="value">'NumPad4'</code>, <code class="value">'NumPad5'</code>, <code class="value">'NumPad6'</code>, <code class="value">'NumPad7'</code>, <code class="value">'NumPad8'</code>, and <code class="value">'NumPad9'</code>, found in some keyboard enumeration sets, are not distinguished from other numerical key values in this set; a content author may use the <a href="#events-KeyboardEvent-location"><code>KeyboardEvent.location</code></a> attribute to discover if a key originated from the numeric keypad.</p>
          <p>Future versions of this specification may include key values not included here, which have become common since the publication of this specification.</p>
<!-- <p>Javascript escaped characters may have issues because they are based on UTF-16 encoding, in that it uses surrogate pairs for values outside the Basic Multilingual Plane.</p> -->

          <p>In the following list, character values for printing control characters are described as a character escape, for convenience, using the JavaScript notation for escapes.</p>
          
          <div id="js-escape" class="note">
            <p><strong>Note:</strong> There are special internationalization considerations for ECMAScript escaped characters.  CharMod conformance [<cite><a class="normative" href="#references-charmod">CharMod</a></cite>] <a href="http://www.w3.org/TR/charmod/#C045">expects</a> the use of code points rather than surrogate pairs in escapes; ECMAScript escaped characters use surrogate pairs for characters outside the Basic Multilingual Plane ("\uD84E\uDDC2" for &#x239C2;, a Chinese character meaning “untidy”), rather than C-style fixed-length characters ("\U000239c2" for &#x239C2;) or delimited escapes such as Numeric Character References ("&amp;#x239C2;").  Characters escaped in this manner:</p>
            <ul>
              <li>are based on UTF-16 encoding, in that it uses surrogate pairs for values outside the Basic Multilingual Plane</li>
              <li>are expressed using surrogate pairs, which makes it difficult for a human to look up the value, and may require unnecessary overhead for machine processing; this can also cause problems with software written in the incorrect belief that Unicode is a 16-bit character set</li>
              <li>are problematic for characters on supplementary planes (emoji, or Chinese characters on plane 2), some of which may be expected to be input using a keyboard</li>
              <li>may not be suitable for Java or C, which use different escaping mechanisms (could be solved with a normalizing method)</li>
            </ul>
          </div>
          
          <h5 id="key-values-legend">6.2.7.1 Key Values Legend</h5>
          <p>In the <a href="#key-values-list">Key Values List</a>, the following conventions apply:</p>
          <ul>
            <li>Key values are denoted with a <code class="value keyname">blue background</code>, and are the first term in a set</li>
            <li>Character values, where present, are denoted with a <code class="value charval">green background</code>, and follow the key value.</li>
          </ul>
          
          
          <h5 id="key-values-list">6.2.7.2 Key Values List</h5>
          <p>The following list contains the normative list of case-sensitive key values, their character values (where applicable), a non-normative description of typical usage, and a non-normative categorization.  A conforming implementation of the <a href="#events-KeyboardEvent">KeyboardEvent</a> interface must support at least this set of values for use in the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> and <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attributes, though not all values may be available on all platforms or devices.</p>
          <div>
            <table class="data-table" id="table-key-values" summary="">
              <tr>
                <th>Key</th>
                <th>Char</th>
                <th>Typical Usage (Informative)</th>
                <th>Category (Informative)</th>
              </tr>

              <tr>
                <td><code id="key-Attn" class="value keyname">'Attn'</code></td>
                <td> </td>
                <td>The Attention (Attn) key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Apps" class="value keyname">'Apps'</code></td>
                <td> </td>
                <td>Toggle display of available (interactive) application list.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Crsel" class="value keyname">'Crsel'</code></td>
                <td> </td>
                <td>The Cursor Select (Crsel) key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Exsel" class="value keyname">'ExSel'</code></td>
                <td> </td>
                <td>The Extend Selection (ExSel) key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F1" class="value keyname">'F1'</code></td>
                <td> </td>
                <td>The F1 key, a general purpose function key, as index 1.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F2" class="value keyname">'F2'</code></td>
                <td> </td>
                <td>The F2 key, a general purpose function key, as index 2.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F3" class="value keyname">'F3'</code></td>
                <td> </td>
                <td>The F3 key, a general purpose function key, as index 3.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F4" class="value keyname">'F4'</code></td>
                <td> </td>
                <td>The F4 key, a general purpose function key, as index 4.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F5" class="value keyname">'F5'</code></td>
                <td> </td>
                <td>The F5 key, a general purpose function key, as index 5.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F6" class="value keyname">'F6'</code></td>
                <td> </td>
                <td>The F6 key, a general purpose function key, as index 6.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F7" class="value keyname">'F7'</code></td>
                <td> </td>
                <td>The F7 key, a general purpose function key, as index 7.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F8" class="value keyname">'F8'</code></td>
                <td> </td>
                <td>The F8 key, a general purpose function key, as index 8.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F9" class="value keyname">'F9'</code></td>
                <td> </td>
                <td>The F9 key, a general purpose function key, as index 9.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F10" class="value keyname">'F10'</code></td>
                <td> </td>
                <td>The F10 key, a general purpose function key, as index 10.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F11" class="value keyname">'F11'</code></td>
                <td> </td>
                <td>The F11 key, a general purpose function key, as index 11.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F12" class="value keyname">'F12'</code></td>
                <td> </td>
                <td>The F12 key, a general purpose function key, as index 12.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F13" class="value keyname">'F13'</code></td>
                <td> </td>
                <td>The F13 key, a general purpose function key, as index 13.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F14" class="value keyname">'F14'</code></td>
                <td> </td>
                <td>The F14 key, a general purpose function key, as index 14.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F15" class="value keyname">'F15'</code></td>
                <td> </td>
                <td>The F15 key, a general purpose function key, as index 15.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F16" class="value keyname">'F16'</code></td>
                <td> </td>
                <td>The F16 key, a general purpose function key, as index 16.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F17" class="value keyname">'F17'</code></td>
                <td> </td>
                <td>The F17 key, a general purpose function key, as index 17.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F18" class="value keyname">'F18'</code></td>
                <td> </td>
                <td>The F18 key, a general purpose function key, as index 18.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F19" class="value keyname">'F19'</code></td>
                <td> </td>
                <td>The F19 key, a general purpose function key, as index 19.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F20" class="value keyname">'F20'</code></td>
                <td> </td>
                <td>The F20 key, a general purpose function key, as index 20.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F21" class="value keyname">'F21'</code></td>
                <td> </td>
                <td>The F21 key, a general purpose function key, as index 21.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F22" class="value keyname">'F22'</code></td>
                <td> </td>
                <td>The F22 key, a general purpose function key, as index 22.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F23" class="value keyname">'F23'</code></td>
                <td> </td>
                <td>The F23 key, a general purpose function key, as index 23.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-F24" class="value keyname">'F24'</code></td>
                <td> </td>
                <td>The F24 key, a general purpose function key, as index 24.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-LaunchApplication1" class="value keyname">'LaunchApplication1'</code></td>
                <td> </td>
                <td>The Start Application One key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-LaunchApplication2" class="value keyname">'LaunchApplication2'</code></td>
                <td> </td>
                <td>The Start Application Two key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-LaunchMail" class="value keyname">'LaunchMail'</code></td>
                <td> </td>
                <td>The Start Mail key.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-List" class="value keyname">'List'</code></td>
                <td> </td>
                <td>Toggle display listing of currently available content or programs.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Props" class="value keyname">'Props'</code></td>
                <td> </td>
                <td>The properties (props) key.</td>
                <td class="category">General</td>
              </tr>
             <tr>
                <td><code id="key-Soft1" class="value keyname">'Soft1'</code></td>
                <td> </td>
                <td>General purpose virtual function key, as index 1.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Soft2" class="value keyname">'Soft2'</code></td>
                <td> </td>
                <td>General purpose virtual function key, as index 2.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Soft3" class="value keyname">'Soft3'</code></td>
                <td> </td>
                <td>General purpose virtual function key, as index 3.</td>
                <td class="category">General</td>
              </tr>
              <tr>
                <td><code id="key-Soft4" class="value keyname">'Soft4'</code></td>
                <td> </td>
                <td>General purpose virtual function key, as index 4.</td>
                <td class="category">General</td>
              </tr>


               <tr>
                 <td><code id="key-Accept" class="value keyname">'Accept'</code></td>
                 <td> </td>
                 <td>The Accept (Commit, OK) key. Accept current option or input method sequence conversion.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Again" class="value keyname">'Again'</code></td>
                 <td> </td>
                 <td>The Again key, to redo or repeat an action.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Enter" class="value keyname">'Enter'</code></td>
                 <td> </td>
                 <td>The Enter key, to activate current selection or accept current input.
                  <span class="note" id="_58"><strong>Note:</strong> This key value also must be used for the <code>Return</code> (Macintosh numpad) key.</span></td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Find" class="value keyname">'Find'</code></td>
                 <td> </td>
                 <td>The Find key.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Help" class="value keyname">'Help'</code></td>
                 <td> </td>
                 <td>Toggle display of help information.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Info" class="value keyname">'Info'</code></td>
                 <td> </td>
                 <td>Toggle display of information about currently selected context or media.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Menu" class="value keyname">'Menu'</code></td>
                 <td> </td>
                 <td>Toggle display of content or system menu, if available.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-ScrollLock" class="value keyname">'ScrollLock'</code></td>
                 <td> </td>
                 <td>The Scroll Lock key, to toggle between scrolling and cursor movement modes.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Execute" class="value keyname">'Execute'</code></td>
                 <td> </td>
                 <td>The Execute key.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Cancel" class="value keyname">'Cancel'</code></td>
                 <td><a id="key-U-0018"><code class="value charval">'\u0018'</code></a></td>
                 <td>The Cancel key.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Esc" class="value keyname">'Esc'</code></td>
                 <td><a id="key-U-001B"><code class="value charval">'\u001B'</code></a></td>
                 <td>The Escape (Esc) key, to initiate an escape sequence.</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Exit" class="value keyname">'Exit'</code></td>
                 <td> </td>
                 <td>Exit current state or current application (as appropriate).</td>
                 <td class="category">UI</td>
               </tr>
               <tr>
                 <td><code id="key-Zoom" class="value keyname">'Zoom'</code></td>
                 <td> </td>
                 <td>Toggle between full-screen and scaled content, or alter magnification level.</td>
                 <td class="category">UI</td>
               </tr>


               <tr>
                 <td><code id="key-Separator" class="value keyname">'Separator'</code></td>
                 <td> </td>
                 <td>The Separator key, for context-sensitive text separators.</td>
                 <td class="category">Character</td>
               </tr>
              <tr>
                <td><code id="key-Spacebar" class="value keyname">'Spacebar'</code></td>
                <td><a id="key-U-0020"><code class="value charval">'\u0020'</code></a></td>
                <td>The Space (Spacebar) key (<code class="value charrep">'&nbsp;'</code>).</td>
                <td class="category">Character</td>
              </tr>

              <tr>
                <td><code id="key-Add" class="value keyname">'Add'</code></td>
                <td><a id="key-U-002B"><code class="value charval">'\u002B'</code></a></td>
                <td>The Add key, or plus sign (<code class="value charrep">'+'</code>).</td>
                <td class="category">Character / Math</td>
              </tr>
              <tr>
                <td><code id="key-Subtract" class="value keyname">'Subtract'</code></td>
                <td><a id="key-U-2212"><code class="value charval">'\u2212'</code></a></td>
                <td>The Subtract key, or minus sign (<code class="value charrep">'−'</code>).</td>
                <td class="category">Character / Math</td>
              </tr>
              <tr>
                <td><code id="key-Multiply" class="value keyname">'Multiply'</code></td>
                <td><a id="key-U-002A"><code class="value charval">'\u002A'</code></a></td>
                <td>The Multiply key, or multiplication sign (<code class="value charrep">'*'</code>).
                  <span class="note" id="note-Multiply"><strong>Note:</strong> This key value may be represented by different characters depending on context, including <code class="value charval">'\u002A' (ASTERISK, '*')</code> or <code id="key-U-00D7" class="value charval">'\u00D7' (MULTIPLICATION SIGN, '×')</code>.</span>
                </td>
                <td class="category">Character / Math</td>
              </tr>
              <tr>
                <td><code id="key-Divide" class="value keyname">'Divide'</code></td>
                <td><a id="key-U-00F7"><code class="value charval">'\u00F7'</code></a></td>
                <td>The Divide key, or division sign (<code class="value charrep">'÷'</code>).</td>
                <td class="category">Character / Math</td>
              </tr>
              <tr>
                <td><code id="key-Equals" class="value keyname">'Equals'</code></td>
                <td><a id="key-U-003D"><code class="value charval">'\u003D'</code></a></td>
                <td>The Equals key, or equals sign (<code class="value charrep">'='</code>).</td>
                <td class="category">Character / Math</td>
              </tr>
              <tr>
                <td><code id="key-Decimal" class="value keyname">'Decimal'</code></td>
                <td><a id="key-U-2396"><code class="value charval">'\u2396'</code></a></td>
                <td>The Decimal key, or decimal separator key symbol (<code class="value charrep">'.'</code>).  
                  <span class="note" id="note-decimal"><strong>Note:</strong> This key value may be represented by different characters due to localization, such as <code id="key-U-002E" class="value charval">'\u002E' (FULL STOP, '.')</code> or <code id="key-U-00B7" class="value charval">'\u00B7' (MIDDLE DOT, '·')</code>.</span>
                </td>
                <td class="category">Character / Math</td>
              </tr>

              <tr>
                <td><code id="key-BrightnessDown" class="value keyname">'BrightnessDown'</code></td>
                <td> </td>
                <td>The Brightness Down key.  Typically controls the display brightness.</td>
                <td class="category">Device</td>
              </tr>
              <tr>
                <td><code id="key-BrightnessUp" class="value keyname">'BrightnessUp'</code></td>
                <td> </td>
                <td>The Brightness Up key.  Typically controls the display brightness.</td>
                <td class="category">Device</td>
              </tr>
              <tr>
                <td><code id="key-Camera" class="value keyname">'Camera'</code></td>
                <td> </td>
                <td>The Camera key.</td>
                <td class="category">Device</td>
              </tr>
              <tr>
                <td><code id="key-Eject" class="value keyname">'Eject'</code></td>
                <td> </td>
                <td>Toggle removable media to eject (open) and insert (close) state.</td>
                <td class="category">Device</td>
              </tr>
              <tr>
                <td><code id="key-Power" class="value keyname">'Power'</code></td>
                <td> </td>
                <td>Toggle power state.
                 <span class="note" id="note-key-power"><strong>Note:</strong> Some devices may not expose this key to the operating environment.</span></td>
                <td class="category">Device</td>
              </tr>
              <tr>
                <td><code id="key-PrintScreen" class="value keyname">'PrintScreen'</code></td>
                <td> </td>
                <td>The Print Screen (PrintScrn, SnapShot) key, to initiate print-screen function.</td>
                <td class="category">Device</td>
              </tr>

              <tr>
                <td><code id="key-BrowserFavorites" class="value keyname">'BrowserFavorites'</code></td>
                <td> </td>
                <td>The Browser Favorites key.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-BrowserHome" class="value keyname">'BrowserHome'</code></td>
                <td> </td>
                <td>The Browser Home key, used with keyboard entry, to go to the home page.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-BrowserRefresh" class="value keyname">'BrowserRefresh'</code></td>
                <td> </td>
                <td>The Browser Refresh key.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-BrowserSearch" class="value keyname">'BrowserSearch'</code></td>
                <td> </td>
                <td>The Browser Search key.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-BrowserStop" class="value keyname">'BrowserStop'</code></td>
                <td> </td>
                <td>The Browser Stop key.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-HistoryBack" class="value keyname">'HistoryBack'</code></td>
                <td> </td>
                <td>Navigate to previous content or page in current history.</td>
                <td class="category">Browser</td>
              </tr>
              <tr>
                <td><code id="key-HistoryForward" class="value keyname">'HistoryForward'</code></td>
                <td> </td>
                <td>Navigate to next content or page in current history.</td>
                <td class="category">Browser</td>
              </tr>


              <tr>
                <td><code id="key-Left" class="value keyname">'Left'</code></td>
                <td> </td>
                <td>The left arrow key, to navigate or traverse leftward.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-PageDown" class="value keyname">'PageDown'</code></td>
                <td> </td>
                <td>The Page Down key, to scroll down or display next page of content.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-PageUp" class="value keyname">'PageUp'</code></td>
                <td> </td>
                <td>The Page Up key, to scroll up or display previous page of content.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-Right" class="value keyname">'Right'</code></td>
                <td> </td>
                <td>The right arrow key, to navigate or traverse rightward.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-Up" class="value keyname">'Up'</code></td>
                <td> </td>
                <td>The up arrow key, to navigate or traverse upward.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-UpLeft" class="value keyname">'UpLeft'</code></td>
                <td> </td>
                <td>The diagonal up-left arrow key, to navigate or traverse diagonally up and to the left.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-UpRight" class="value keyname">'UpRight'</code></td>
                <td> </td>
                <td>The diagonal up-right arrow key, to navigate or traverse diagonally up and to the right.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-Down" class="value keyname">'Down'</code></td>
                <td> </td>
                <td>The down arrow key, to navigate or traverse downward.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-DownLeft" class="value keyname">'DownLeft'</code></td>
                <td> </td>
                <td>The diagonal down-left arrow key, to navigate or traverse diagonally down and to the left.</td>
                <td class="category">Navigation</td>
              </tr>
              <tr>
                <td><code id="key-DownRight" class="value keyname">'DownRight'</code></td>
                <td> </td>
                <td>The diagonal down-right arrow key, to navigate or traverse diagonally down and to the right.</td>
                <td class="category">Navigation</td>
              </tr>


              <tr>
                <td><code id="key-Home" class="value keyname">'Home'</code></td>
                <td> </td>
                <td>The Home key, used with keyboard entry, to go to start of content.</td>
                <td class="category">Edit / Navigation</td>
              </tr>
              <tr>
                <td><code id="key-End" class="value keyname">'End'</code></td>
                <td> </td>
                <td>The End key, used with keyboard entry to go to the end of content.</td>
                <td class="category">Edit / Navigation</td>
              </tr>
              <tr>
                <td><code id="key-Select" class="value keyname">'Select'</code></td>
                <td> </td>
                <td>The Select key.</td>
                <td class="category">Edit / Navigation</td>
              </tr>
              <tr>
                <td><code id="key-Tab" class="value keyname">'Tab'</code></td>
                <td><a id="key-U-0009"><code class="value charval">'\u0009'</code></a></td>
                <td>The Horizontal Tabulation (Tab) key.</td>
                <td class="category">Edit / Navigation</td>
              </tr>


              <tr>
                <td><code id="key-Clear" class="value keyname">'Clear'</code></td>
                <td> </td>
                <td>The Clear key, for removing current selected input.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Copy" class="value keyname">'Copy'</code></td>
                <td> </td>
                <td>The Copy key.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Cut" class="value keyname">'Cut'</code></td>
                <td> </td>
                <td>The Cut key.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Del" class="value keyname">'Del'</code></td>
                <td><a id="key-U-007F"><code class="value charval">'\u007F'</code></a></td>
                <td>The Delete (Del) Key. <span class="note" id="_63"><strong>Note:</strong> This key value also must be used for the key labeled <code class="value">'delete'</code> MacOS keyboards when modified by the <code class="value">'Fn'</code> key.</span></td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-EraseEof" class="value keyname">'EraseEof'</code></td>
                <td> </td>
                <td>The Erase to End of Field key.  This key deletes all characters from the current cursor position to the end of the current field.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Insert" class="value keyname">'Insert'</code></td>
                <td> </td>
                <td>The Insert (Ins) key, to toggle between text modes for insertion or overtyping.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Paste" class="value keyname">'Paste'</code></td>
                <td> </td>
                <td>The Paste key.</td>
                <td class="category">Edit</td>
              </tr>
              <tr>
                <td><code id="key-Undo" class="value keyname">'Undo'</code></td>
                <td> </td>
                <td>The Undo key.</td>
                <td class="category">Edit</td>
              </tr>


              <tr>
                <td><code id="key-DeadGrave" class="value keyname">'DeadGrave'</code></td>
                <td><a id="key-U-0300"><code class="value charval">'\u0300'</code></a></td>
                <td>The Combining Grave Accent (Greek Varia, Dead Grave) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadEacute" class="value keyname">'DeadEacute'</code></td>
                <td><a id="key-U-0301"><code class="value charval">'\u0301'</code></a></td>
                <td>The Combining Acute Accent (Stress Mark, Greek Oxia, Tonos, Dead Eacute) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadCircumflex" class="value keyname">'DeadCircumflex'</code></td>
                <td><a id="key-U-0302"><code class="value charval">'\u0302'</code></a></td>
                <td>The Combining Circumflex Accent (Hat, Dead Circumflex) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadTilde" class="value keyname">'DeadTilde'</code></td>
                <td><a id="key-U-0303"><code class="value charval">'\u0303'</code></a></td>
                <td>The Combining Tilde (Dead Tilde) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadMacron" class="value keyname">'DeadMacron'</code></td>
                <td><a id="key-U-0304"><code class="value charval">'\u0304'</code></a></td>
                <td>The Combining Macron (Long, Dead Macron) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadBreve" class="value keyname">'DeadBreve'</code></td>
                <td><a id="key-U-0306"><code class="value charval">'\u0306'</code></a></td>
                <td>The Combining Breve (Short, Dead Breve) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadAboveDot" class="value keyname">'DeadAboveDot'</code></td>
                <td><a id="key-U-0307"><code class="value charval">'\u0307'</code></a></td>
                <td>The Combining Dot Above (Derivative, Dead Above Dot) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadUmlaut" class="value keyname">'DeadUmlaut'</code></td>
                <td><a id="key-U-0308"><code class="value charval">'\u0308'</code></a></td>
                <td>The Combining Diaeresis (Double Dot Abode, Umlaut, Greek Dialytika, Double Derivative, Dead Diaeresis) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadAboveRing" class="value keyname">'DeadAboveRing'</code></td>
                <td><a id="key-U-030A"><code class="value charval">'\u030A'</code></a></td>
                <td>The Combining Ring Above (Dead Above Ring) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadDoubleacute" class="value keyname">'DeadDoubleacute'</code></td>
                <td><a id="key-U-030B"><code class="value charval">'\u030B'</code></a></td>
                <td>The Combining Double Acute Accent (Dead Doubleacute) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadCaron" class="value keyname">'DeadCaron'</code></td>
                <td><a id="key-U-030C"><code class="value charval">'\u030C'</code></a></td>
                <td>The Combining Caron (Hacek, V Above, Dead Caron) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadCedilla" class="value keyname">'DeadCedilla'</code></td>
                <td><a id="key-U-0327"><code class="value charval">'\u0327'</code></a></td>
                <td>The Combining Cedilla (Dead Cedilla) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadOgonek" class="value keyname">'DeadOgonek'</code></td>
                <td><a id="key-U-0328"><code class="value charval">'\u0328'</code></a></td>
                <td>The Combining Ogonek (Nasal Hook, Dead Ogonek) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadIota" class="value keyname">'DeadIota'</code></td>
                <td><a id="key-U-0345"><code class="value charval">'\u0345'</code></a></td>
                <td>The Combining Greek Ypogegrammeni (Greek Non-Spacing Iota Below, Iota Subscript, Dead Iota) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadVoicedSound" class="value keyname">'DeadVoicedSound'</code></td>
                <td><a id="key-U-3099"><code class="value charval">'\u3099'</code></a></td>
                <td>The Combining Katakana-Hiragana Voiced Sound Mark (Dead Voiced Sound) key.</td>
                <td class="category">Composition</td>
              </tr>
              <tr>
                <td><code id="key-DeadSemivoicedSound" class="value keyname">'DeadSemivoicedSound'</code></td>
                <td><a id="key-U-309A"><code class="value charval">'\u309A'</code></a></td>
                <td>The Combining Katakana-Hiragana Semi-Voiced Sound Mark (Dead Semivoiced Sound) key.</td>
                <td class="category">Composition</td>
              </tr>

              <tr>
                <td><code id="key-Alphanumeric" class="value keyname">'Alphanumeric'</code></td>
                <td> </td>
                <td>The Alphanumeric key.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Alt" class="value keyname">'Alt'</code></td>
                <td> </td>
                <td>The Alternative (Alt, Option, Menu) key.  Enable alternate modifier function for interpreting concurrent or subsequent keyboard input.
                  <span class="note" id="note-alt-key"><strong>Note:</strong> This key value is also used for the Apple <code>'Option'</code> key.</span>
                </td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-AltGraph" class="value keyname">'AltGraph'</code></td>
                <td> </td>
                <td>The Alt-Graph key.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-CapsLock" class="value keyname">'CapsLock'</code></td>
                <td> </td>
                <td>The Caps Lock (Capital) key.  Toggle capital character lock function for interpreting subsequent keyboard input event.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Control" class="value keyname">'Control'</code></td>
                <td> </td>
                <td>The Control (Ctrl) key, to enable control modifier function for interpreting concurrent or subsequent keyboard input.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Fn" class="value keyname">'Fn'</code></td>
                <td> </td>
                <td>The Function switch (Fn) key.  Activating this key simultaneously with another key changes that key's value to an alternate character or function.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-FnLock" class="value keyname">'FnLock'</code></td>
                <td> </td>
                <td>The Function-Lock (FnLock, F-Lock) key.  Activating this key switches the mode of the keyboard to changes some keys' values to an alternate character or function.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Meta" class="value keyname">'Meta'</code></td>
                <td> </td>
                <td>The Meta key, to enable meta modifier function for interpreting concurrent or subsequent keyboard input.
                  <span class="note" id="note-meta-key"><strong>Note:</strong> This key value is also used for the Apple <code>'Command'</code> key.</span>
                </td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Process" class="value keyname">'Process'</code></td>
                <td> </td>
                <td>The Process key.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-NumLock" class="value keyname">'NumLock'</code></td>
                <td> </td>
                <td>The Number Lock key, to toggle numer-pad mode function for interpreting subsequent keyboard input.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Shift" class="value keyname">'Shift'</code></td>
                <td> </td>
                <td>The Shift key, to enable shift modifier function for interpreting concurrent or subsequent keyboard input.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-SymbolLock" class="value keyname">'SymbolLock'</code></td>
                <td> </td>
                <td>The Symbol Lock key.</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-OS" class="value keyname">'OS'</code></td>
                <td> </td>
                <td>The operating system key (e.g. the "Windows Logo" key).</td>
                <td class="category">Modifier</td>
              </tr>
              <tr>
                <td><code id="key-Compose" class="value keyname">'Compose'</code></td>
                <td> </td>
                <td>The Compose key, also known as <em>Multi_key</em> on the X Window System.  This key acts in a manner similar to a <a class="def" href="#glossary-dead-key">dead key</a>, triggering a mode where subsequent key presses are combined to produce a different character.</td>
                <td class="category">Modifier</td>
              </tr>

              <tr>
                <td><code id="key-AllCandidates" class="value keyname">'AllCandidates'</code></td>
                <td> </td>
                <td>The All Candidates key, to initate the multi-candidate mode.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-NextCandidate" class="value keyname">'NextCandidate'</code></td>
                <td> </td>
                <td>The Next Candidate function key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-PreviousCandidate" class="value keyname">'PreviousCandidate'</code></td>
                <td> </td>
                <td>The Previous Candidate function key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-CodeInput" class="value keyname">'CodeInput'</code></td>
                <td> </td>
                <td>The Code Input key, to initiate the Code Input mode to allow characters to be entered by their code points.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-Convert" class="value keyname">'Convert'</code></td>
                <td> </td>
                <td>The Convert key, to convert the current input method sequence.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-Nonconvert" class="value keyname">'Nonconvert'</code></td>
                <td> </td>
                <td>The Nonconvert (Don't Convert) key, to accept current input method sequence without conversion in IMEs.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-FinalMode" class="value keyname">'FinalMode'</code></td>
                <td> </td>
                <td>The Final Mode (Final) key used on some Asian keyboards, to enable the final mode for IMEs.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-FullWidth" class="value keyname">'FullWidth'</code></td>
                <td> </td>
                <td>The Full-Width Characters key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-HalfWidth" class="value keyname">'HalfWidth'</code></td>
                <td> </td>
                <td>The Half-Width Characters key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-Modechange" class="value keyname">'ModeChange'</code></td>
                <td> </td>
                <td>The Mode Change key, to toggle between or cycle through input modes of IMEs.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-RomanCharacters" class="value keyname">'RomanCharacters'</code></td>
                <td> </td>
                <td>The Roman Characters function key, also known as the <code>'Youngja'</code> or <code>'Young'</code> key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-HangulMode" class="value keyname">'HangulMode'</code></td>
                <td> </td>
                <td>The Hangul (Korean characters) Mode key, to toggle between Hangul and English modes.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-HanjaMode" class="value keyname">'HanjaMode'</code></td>
                <td> </td>
                <td>The Hanja (Korean characters) Mode key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-JunjaMode" class="value keyname">'JunjaMode'</code></td>
                <td> </td>
                <td>The Junja (Korean characters) Mode key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-Hiragana" class="value keyname">'Hiragana'</code></td>
                <td> </td>
                <td>The Hiragana (Japanese Kana characters) key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-JapaneseHiragana" class="value keyname">'JapaneseHiragana'</code></td>
                <td> </td>
                <td>The Japanese-Hiragana key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-JapaneseKatakana" class="value keyname">'JapaneseKatakana'</code></td>
                <td> </td>
                <td>The Japanese-Katakana key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-JapaneseRomaji" class="value keyname">'JapaneseRomaji'</code></td>
                <td> </td>
                <td>The Japanese-Romaji key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-KanaMode" class="value keyname">'KanaMode'</code></td>
                <td> </td>
                <td>The Kana Mode (Kana Lock) key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-KanjiMode" class="value keyname">'KanjiMode'</code></td>
                <td> </td>
                <td>The Kanji (Japanese name for ideographic characters of Chinese origin) Mode key.</td>
                <td class="category">IME</td>
              </tr>
              <tr>
                <td><code id="key-Katakana" class="value keyname">'Katakana'</code></td>
                <td> </td>
                <td>The Katakana (Japanese Kana characters) key.</td>
                <td class="category">IME</td>
              </tr>



              <tr>
                <td><code id="key-AudioFaderFront" class="value keyname">'AudioFaderFront'</code></td>
                <td> </td>
                <td>Adjust audio fader towards front.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioFaderRear" class="value keyname">'AudioFaderRear'</code></td>
                <td> </td>
                <td>Adjust audio fader towards rear.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioBalanceLeft" class="value keyname">'AudioBalanceLeft'</code></td>
                <td> </td>
                <td>Adjust audio balance leftward.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioBalanceRight" class="value keyname">'AudioBalanceRight'</code></td>
                <td> </td>
                <td>Adjust audio balance rightward.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioBassBoostDown" class="value keyname">'AudioBassBoostDown'</code></td>
                <td> </td>
                <td>Decrease audio bass boost or cycle down through bass boost states.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioBassBoostUp" class="value keyname">'AudioBassBoostUp'</code></td>
                <td> </td>
                <td>Increase audio bass boost or cycle up through bass boost states.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioMute" class="value keyname">'AudioMute'</code></td>
                <td> </td>
                <td>Toggle between muted state and prior volume level.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioVolumeDown" class="value keyname">'AudioVolumeDown'</code></td>
                <td> </td>
                <td>Decrease audio volume.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioVolumeUp" class="value keyname">'AudioVolumeUp'</code></td>
                <td> </td>
                <td>Increase audio volume.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaPause" class="value keyname">'MediaPause'</code></td>
                <td> </td>
                <td>Pause playback, if not paused or stopped; also used with keyboard entry to pause scrolling output.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaPlay" class="value keyname">'MediaPlay'</code></td>
                <td> </td>
                <td>Initiate or continue media playback at normal speed, if not currently playing at normal speed.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaTrackEnd" class="value keyname">'MediaTrackEnd'</code></td>
                <td> </td>
                <td>Seek to end of media or program.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaTrackNext" class="value keyname">'MediaTrackNext'</code></td>
                <td> </td>
                <td>Seek to next media or program track.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaPlayPause" class="value keyname">'MediaPlayPause'</code></td>
                <td> </td>
                <td>Toggle media between play and pause states.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaTrackPrevious" class="value keyname">'MediaTrackPrevious'</code></td>
                <td> </td>
                <td>Seek to previous media or program track.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaTrackSkip" class="value keyname">'MediaTrackSkip'</code></td>
                <td> </td>
                <td>Skip current content or program.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaTrackStart" class="value keyname">'MediaTrackStart'</code></td>
                <td> </td>
                <td>Seek to start of media or program.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaStop" class="value keyname">'MediaStop'</code></td>
                <td> </td>
                <td>Stop media playing, pausing, forwarding, rewinding, or recording, if not already stopped.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-SelectMedia" class="value keyname">'SelectMedia'</code></td>
                <td> </td>
                <td>The Select Media key.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Blue" class="value keyname">'Blue'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 3.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Brown" class="value keyname">'Brown'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 5.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ChannelDown" class="value keyname">'ChannelDown'</code></td>
                <td> </td>
                <td>Select next (numerically or logically) lower channel..</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ChannelUp" class="value keyname">'ChannelUp'</code></td>
                <td> </td>
                <td>Select next (numerically or logically) higher channel.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ClearFavorite0" class="value keyname">'ClearFavorite0'</code></td>
                <td> </td>
                <td>Clear program or content stored as favorite 0.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ClearFavorite1" class="value keyname">'ClearFavorite1'</code></td>
                <td> </td>
                <td>Clear program or content stored as favorite 1.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ClearFavorite2" class="value keyname">'ClearFavorite2'</code></td>
                <td> </td>
                <td>Clear program or content stored as favorite 2.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ClearFavorite3" class="value keyname">'ClearFavorite3'</code></td>
                <td> </td>
                <td>Clear program or content stored as favorite 3.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Dimmer" class="value keyname">'Dimmer'</code></td>
                <td> </td>
                <td>Adjust brightness of device, may toggle between or cycle through states.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-DisplaySwap" class="value keyname">'DisplaySwap'</code></td>
                <td> </td>
                <td>Swap video sources.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-FastFwd" class="value keyname">'FastFwd'</code></td>
                <td> </td>
                <td>Initiate or continue forward playback at faster than normal speed, or increase speed if already fast forwarding.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Green" class="value keyname">'Green'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 1.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Grey" class="value keyname">'Grey'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 4.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Guide" class="value keyname">'Guide'</code></td>
                <td> </td>
                <td>Toggle display of program or content guide.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-InstantReplay" class="value keyname">'InstantReplay'</code></td>
                <td> </td>
                <td>Toggle instant replay.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaLast" class="value keyname">'MediaLast'</code></td>
                <td> </td>
                <td>Select previously selected channel or media.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Link" class="value keyname">'Link'</code></td>
                <td> </td>
                <td>Launch linked content, if available and appropriate.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Live" class="value keyname">'Live'</code></td>
                <td> </td>
                <td>Toggle display listing of currently available live content or programs.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Lock" class="value keyname">'Lock'</code></td>
                <td> </td>
                <td>Lock or unlock current content or program.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-NextDay" class="value keyname">'NextDay'</code></td>
                <td> </td>
                <td>If guide is active and displayed, then display next day's content.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-NextFavoriteChannel" class="value keyname">'NextFavoriteChannel'</code></td>
                <td> </td>
                <td>Select next favorite channel (in favorites list).</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-OnDemand" class="value keyname">'OnDemand'</code></td>
                <td> </td>
                <td>Access on-demand content or programs.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PinPDown" class="value keyname">'PinPDown'</code></td>
                <td> </td>
                <td>Move picture-in-picture window downward.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PinPMove" class="value keyname">'PinPMove'</code></td>
                <td> </td>
                <td>Move picture-in-picture window.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PinPToggle" class="value keyname">'PinPToggle'</code></td>
                <td> </td>
                <td>Toggle display of picture-in-picture window.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PinPUp" class="value keyname">'PinPUp'</code></td>
                <td> </td>
                <td>Move picture-in-picture window upward.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PlaySpeedDown" class="value keyname">'PlaySpeedDown'</code></td>
                <td> </td>
                <td>Decrease media playback speed.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PlaySpeedReset" class="value keyname">'PlaySpeedReset'</code></td>
                <td> </td>
                <td>Reset playback speed to normal speed (according to current media function).</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PlaySpeedUp" class="value keyname">'PlaySpeedUp'</code></td>
                <td> </td>
                <td>Increase media playback speed.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-PrevDay" class="value keyname">'PrevDay'</code></td>
                <td> </td>
                <td>If guide is active and displayed, then display previous day's content.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RandomToggle" class="value keyname">'RandomToggle'</code></td>
                <td> </td>
                <td>Toggle random media or content shuffle mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RecallFavorite0" class="value keyname">'RecallFavorite0'</code></td>
                <td> </td>
                <td>Select (recall) program or content stored as favorite 0.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RecallFavorite1" class="value keyname">'RecallFavorite1'</code></td>
                <td> </td>
                <td>Select (recall) program or content stored as favorite 1.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RecallFavorite2" class="value keyname">'RecallFavorite2'</code></td>
                <td> </td>
                <td>Select (recall) program or content stored as favorite 2.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RecallFavorite3" class="value keyname">'RecallFavorite3'</code></td>
                <td> </td>
                <td>Select (recall) program or content stored as favorite 3.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaRecord" class="value keyname">'MediaRecord'</code></td>
                <td> </td>
                <td>Initiate or resume recording of currently selected media.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RecordSpeedNext" class="value keyname">'RecordSpeedNext'</code></td>
                <td> </td>
                <td>Toggle or cycle between media recording speeds (if applicable).</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Red" class="value keyname">'Red'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 0.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-MediaRewind" class="value keyname">'MediaRewind'</code></td>
                <td> </td>
                <td>Initiate or continue reverse playback at faster than normal speed, or increase speed if already rewinding.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-RfBypass" class="value keyname">'RfBypass'</code></td>
                <td> </td>
                <td>Toggle RF (radio frequency) input bypass mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ScanChannelsToggle" class="value keyname">'ScanChannelsToggle'</code></td>
                <td> </td>
                <td>Toggle scan channels mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-ScreenModeNext" class="value keyname">'ScreenModeNext'</code></td>
                <td> </td>
                <td>Advance display screen mode to next available mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Settings" class="value keyname">'Settings'</code></td>
                <td> </td>
                <td>Toggle display of device settings screen.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-SplitScreenToggle" class="value keyname">'SplitScreenToggle'</code></td>
                <td> </td>
                <td>Toggle split screen mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-StoreFavorite0" class="value keyname">'StoreFavorite0'</code></td>
                <td> </td>
                <td>Store current program or content as favorite 0.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-StoreFavorite1" class="value keyname">'StoreFavorite1'</code></td>
                <td> </td>
                <td>Store current program or content as favorite 1.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-StoreFavorite2" class="value keyname">'StoreFavorite2'</code></td>
                <td> </td>
                <td>Store current program or content as favorite 2.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-StoreFavorite3" class="value keyname">'StoreFavorite3'</code></td>
                <td> </td>
                <td>Store current program or content as favorite 3.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Subtitle" class="value keyname">'Subtitle'</code></td>
                <td> </td>
                <td>Toggle display of subtitles, if available.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-AudioSurroundModeNext" class="value keyname">'AudioSurroundModeNext'</code></td>
                <td> </td>
                <td>Advance surround audio mode to next available mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Teletext" class="value keyname">'Teletext'</code></td>
                <td> </td>
                <td>Toggle display of teletext, if available.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-VideoModeNext" class="value keyname">'VideoModeNext'</code></td>
                <td> </td>
                <td>Advance video mode to next available mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-DisplayWide" class="value keyname">'DisplayWide'</code></td>
                <td> </td>
                <td>Toggle device display mode between wide aspect and normal aspect mode.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Wink" class="value keyname">'Wink'</code></td>
                <td> </td>
                <td>Cause device to identify itself in some manner, e.g., audibly or visibly.</td>
                <td class="category">Media</td>
              </tr>
              <tr>
                <td><code id="key-Yellow" class="value keyname">'Yellow'</code></td>
                <td> </td>
                <td>General purpose color-coded media function key, as index 2.</td>
                <td class="category">Media</td>
              </tr>



              <tr>
                <td><code id="key-Unidentified" class="value keyname">'Unidentified'</code></td>
                <td> </td>
                <td>This key value is used when an implementations is unable to identify another key value, due to either hardware, platform, or software constraints.</td>
                <td class="category">Special</td>
              </tr>
            </table>

          </div>

        </div>
<!-- div2 KeySet-Set -->
      </div>
    </div>
<!-- div1 KeySet -->

    <div>
      <h2><a id="legacy-key-attributes" href="#legacy-key-attributes">Appendix A: Legacy key attributes: <code class="attr-name">keyCode</code>, <code class="attr-name">charCode</code>, and <code class="attr-name">which</code></a></h2>

      <p><em>This section is informative</em></p>

      <p>Browser support for keyboards has traditionally relied on three ad-hoc attributes, <code class="attr-name">keyCode</code>, <code class="attr-name">charCode</code>, and <code class="attr-name">which</code>.</p>  
      <p>All three of these attributes return a numerical code that represents some aspect of the key pressed: <code class="attr-name">keyCode</code> is an index of the key itself; <code class="attr-name">charCode</code> is the ASCII value of the character keys; <code class="attr-name">which</code> is the character value where available and otherwise the key index.  The values for these attributes, and the availability of the attribute, is inconsistent across platforms, keyboard languages and layouts, <a class="def" href="#glossary-user-agent">user agents</a>, versions, and even event types.  A significant amount of legacy content, including script libraries, relies upon detecting the <a class="def" href="#glossary-user-agent">user agent</a> and acting accordingly, and any changes to <code class="attr-name">keyCode</code>, <code class="attr-name">charCode</code>, or <code class="attr-name">which</code> risk breaking as much content as they fix or enable.  Additionally, these attributes are not suitable for international usage, or accessibility concerns.</p>
        
      <p>Therefore, this specification does not normatively define the <code class="attr-name">charCode</code>, <code class="attr-name">keyCode</code>, or <code class="attr-name">which</code> attributes on the <a href="#events-KeyboardEvent">KeyboardEvent</a> interface, though they may be present in <a class="def" href="#glossary-user-agent">user agents</a> for compatibility with legacy content.  Authors should use the <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> and <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> attributes instead of the <code class="attr-name">charCode</code> and <code class="attr-name">keyCode</code> attributes, respectively.</p>
      
      <p>However, for the purpose of documenting the current state of these attributes and their relation to equivalent key values, this section describes an informative supplemental Web IDL for <a href="#events-KeyboardEvent">KeyboardEvent</a> containing these attributes, and informative definitions for determining their attribute values.</p>

      <p>For implementations which do support these attributes, it is suggested to use this supplemental <a href="#events-KeyboardEvent-supplemental">KeyboardEvent</a> Web IDL.</p>

      <h3 id="KeyboardEvent-supplemental-interface">A.1 Legacy KeyboardEvent supplemental interface</h3>
      <dl>
        <dt>
          <strong>Interface <em><a id="events-KeyboardEvent-supplemental" name="events-KeyboardEvent-supplemental">KeyboardEvent (supplemental)</a></em></strong> (introduced in <strong class="since">DOM Level 3</strong>)
        </dt>
        <dd>
          <p>
            The supplemental <code>KeyboardEvent</code> interface is a non-normative extension of the <a href="#events-KeyboardEvent">KeyboardEvent</a> interface, which adds the <a href="#events-KeyboardEvent-supplemental-charCode">charCode</a>, <a href="#events-KeyboardEvent-supplemental-keyCode">keyCode</a>, and <a href="#events-KeyboardEvent-supplemental-which">which</a> attributes.
          </p>
          <p>
            To create an instance of the <code>KeyboardEvent (supplemental)</code> interface, use the <a href="#events-DocumentEvent-createEvent"><code>DocumentEvent.createEvent("KeyboardEvent")</code></a> method call, though this does not take the values of the <a href="#events-KeyboardEvent-supplemental-charCode">charCode</a>, <a href="#events-KeyboardEvent-supplemental-keyCode">keyCode</a>, or <a href="#events-KeyboardEvent-supplemental-which">which</a> attributes as parameters.
          </p>
          <dl>
            <dt>
              <br/>
              <strong>Web IDL Definition</strong>
            </dt>
            <dd>
              <pre class="idl" id="idl-interface-KeyboardEvent-supplemental">
          <code>
          // Legacy, introduced in DOM Level 3:
          [Supplemental]
          interface <a href="#events-KeyboardEvent-supplemental">KeyboardEvent</a> {
            readonly attribute unsigned long   <a href="#events-KeyboardEvent-supplemental-charCode">charCode</a>;
            readonly attribute unsigned long   <a href="#events-KeyboardEvent-supplemental-keyCode">keyCode</a>;
            readonly attribute unsigned long   <a href="#events-KeyboardEvent-supplemental-which">which</a>;
          };
                          </code>
          </pre>
            </dd>
            <dt>
              <strong>Attributes</strong>
            </dt>
            <dd>
              <dl>
                <dt>
                  <code class="attribute-name"><a id="events-KeyboardEvent-supplemental-charCode" name="events-KeyboardEvent-supplemental-charCode">charCode</a></code> of type <code>unsigned long</code>, readonly
                </dt>
                <dd>
                  <p>
                    <code class="attr-name">charCode</code> holds a character value, for <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> events which generate character input.  The value is the Unicode reference number (code point) of that character (e.g. <code>event.charCode = event.char.charCodeAt(0)</code>). For <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> or  <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events, the value of <code class="attr-name">charCode</code> is <code>0</code>.
                  </p>
                </dd>

                <dt>
                  <code class="attribute-name"><a id="events-KeyboardEvent-supplemental-keyCode">keyCode</a></code> of type <code>unsigned long</code>, readonly
                </dt>
                <dd>
                  <p>
                    <code class="attr-name">keyCode</code> holds a system- and implementation-dependent numerical code signifying the unmodified identifier associated with the key pressed. Unlike the <a href="#events-KeyboardEvent-key"><code>KeyboardEvent.key</code></a> or <a href="#events-KeyboardEvent-char"><code>KeyboardEvent.char</code></a> attributes, the set of possible values are not normatively defined in this specification; typically, these value of the <code class="attr-name">keyCode</code> should represent the decimal codepoint in ASCII [<a href="#ref-rfc20">RFC20</a>][<a href="#ref-US-ASCII">US-ASCII</a>] or Windows 1252 [<a href="#ref-WIN1252">WIN1252</a>], but may be drawn from a different appropriate character set. Implementations that are unable to identify a key must use the key value <code class="value">0</code>.  
                  </p>
                  <p>See <a href="#legacy-key-models">Legacy key models</a> for more details on how to determine the values for <code class="attr-name">keyCode</code>.</p>
                </dd>

                <dt>
                  <code class="attribute-name"><a id="events-KeyboardEvent-supplemental-which" name="events-KeyboardEvent-supplemental-which">which</a></code> of type <code>unsigned long</code>, readonly
                </dt>
                <dd>
                  <p>
                    <code>which</code> holds a system- and implementation-dependent numerical code signifying the unmodified identifier associated with the key pressed.  In most cases, the value is identical to <code class="attribute-name"><a href="#events-KeyboardEvent-supplemental-keyCode">keyCode</a></code>.
                  </p>
                </dd>
              </dl>
            </dd>
          </dl>
        </dd>
      </dl>


      <h3 id="legacy-key-models">A.2 Legacy key models</h3>
      <p><em>This section is informative</em></p>
      <p>Implementations differ on which values are exposed on these attributes for different event types.  An implementation may choose to expose both virtual key codes and character codes in the <code class="attr-name">keyCode</code> property (<em>conflated model</em>), or report separate <code class="attr-name">keyCode</code> and <code class="attr-name">charCode</code> properties (<em>split model</em>).</p>

      <h4 id="determine-keydown-keyup-keyCode">A.2.1 How to determine <code class="attr-name">keyCode</code> for <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> and <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events</h4>
      <p>The <code class="attr-name">keyCode</code> for <a class="eventtype" href="#event-type-keydown"><code>keydown</code></a> or <a class="eventtype" href="#event-type-keyup"><code>keyup</code></a> events is calculated as follows:</p>
      <ol>
        <li>Read the virtual key code from the operating system's event information, if such information is available.</li>
        <li>If an Input Method Editor is processing key input and the event is keydown, return 229.</li>
        <li>If input key when pressed without modifiers would insert a numerical character (0-9), return the ASCII code of that numerical character.</li>
        <li>If input key when pressed without modifiers would insert a a lower case character in the a-z alphabetical range, return the ASCII code of the upper case equivalent.</li>
        <li>If the implementation supports a key code conversion table for the operating system and platform, look up the value. If the conversion table specifies an alternate virtual key value for the given input, return the specified value.</li>
        <li>If the key's function, as determined in an implementation-specific way, corresponds to one of the keys in the <a href="#fixed-virtual-key-codes">table of fixed virtual key codes</a>, return the corresponding key code.</li>
         <li>Return the virtual key code from the operating system.</li>
        <li>If no key code was found, return 0.</li>
      </ol>

      <h4 id="determine-keypress-keyCode">A.2.2 How to determine <code class="attr-name">keyCode</code> for <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> events</h4>
      <p><em>This section is informative</em></p>
      <p>The <code class="attr-name">keyCode</code> for <a class="eventtype" href="#event-type-keypress"><code>keypress</code></a> events is calculated as follows:</p>
      <ol>
        <li>If the implementation supports a <em>conflated model</em>, set <code class="attr-name">keyCode</code> to the Unicode code point of the character being entered.</li>
        <li>If the implementation supports a <em>split model</em>, set <code class="attr-name">keyCode</code> to 0.</li>
      </ol>


      <h4 id="fixed-virtual-key-codes">A.2.3 Fixed virtual key codes</h4>
      <p><em>This section is informative</em></p>
      <p>The virtual key codes for the following keys do not usually change with keyboard layouts on desktop systems:</p>
      <table class="data-table">
        <tr><th><strong>Key</strong></th> <th><strong>Virtual Key Code</strong></th></tr>
        <tr><th>Backspace</th> <td>8</td></tr>
        <tr><th>Tab</th> <td>9</td></tr>
        <tr><th>Enter</th> <td>13</td></tr>
        <tr><th>Shift</th> <td>16</td></tr>
        <tr><th>Control</th> <td>17</td></tr>
        <tr><th>Alt</th> <td>18</td></tr>
        <tr><th>Caps Lock</th> <td>20</td></tr>
        <tr><th>Escape</th> <td>27</td></tr>
        <tr><th>Space</th> <td>32</td></tr>
        <tr><th>Page up</th> <td>33</td></tr>
        <tr><th>Page down</th> <td>34</td></tr>
        <tr><th>End</th> <td>35</td></tr>
        <tr><th>Home</th> <td>36</td></tr>
        <tr><th>Left</th> <td>37</td></tr>
        <tr><th>Up</th> <td>38</td></tr>
        <tr><th>Right</th> <td>39</td></tr>
        <tr><th>Down</th> <td>40</td></tr>
        <tr><th>Delete</th> <td>46</td></tr>
      </table>

      <h4 id="optionally-fixed-virtual-key-codes">A.2.4 Optionally fixed virtual key codes</h4>
      <p><em>This section is informative</em></p>
      <p>The following punctuation characters may change virtual codes between keyboard layouts, but reporting these values will likely be more compatible with legacy content expecting US-English keyboard layout:</p>
    	<table class="data-table">
      	<tr><th><strong>Key</strong></th> <th><strong>Virtual Key Code</strong></th></tr>
      	<tr><th>Semicolon (;)</th> <td>186</td></tr>
      	<tr><th>Colon (:)</th> <td>186</td></tr>
      	<tr><th>Plus (+)</th> <td>187</td></tr>
      	<tr><th>Equals sign (=)</th> <td>187</td></tr>
      	<tr><th>Comma (,)</th> <td>188</td></tr>
      	<tr><th>Less than sign (&lt;)</th> <td>188</td></tr>
      	<tr><th>Minus (-)</th> <td>189</td></tr>
      	<tr><th>Underscore (_)</th> <td>189</td></tr>
      	<tr><th>Period (.)</th> <td>190</td></tr>
      	<tr><th>Greater than sign (&gt;)</th> <td>190</td></tr>
      	<tr><th>Question mark (?)</th> <td>191</td></tr>
      	<tr><th>Forward slash (/)</th> <td>191</td></tr>
      	<tr><th>Backtick (`)</th> <td>192</td></tr>
      	<tr><th>Tilde (~)</th> <td>192</td></tr>
      	<tr><th>Opening square bracket ([)</th> <td>219</td></tr>
      	<tr><th>Opening curly bracket ({)</th> <td>219</td></tr>
      	<tr><th>Backslash (\)</th> <td>220</td></tr>
      	<tr><th>Pipe (|)</th> <td>220</td></tr>
      	<tr><th>Closing square bracket (])</th> <td>221</td></tr>
      	<tr><th>Closing curly bracket (})</th> <td>221</td></tr>
      	<tr><th>Single quote (')</th> <td>222</td></tr>
      	<tr><th>Double quote (")</th> <td>222</td></tr>
    	</table>
      	
    </div>
<!-- Appendix A: Legacy Key Events -->

<!-- Appendix B: Extending Events -->
    <div>
      <h2><a id="extending_events" href="#extending_events">Appendix B: Extending Events</a></h2>

      <p><em>This section is informative</em></p>
      <h3><a id="extending_events-intro" href="#extending_events-intro">B.1 Introduction</a></h3>

      <p class="1st">This specification defines several interfaces and many events; however, this is not an exhaustive set of events for all purposes.  To allow content authors and implementers to add desired functionality, this specification provides two mechanisms for extend this set of interfaces and events without creating conflicts: <a href="#extending_events-Custom_Events">custom events</a> and <a href="#extending_events-Impl_Extensions">implementation-specific extensions</a>.</p>
      
      <h3><a id="extending_events-Custom_Events" href="#extending_events-Custom_Events">B.2 Custom Events</a></h3>

      <p>A script author may wish to define an application in terms of functional components, with event types that are meaningful to the application architecture.  The content author can use the <a href="#events-CustomEvent"><code>CustomEvent</code></a> interface to create their own events appropriate to the level of abstraction they are using.</p>
      <div class="example" id="example-custom-events">
        <p><strong>Example:</strong> A content author might have created an application which features a dynamically generated bar chart.  This bar chart is meant to be updated every 5 minutes, or when a feed shows new information, or when the user refreshes it manually by clicking a button.  There are several handlers that have to be called when the chart needs to be updated: the application has to fetch the most recent data, show an icon to the user that the event is being updated, and rebuild the chart.  To manage this, the content author can choose to create a custom "updateChart" event, which is fired whenever one of the trigger conditions is met:</p>
        <pre><code>
  var chartData = ...;
  var evt = document.createEvent("CustomEvent");
  evt.initCustomEvent( "updateChart", true, false, { data: chartData });
  document.documentElement.dispatchEvent(evt);          
        </code></pre>
      </div>
      <h2><a id="extending_events-Impl_Extensions" href="#extending_events-Impl_Extensions">B.3 Implementation-Specific Extensions</a></h2>

      <p>While a new event is being designed and prototyped, or when an event is intended for implementation-specific functionality, it is desirable to distinguish it from standardized events.  Implementors should prefix event types specific to their implementations with a short string to distinguish it from the same event in other implementations and from standardized events.  This is similar to the <a href="http://www.w3.org/TR/CSS21/syndata.html#vendor-keywords" title="CSS 2.1: Syntax and basic data types">vendor-specific keyword prefixes</a> in CSS, though without the dashes ("-") used in CSS, since that can cause problems when used as an attribute name in Javascript.</p>
      <div class="example" id="example-impl-extensions">
        <p><strong>Example:</strong> A particular browser vendor, "FooCorp", might wish to introduce a new event, "<code>jump</code>".  This vendor implements "<code>fooJump</code>" in their browser, using their vendor-specific prefix, <code class="value">foo</code>.  Early adopters start experimenting with the event, using <code>someElement.addEventListener( "fooJump", doJump, false )</code>, and provide feedback to FooCorp, who change the behavior of "<code>fooJump</code>" accordingly.</p>
        <p>After some time, another vendor, "BarOrg", decides they also want the functionality, but implement it slightly differently, so they use their own vendor-specific prefix, <code class="value">bar</code> in their event type name, "<code>barJump</code>".  Content authors experimenting with this version of the "<code>jump</code>" event type register events with BarOrg's event type name.  Content authors who wish to write code that accounts for both browsers can either register each event type separately with specific handlers, or use the same handler and switch on the name of the event type; thus, early experiments in different codebases do not conflict, and the early adopter is able to write easily-maintained code for multiple implementations.</p>
        <p>Eventually, as the feature matures, the behavior of both browsers stabilize and might converge due to content author and user feedback or through formal standardization; as this stabilization occurs, and risk of conflicts decrease, content authors can remove the forked code, and use the "<code>jump</code>" event type name (even before it is formally standardized) using the same event handler and the more generic registration method <code>someElement.addEventListener( "jump", doJump, false )</code>.</p>
      </div>  
      
      <h4><a id="extending_events-prefixes" href="#extending_events-prefixes">B.3.1 Known Implementation-Specific Prefixes</a></h4>

      <p>At the time of writing, the following event-type name prefixes are known to exist:</p>
      <table border="1" cellpadding="2" cellspacing="0" summary="Known event-type name prefixes">
        <thead>
          <tr>
            <th>Prefix</th>
            <th>Web Engine (Organization)</th>
          </tr>
        </thead>
        <tbody>
          <tr>
            <td><code>moz</code>, <code>Moz</code></td>
            <td>Gecko (Mozilla)</td>
          </tr>
          <tr>
            <td><code>ms</code>, <code>MS</code></td>
            <td>Trident (Microsoft)</td>
          </tr>
          <tr>
            <td><code>o</code>, <code>O</code></td>
            <td>Presto (Opera Software)</td>
          </tr>
          <tr>
            <td><code>webkit</code></td>
            <td>WebKit (Apple, Google, others)</td>
          </tr>
        </tbody>
      </table>
      <br />
    </div>
	<!-- div1 WebIDL -->
    <div>
      <h2><a id="webidl-definitions" href="#webidl-definitions">Appendix C: WebIDL Interface Definitions</a></h2>
	  <p><em>This section is informative</em></p>
      <p>The following definitions are [<a href="#references-webIDL">WebIDL</a>] implementations of the interfaces defined in this specification.</p>
      	   
      	   <!-- interface Event webIDL -->
      	        <h3><a id="webidl-events-Event" href="#webidl-events-Event">Interface Event</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#interface-Event">interface Event</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-Event"><code>
// Introduced in DOM Level 2:
interface <a href="#events-Event">Event</a> 
{
  // PhaseType
  const unsigned short               <a href="#events-CAPTURING_PHASE">CAPTURING_PHASE</a>      = 1;
  const unsigned short               <a href="#events-AT_TARGET">AT_TARGET</a>            = 2;
  const unsigned short               <a href="#events-BUBBLING_PHASE">BUBBLING_PHASE</a>       = 3;

  readonly attribute DOMString       <a href="#events-event-type-type">type</a>;
  readonly attribute <a href="#events-EventTarget">EventTarget</a>     <a href="#events-event-type-target">target</a>;
  readonly attribute <a href="#events-EventTarget">EventTarget</a>     <a href="#events-event-type-currentTarget">currentTarget</a>;
  readonly attribute unsigned short  <a href="#events-event-type-eventPhase">eventPhase</a>;
  readonly attribute boolean         <a href="#events-event-type-canBubble">bubbles</a>;
  readonly attribute boolean         <a href="#events-event-type-canCancel">cancelable</a>;
  readonly attribute DOMTimeStamp    <a href="#events-event-type-timeStamp">timeStamp</a>;

  void                               <a href="#events-event-type-stopPropagation">stopPropagation</a>();
  void                               <a href="#events-event-type-preventDefault">preventDefault</a>();
  void                               <a href="#events-event-type-initEvent">initEvent</a>(in DOMString eventTypeArg, 
                                               in boolean canBubbleArg, 
                                               in boolean cancelableArg);
  // Introduced in DOM Level 3:
  void                               <a href="#events-event-type-stopImmediatePropagation">stopImmediatePropagation</a>();

  readonly attribute boolean         <a href="#events-event-type-defaultPrevented">defaultPrevented</a>;
  readonly attribute boolean         <a href="#events-event-type-isTrusted">isTrusted</a>;
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface CustomEvent webIDL -->
      	        <h3><a id="webidl-events-CustomEvent" href="#webidl-events-CustomEvent">Interface CustomEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#interface-CustomEvent">interface CustomEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-CustomEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-CustomEvent">CustomEvent</a> : <a href="#events-Event">Event</a> 
{
  readonly attribute any             <a href="#events-CustomEvent-detail">detail</a>;
  void                               <a href="#events-event-type-initCustomEvent">initCustomEvent</a>(in DOMString typeArg, 
                                                     in boolean   canBubbleArg, 
                                                     in boolean   cancelableArg, 
                                                     in any       detailArg);
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface EventTarget webIDL -->
      	        <h3><a id="webidl-events-EventTarget" href="#webidl-events-EventTarget">Interface EventTarget</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#interface-EventTarget">interface EventTarget</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-EventTarget"><code>
// Introduced in DOM Level 2:
[NoInterfaceObject]
interface <a href="#events-EventTarget">EventTarget</a> 
{
  void               <a href="#events-EventTarget-addEventListener">addEventListener</a>(in DOMString type, 
                                      in <a href="#events-EventListener">EventListener</a> listener, 
                                      in <em>optional</em> boolean useCapture);
  void               <a href="#events-EventTarget-removeEventListener">removeEventListener</a>(in DOMString type, 
                                         in <a href="#events-EventListener">EventListener</a> listener, 
                                         in <em>optional</em> boolean useCapture);
  // Modified in DOM Level 3:
  boolean            <a href="#events-EventTarget-dispatchEvent">dispatchEvent</a>(in <a href="#events-Event">Event</a> evt)
                                   raises(<a href="#events-EventException">EventException</a>, 
                                   DOMException);
                                   
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface EventListener webIDL -->
      	        <h3><a id="webidl-events-EventListener" href="#webidl-events-EventListener">Interface EventListener</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#interface-EventListener">interface EventListener</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-EventListener"><code>
// Introduced in DOM Level 2:
[Callback]
interface <a href="#events-EventListener">EventListener</a> 
{
  void               <a href="#events-EventListener-handleEvent">handleEvent</a>(in <a href="#events-Event">Event</a> evt);
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- Exception EventException webIDL -->
      	        <h3><a id="webidl-events-EventException" href="#webidl-events-EventException">Exception EventException</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-EventException">exception EventException</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-EventException"><code>
// Introduced in DOM Level 2:
exception <a href="#events-EventException">EventException</a> 
{
// EventExceptionCode
                const unsigned short <a href="#events-UNSPECIFIED_EVENT_TYPE_ERR">UNSPECIFIED_EVENT_TYPE_ERR</a> = 0;
// Introduced in DOM Level 3:
                const unsigned short <a href="#events-DISPATCH_REQUEST_ERR">DISPATCH_REQUEST_ERR</a> = 1;

                unsigned short code;
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface DocumentEvent webIDL -->
      	        <h3><a id="webidl-events-DocumentEvent" href="#webidl-events-DocumentEvent">Interface DocumentEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#interface-DocumentEvent">interface DocumentEvent</a></strong></dt>
      	        <dd>
                  <pre class="idl" id="WEBidl-interface-DocumentEvent"><code>
// Introduced in DOM Level 2:
[NoInterfaceObject]
interface <a href="#events-DocumentEvent">DocumentEvent</a> 
{
  // Modified in DOM Level 3:
  <a href="#events-Event">Event</a>                     <a href="#events-DocumentEvent-createEvent">createEvent</a>(in DOMString eventInterface)
                                        raises(DOMException);
};
Document implements <a href="#events-DocumentEvent">DocumentEvent</a>;
                  </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface UIEvent webIDL -->
      	        <h3><a id="webidl-events-UIEvent" href="#webidl-events-UIEvent">Interface UIEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-UIEvent">interface UIEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-UIEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-UIEvent">UIEvent</a> : <a href="#events-Event">Event</a> 
{
  readonly attribute AbstractView <a href="#events-UIEvent-view">view</a>;
  readonly attribute long	<a href="#events-UIEvent-detail">detail</a>;

  void                               <a href="#events-event-type-initUIEvent">initUIEvent</a>(in DOMString typeArg, 
                                                 in boolean canBubbleArg, 
                                                 in boolean cancelableArg, 
                                                 in AbstractView viewArg, 
                                                 in long detailArg);
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface FocusEvent webIDL -->
      	        <h3><a id="webidl-events-FocusEvent" href="#webidl-events-FocusEvent">Interface FocusEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-FocusEvent">interface FocusEvent</a></strong></dt>
	      	        <dd>
	                <pre class="idl" id="WEBidl-interface-FocusEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-FocusEvent">FocusEvent</a> : <a href="#events-UIEvent">UIEvent</a> 
{
  readonly attribute <a href="#events-EventTarget">EventTarget</a>   <a href="#events-FocusEvent-relatedTarget">relatedTarget</a>;

  void                             <a href="#events-event-type-initFocusEvent">initFocusEvent</a>(in DOMString typeArg, 
												  in boolean canBubbleArg, 
												  in boolean cancelableArg, 
												  in AbstractView viewArg, 
												  in long detailArg, 
												  in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg);
};
	                </code></pre>
	                </dd>
	            </dl>


      	   <!-- interface MouseEvent webIDL -->
      	        <h2><a id="webidl-events-MouseEvent" href="#webidl-events-MouseEvent">Interface MouseEvent</a></h2>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-MouseEvent">interface MouseEvent</a></strong></dt>
      	        <dd>
              <pre class="idl" id="WEBidl-interface-MouseEvent"><code>
// Modified in DOM Level 3:
interface <a href="#events-MouseEvent">MouseEvent</a> : <a href="#events-UIEvent">UIEvent</a> 
{
  readonly attribute long            <a href="#events-MouseEvent-screenX">screenX</a>;
  readonly attribute long            <a href="#events-MouseEvent-screenY">screenY</a>;
  readonly attribute long            <a href="#events-MouseEvent-clientX">clientX</a>;
  readonly attribute long            <a href="#events-MouseEvent-clientY">clientY</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-ctrlKey">ctrlKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-shiftKey">shiftKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-altKey">altKey</a>;
  readonly attribute boolean         <a href="#events-MouseEvent-metaKey">metaKey</a>;
  readonly attribute unsigned short  <a href="#events-MouseEvent-button">button</a>;  
  readonly attribute unsigned short  <a href="#events-MouseEvent-buttons">buttons</a>;
  readonly attribute                 <a href="#events-EventTarget">EventTarget</a>     <a href="#events-MouseEvent-relatedTarget">relatedTarget</a>;

  void                               <a href="#events-event-type-initMouseEvent">initMouseEvent</a>(in DOMString typeArg, 
                                                in boolean canBubbleArg, 
                                                in boolean cancelableArg, 
                                                in AbstractView viewArg, 
                                                in long detailArg, 
                                                in long screenXArg, 
                                                in long screenYArg, 
                                                in long clientXArg, 
                                                in long clientYArg, 
                                                in boolean ctrlKeyArg, 
                                                in boolean altKeyArg, 
                                                in boolean shiftKeyArg, 
                                                in boolean metaKeyArg, 
                                                in unsigned short buttonArg,
                                                in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg);

  // Introduced in DOM Level 3:
  boolean                            <a href="#events-MouseEvent-getModifierState">getModifierState</a>(in DOMString keyArg);
};
              </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface WheelEvent webIDL -->
      	        <h3><a id="webidl-events-WheelEvent" href="#webidl-events-WheelEvent">Interface WheelEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-WheelEvent">interface WheelEvent</a></strong></dt>
      	        <dd>
              <pre class="idl" id="WEBidl-interface-WheelEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-WheelEvent">WheelEvent</a> : <a href="#events-MouseEvent">MouseEvent</a> 
{
  // DeltaModeCode
  const unsigned long                <a href="#events-DOM_DELTA_PIXEL">DOM_DELTA_PIXEL</a>       = 0x00;
  const unsigned long                <a href="#events-DOM_DELTA_LINE">DOM_DELTA_LINE</a>        = 0x01;
  const unsigned long                <a href="#events-DOM_DELTA_PAGE">DOM_DELTA_PAGE</a>        = 0x02;

  readonly attribute float            <a href="#events-WheelEvent-deltaX">deltaX</a>;
  readonly attribute float            <a href="#events-WheelEvent-deltaY">deltaY</a>;
  readonly attribute float            <a href="#events-WheelEvent-deltaZ">deltaZ</a>;
  readonly attribute unsigned long   <a href="#events-WheelEvent-deltaMode">deltaMode</a>;

  void                               <a href="#events-event-type-initWheelEvent">initWheelEvent</a>(in DOMString typeArg, 
                                                    in boolean canBubbleArg, 
                                                    in boolean cancelableArg, 
                                                    in AbstractView viewArg, 
                                                    in long detailArg, 
                                                    in long screenXArg, 
                                                    in long screenYArg, 
                                                    in long clientXArg, 
                                                    in long clientYArg, 
                                                    in unsigned short buttonArg, 
                                                    in <a href="#events-EventTarget">EventTarget</a> relatedTargetArg, 
                                                    in DOMString modifiersListArg, 
                                                    in float deltaXArg, 
                                                    in float deltaYArg, 
                                                    in float deltaZArg, 
                                                    in unsigned long deltaMode);
};
              </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface TextEvent webIDL -->
      	        <h3><a id="webidl-events-TextEvent" href="#webidl-events-TextEvent">Interface TextEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-TextEvent">interface TextEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-TextEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-TextEvent">TextEvent</a> : <a href="#events-UIEvent">UIEvent</a> 
{
  // InputMethodCode
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_UNKNOWN">DOM_INPUT_METHOD_UNKNOWN</a>       = 0x00;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_KEYBOARD">DOM_INPUT_METHOD_KEYBOARD</a>      = 0x01;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_PASTE">DOM_INPUT_METHOD_PASTE</a>         = 0x02;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_DROP">DOM_INPUT_METHOD_DROP</a>          = 0x03;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_IME">DOM_INPUT_METHOD_IME</a>           = 0x04;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_OPTION">DOM_INPUT_METHOD_OPTION</a>        = 0x05;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_HANDWRITING">DOM_INPUT_METHOD_HANDWRITING</a>   = 0x06;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_VOICE">DOM_INPUT_METHOD_VOICE</a>         = 0x07;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_MULTIMODAL">DOM_INPUT_METHOD_MULTIMODAL</a>    = 0x08;
  const unsigned long                <a href="#events-DOM_INPUT_METHOD_SCRIPT">DOM_INPUT_METHOD_SCRIPT</a>        = 0x09;

  readonly attribute DOMString       <a href="#events-TextEvent-data">data</a>;
  readonly attribute unsigned long   <a href="#events-TextEvent-inputMethod">inputMethod</a>;  
  readonly attribute DOMString       <a href="#events-TextEvent-locale">locale</a>;

  void                               <a href="#events-event-type-initTextEvent">initTextEvent</a>(in DOMString typeArg, 
                                                   in boolean canBubbleArg, 
                                                   in boolean cancelableArg, 
                                                   in AbstractView viewArg, 
                                                   in DOMString dataArg, 
                                                   in unsigned long inputMethod, 
                                                   in DOMString localeArg);
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface KeyboardEvent webIDL -->
      	        <h3><a id="webidl-events-KeyboardEvent" href="#webidl-events-KeyboardEvent">Interface KeyboardEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-KeyboardEvent">interface KeyboardEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-KeyboardEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-KeyboardEvent">KeyboardEvent</a> : <a href="#events-UIEvent">UIEvent</a> 
{
  // KeyLocationCode
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_STANDARD">DOM_KEY_LOCATION_STANDARD</a>      = 0x00;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_LEFT">DOM_KEY_LOCATION_LEFT</a>          = 0x01;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_RIGHT">DOM_KEY_LOCATION_RIGHT</a>         = 0x02;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_NUMPAD">DOM_KEY_LOCATION_NUMPAD</a>        = 0x03;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_MOBILE">DOM_KEY_LOCATION_MOBILE</a>        = 0x04;
  const unsigned long                <a href="#events-DOM_KEY_LOCATION_JOYSTICK">DOM_KEY_LOCATION_JOYSTICK</a>      = 0x05;

  readonly attribute DOMString       <a href="#events-KeyboardEvent-char">char</a>;
  readonly attribute DOMString       <a href="#events-KeyboardEvent-key">key</a>;
  readonly attribute unsigned long   <a href="#events-KeyboardEvent-location">location</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-ctrlKey">ctrlKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-shiftKey">shiftKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-altKey">altKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-metaKey">metaKey</a>;
  readonly attribute boolean         <a href="#events-KeyboardEvent-repeat">repeat</a>;
  readonly attribute DOMString       <a href="#events-KeyboardEvent-locale">locale</a>;

  boolean                            <a href="#events-KeyboardEvent-getModifierState">getModifierState</a>(in DOMString keyArg);
  void                               <a href="#events-KeyboardEvent-initKeyboardEvent">initKeyboardEvent</a>(in DOMString typeArg, 
                                                       in boolean canBubbleArg, 
                                                       in boolean cancelableArg, 
                                                       in AbstractView viewArg, 
                                                       in DOMString charArg, 
                                                       in DOMString keyArg, 
                                                       in unsigned long locationArg, 
                                                       in DOMString modifiersListArg,
                                                       in boolean repeat,
                                                       in DOMString localeArg); 
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface CompositionEvent webIDL -->
      	        <h3><a id="webidl-events-CompositionEvent" href="#webidl-events-CompositionEvent">Interface CompositionEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-CompositionEvent">interface CompositionEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-CompositionEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-CompositionEvent">CompositionEvent</a> : <a href="#events-UIEvent">UIEvent</a> 
{
  readonly attribute DOMString       <a href="#events-CompositionEvent-data">data</a>;
  readonly attribute DOMString       <a href="#events-CompositionEvent-locale">locale</a>;

  void                               <a href="#events-event-type-initCompositionEvent">initCompositionEvent</a>(in DOMString typeArg, 
                                                          in boolean canBubbleArg, 
                                                          in boolean cancelableArg, 
                                                          in AbstractView viewArg, 
                                                          in DOMString dataArg,
                                                          in DOMString localeArg);
};
                </code></pre>
              </dd>
      	        </dl>

      	   <!-- interface MutationEvent webIDL -->
      	        <h3><a id="webidl-events-MutationEvent" href="#webidl-events-MutationEvent">Interface MutationEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-MutationEvent">interface MutationEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-MutationEvent"><code>
// Introduced in DOM Level 2:
interface <a href="#events-MutationEvent">MutationEvent</a> : <a href="#events-Event">Event</a> 
{
  // attrChangeType
  const unsigned short      <a href="#events-MODIFICATION">MODIFICATION</a>                   = 1;
  const unsigned short      <a href="#events-ADDITION">ADDITION</a>                       = 2;
  const unsigned short      <a href="#events-REMOVAL">REMOVAL</a>                        = 3;

  readonly attribute Node            <a href="#events-MutationEvent-relatedNode">relatedNode</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-prevValue">prevValue</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-newValue">newValue</a>;
  readonly attribute DOMString       <a href="#events-MutationEvent-attrName">attrName</a>;
  readonly attribute unsigned short  <a href="#events-MutationEvent-attrChange">attrChange</a>;

  void               <a href="#events-event-type-initMutationEvent">initMutationEvent</a>(in DOMString typeArg, 
                                       in boolean canBubbleArg, 
                                       in boolean cancelableArg, 
                                       in Node relatedNodeArg, 
                                       in DOMString prevValueArg, 
                                       in DOMString newValueArg, 
                                       in DOMString attrNameArg, 
                                       in unsigned short attrChangeArg);
};
                </code></pre>
              </dd>
      	        </dl>


      	   <!-- interface MutationNameEvent webIDL -->
      	        <h3><a id="webidl-events-MutationNameEvent" href="#webidl-events-MutationNameEvent">Interface MutationNameEvent</a></h3>
      	        <dl>
      	        	<dt><strong>WebIDL Definition for the <a href="#events-MutationNameEvent">interface MutationNameEvent</a></strong></dt>
      	        <dd>
                <pre class="idl" id="WEBidl-interface-MutationNameEvent"><code>
// Introduced in DOM Level 3:
interface <a href="#events-MutationNameEvent">MutationNameEvent</a> : <a href="#events-MutationEvent">MutationEvent</a> 
{
  readonly attribute DOMString       <a href="#events-MutationNameEvent-prevNamespaceURI">prevNamespaceURI</a>;
  readonly attribute DOMString       <a href="#events-MutationNameEvent-prevNodeName">prevNodeName</a>;

  // Introduced in DOM Level 3:
  void                               <a href="#events-event-type-initMutationNameEvent">initMutationNameEvent</a>(in DOMString typeArg, 
                                                           in boolean canBubbleArg, 
                                                           in boolean cancelableArg, 
                                                           in Node relatedNodeArg, 
                                                           in DOMString prevNamespaceURIArg, 
                                                           in DOMString prevNodeNameArg);
};
                </code></pre>
              </dd>
	        </dl>
      </div>
<!-- div1 Events -->
    <div>
      <h2><a id="security-considerations-Security" href="#security-considerations-Security">Appendix D: Security Considerations</a></h2>

      <p class="1st">This appendix discusses security considerations for DOM Level 3 Events implementations. The discussion is limited to security issues that arise directly from implementation of the event model, APIs and events defined in this specification. Implementations typically support other features like scripting languages, other APIs and additional events not defined in this document; these features constitute an unknown factor and are out of scope of this document. Implementers should consult the specifications of such features for their respective security considerations.</p>
      <p>Many of the event types defined in this specification are dispatched in response to user actions. This allows malicious event listeners to gain access to information users would typically consider confidential, e.g., typos they might have made when filling out a form, if they reconsider their answer to a multiple choice question shortly before submitting a form, their typing rate or primary input mechanism. In the worst case, malicious event listeners are able to capture all user interactions and submit them to a third party through means, while not defined in DOM Level 3 Events, generally available in DOM implementations, such as the XMLHttpRequest interface.</p>
      <p>In DOM implementations that support facilities to load external data, events like the <code>error</code> event can provide access to sensitive information about the environment of the computer system or network; an example would be a malicious HTML document that attempts to embed a resource on the local network or the localhost on different ports; an embedded <a class="def" href="#glossary-DOM-application">DOM application</a> could then listen for <code>error</code> and <code>load</code> events to determine which other computers in a network are accessible from the local system or which ports are open on the system to prepare further attacks.</p>
      <p>An implementation of DOM Level 3 Events alone is generally insufficient to perform attacks of this kind and the security considerations of the facilities that possibly support such attacks apply. For conformance with this specification, DOM implementations may take reasonable steps to ensure that <a class="def" href="#glossary-DOM-application">DOM applications</a> do not get access to confidential or sensitive information, for example, they might choose to dispatch no <code>load</code> events to nodes that attempt to embed resources on the local network.</p>
      <p>The <a href="http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-5CED94D7"><code>DOMImplementation.hasFeature()</code></a> method allows content authors to retrieve information about which event types the implementation supports, including event types not defined in this specification. Which event types a DOM Level 3 Events implementation supports can depend on configuration settings or on additional software modules available to the implementation.</p>
    </div>
<!-- div1 Security -->

    
    <div>
      <h2><a id="changes-Changes" href="#changes-Changes">Appendix E: Changes</a></h2>

      <div>
        <h3><a id="changes-DOMEvents2to3Changes" href="#changes-DOMEvents2to3Changes">E.1 Changes between DOM Level 2 Events and DOM Level 3 Events</a></h3>

        <p>Numerous clarifications to the interfaces and event types have been made. The <code>HTMLEvents</code> module is no longer defined in this document. The event types <code>focus</code> and <code>blur</code> have been added to the <a href="#events-UIEvent"><code>UIEvent</code></a> module, the event type <code>dblclick</code> has been added to the <a href="#events-MouseEvent"><code>MouseEvent</code></a> module. This new specification provides a better separation between the DOM event flow, the event types, and the DOM interfaces.</p>
        <div>
          <h4><a id="changes-DOMEvents2to3Changes-flow" href="#changes-DOMEvents2to3Changes-flow">E.1.1 Changes to DOM Level 2 event flow</a></h4>

          <p>This new specification introduced the following new concepts in the event flow:</p>
          <ul>
            <li>ordering of event listeners: event listeners are now ordered while ordering was unspecified in DOM Level 2 Events.</li>
            <li>the event flow now includes the <a class="def" href="#glossary-defaultView">defaultView</a> (or <code>window</code>), to reflect existing implementations.</li>
          </ul>
        </div>
<!-- div3 DOMEvents2to3Changes-flow -->
        <div>
          
        <h4><a id="changes-DOMEvents2to3Changes-event-types" href="#changes-DOMEvents2to3Changes-event-types">E.1.2 Changes to DOM Level 2 event types</a></h4>

          <p>Many clarifications have been made on the event types. The conformance is now explicitly defined against the event types, and not only in terms of interfaces required by the event types. Support for the features <code>"BasicEvents"</code>, <code>"TextEvents"</code>, <code>"KeyboardEvents"</code>, and <code>"MutationNameEvents"</code> have been introduced.</p>
          <p>In the most recent drafts of this specification, <code>"MutationEvents"</code> and <code>"MutationNameEvents"</code> have been deprecated. Support for namespaced events, present in early drafts of this specification, has been removed.</p>
          <p>For user agents which support the <a class="eventtype" href="#event-type-DOMNodeInserted"><code>DOMNodeInserted</code></a> and <a class="eventtype" href="#event-type-DOMNodeRemoved"><code>DOMNodeRemoved</code></a> event types, this specification no longer requires that the event type be fired for <code>Attr</code> nodes.</p>            
          <p>The <code>resize</code> event type no longer bubbles, reflecting existing implementations.</p>
        </div>
<!-- div3 DOMEvents2to3Changes-event-types -->
        <div>
          
          <h4><a id="changes-DOMLevel2to3Changes" href="#changes-DOMLevel2to3Changes">E.1.3 Changes to DOM Level 2 Events interfaces</a></h4>

          <dl>
            <dt>Interface <a href="#events-Event"><code>Event</code></a></dt>
            <dd>The <a href="#events-Event"><code>Event</code></a> interface has one new attribute, <a href="#events-event-type-defaultPrevented"><code>Event.defaultPrevented</code></a>, and one new method, <a href="#events-event-type-stopImmediatePropagation"><code>Event.stopImmediatePropagation()</code></a>.<br />
                  <a href="#events-event-type-timeStamp"><code>Event.timeStamp</code></a> is now a <code>Number</code> in the ECMAScript binding; a proposed correction to make the same change in [<cite><a class="normative" href="#references-DOMCore">DOM3 Core</a></cite>] is forthcoming.<br />
    DOM Level 3 Events considers the <a href="#events-event-type-type"><code>Event.type</code></a> attribute to be case-sensitive, while DOM Level 2 Events considers <a href="#events-event-type-type"><code>Event.type</code></a> to be case-insensitive.</dd>

            <dt>Interface <a href="#events-EventTarget"><code>EventTarget</code></a></dt>
            <dd><!-- The <a href="#events-EventTarget"><code>EventTarget</code></a> interface has foo new methods: . --> The method <a href="#events-EventTarget-dispatchEvent"><code>EventTarget.dispatchEvent()</code></a> was modified.</dd>

<!-- <dt>Interface <a href="#events-DocumentEvent"><code>DocumentEvent</code></a></dt>
            <dd>The <a href="#events-DocumentEvent"><code>DocumentEvent</code></a> interface has one new method: <a href="#events-DocumentEvent-canDispatch"><code>DocumentEvent.canDispatch()</code></a>.</dd>
 -->
<!-- <dt>Interface <a href="#events-UIEvent"><code>UIEvent</code></a></dt>
            <dd>The <a href="#events-UIEvent"><code>UIEvent</code></a> interface has a new method <a href="#events-event-type-initUIEvent"><code>UIEvent.initUIEvent()</code></a>.</dd>
 -->
            <dt>Interface <a href="#events-MouseEvent"><code>MouseEvent</code></a></dt>
            <dd>The <a href="#events-MouseEvent"><code>MouseEvent</code></a> interface has one new method <a href="#events-MouseEvent-getModifierState"><code>MouseEvent.getModifierState()</code></a>.</dd>

            <dt>Exception <a href="#events-EventException"><code>EventException</code></a></dt>
            <dd>The <a href="#events-DISPATCH_REQUEST_ERR"><code>DISPATCH_REQUEST_ERR</code></a> constant has been added.</dd>

          </dl>
        </div>
<!-- div3 DOMLevel2to3Changes -->
        <div>
          <h3><a id="changes-DOMLevel3Addons" href="#changes-DOMLevel3Addons">E.1.4 New Interfaces</a></h3>

          <p>The interfaces <a href="#events-CustomEvent"><code>CustomEvent</code></a>, <a href="#events-FocusEvent"><code>FocusEvent</code></a>, <a href="#events-TextEvent"><code>TextEvent</code></a>, <a href="#events-KeyboardEvent"><code>KeyboardEvent</code></a>, <a href="#events-CompositionEvent"><code>CompositionEvent</code></a>, <a href="#events-MutationNameEvent"><code>MutationNameEvent</code></a>, and <a href="#events-WheelEvent"><code>WheelEvent</code></a> were added to the Events module.</p>
        </div>
<!-- div3 DOMLevel3Addons -->
      </div>
<!-- div2 DOMEvents2to3Changes -->
      <div>
        <h2><a id="changes-drafts" href="#changes-drafts">E.2 Changes between different drafts of DOM Level 3 Events</a></h2>

        <p>The DOM Level 3 Events document was previously developed between 2000 and 2003, and and published as a W3C Note, pending further feedback and interest from implementers.  In 2006, it was picked up for revision and progress on the Recommendation Track, and is now being revised to reflect the current state of implementation and the needs of script authors.</p>
        <p>Despite its status only as a W3C Note, rather than an official Recommendation, DOM 3 Events saw some implementation, and reference by other specifications, so care is being taken to cause minimal disruption, while still adapting the specification to the current environment.</p>
        <p>This specification has been reordered significantly from the earlier W3C Note form, and from the structure of DOM2 Events, in order to clarify the material.  New diagrams have been put in place to represent hierarchies and events flows more clearly.  Here are some of the more important changes between drafts:</p>
        <ul>
          <li>The "key identifier" feature has been renamed "key value" to disambiguate them from unique identifiers for keys.</li>
          <li>The <code>change</code>, <code>submit</code>, and <code>reset</code> events were removed, since they were specific to HTML forms, and are specified in HTML5.</li>
          <li>Namespaced events have been removed.</li>
        </ul>
      </div>
    </div>
<!-- div1 Changes -->
<!-- div1 ecma-binding -->


    <div>
      <h2><a id="acknowledgements-contributors" href="#acknowledgements-contributors">Appendix F: Acknowledgements</a></h2>

      <p class="1st">Many people contributed to the DOM specifications (Level 1, 2 or 3), including participants of the DOM Working Group, the DOM Interest Group,the WebAPI Working Group, and the WebApps Working Group. We especially thank the following:</p>
      <p>Andrew Watson (Object Management Group), Andy Heninger (IBM), Angel Diaz (IBM), Arnaud Le Hors (W3C and IBM), Ashok Malhotra (IBM and Microsoft), Ben Chang (Oracle), Bill Smith (Sun), Bill Shea (Merrill Lynch), Bob Sutor (IBM), Chris Lovett (Microsoft), Chris Wilson (Microsoft), David Brownell (Sun), David Ezell (Hewlett-Packard Company), David Singer (IBM), Dimitris Dimitriadis (Improve AB and invited expert), Don Park (invited), Elena Litani (IBM), Eric Vasilik (Microsoft), Gavin Nicol (INSO), Ian Jacobs (W3C), James Clark (invited), James Davidson (Sun), Jared Sorensen (Novell), Jeroen van Rotterdam (X-Hive Corporation), Joe Kesselman (IBM), Joe Lapp (webMethods), Joe Marini (Macromedia), Johnny Stenback (Netscape/AOL), Jon Ferraiolo (Adobe), Jonathan Marsh (Microsoft), Jonathan Robie (Texcel Research and Software AG), Kim Adamson-Sharpe (SoftQuad Software Inc.), Lauren Wood (SoftQuad Software Inc., <em>former Chair</em>), Laurence Cable (Sun), Mark Davis (IBM), Mark Scardina (Oracle), Martin D&#xFC;rst (W3C), Mary Brady (NIST), Mick Goulish (Software AG), Mike Champion (Arbortext and Software AG), Miles Sabin (Cromwell Media), Patti Lutsky (Arbortext), Paul Grosso (Arbortext), Peter Sharpe (SoftQuad Software Inc.), Phil Karlton (Netscape), Philippe Le H&#xE9;garet (W3C, <em>W3C Team Contact and former Chair</em>), Ramesh Lekshmynarayanan (Merrill Lynch), Ray Whitmer (iMall, Excite@Home, and Netscape/AOL, <em>Chair</em>), Rezaur Rahman (Intel), Rich Rollman (Microsoft), Rick Gessner (Netscape), Rick Jelliffe (invited), Rob Relyea (Microsoft), Scott Isaacs (Microsoft), Sharon Adler (INSO), Steve Byrne (JavaSoft), Tim Bray (invited), Tim Yu (Oracle), Tom Pixley (Netscape/AOL), Vidur Apparao (Netscape), Vinod Anupam (Lucent), Anne van Kesteren (Opera Software), Arun Ranganathan (AOL), Bj&#xF6;rn H&#xF6;hrmann, Charles McCathieNevile (Opera Software, <em>Co-Chair</em>), Christophe Jolif (ILOG), Dean Jackson (W3C, <em>W3C Team Contact</em>), Doug Schepers (Vectoreal), Gorm Haug Eriksen (Opera Software), Ian Davis (Talis Information Limited), Ian Hickson (Google), John Robinson (AOL), Jonas Sicking (Mozilla Foundation), Luca Mascaro (HTML Writers Guild), Maciej Stachowiak (Apple Computer), Marc Hadley (Sun Microsystems), Michael Shenfield (Research In Motion), Robin Berjon, (Expway, <em>Co-Chair</em>) , Scott Hayman (Research In Motion), St&#xE9;phane Sire (IntuiLab), and T.V. Raman (Google).</p>
      <br />
      
      <p><strong>Contributors:</strong> In the WebApps Working Group, the following people made substantial material contributions in the process of refining and revising this specification:  Olli Pettay (Mozilla), Hallvord R. M. Steen (Opera), Travis Leithead (Microsoft), Hironori Bono (Google), Daniel Danilatos (Google), Glenn Adams (Samsung), Mark Vickers (Comcast), Bob Lund (Cable Laboratories) and Cameron McCormack (Invited Expert / Mozilla), .</p>
      
      <p><strong>Glossary contributors:</strong> Arnaud Le Hors (W3C) and Robert S. Sutor (IBM Research).</p>
      
      <p><strong>Test suite contributors:</strong> Fred Drake, Mary Brady (NIST), Carmelo Montanez (NIST), Rick Rivello (NIST), Robert Clary (Netscape), Neil Delima (IBM), with a special mention to Curt Arnold.</p>
      
      <p>Thanks to all those who have helped to improve this specification by sending suggestions and corrections (please, keep bugging us with your issues!), or writing informative books or Web sites:  Brad Pettit, Dylan Schiemann, David Flanagan, Steven Pemberton, Curt Arnold, Al Gilman, Misha Wolf, Sigurd Lerstad, Michael B. Allen, Alexander J. Vincent, Martin D&#xFC;rst, Ken Rehor, NAKANO Masayuki, Garrett Smith, Sergey Ilinsky, Martijn Wargers, Sean Hogan, Magnus Kristiansen, Alex Russell, Jorge Chamorro, Peter-Paul Koch, William Edney, Erik Arvidsson, Cameron McCormack, Kazuyuki Ashimura, Øistein E. Andersen, James Su, Tony Chang, Ojan Vafai, Richard Ishida, Paul Irish, Mike Taylor, Oliver Hunt, Alexey Proskuryakov, Giuseppe Pascale, and Jan Goyvaerts (regular-expressions.info).</p>

      <div>
        <h3><a id="acknowledgements-Productions" href="#acknowledgements-Productions">F.1 Production Systems</a></h3>

        <p>The current drafts of this specification are lovingly hand-crafted in HTML and SVG.</p>
        <p>Earlier versions of this specification were written in XML; the HTML, OMG IDL, Java and ECMAScript bindings were all produced automatically.  Thanks to Joe English, author of <a class="normative" href="http://www.flightlab.com/cost">cost</a>, which was used as the basis for producing DOM Level 1. Thanks also to Gavin Nicol, who wrote the scripts which run on top of cost. Arnaud Le Hors and Philippe Le H&#xE9;garet maintained the scripts.</p>
        <p>After DOM Level 1, we used <a class="normative" href="http://xml.apache.org/xerces-j">Xerces</a> as the basis DOM implementation and wish to thank the authors. Philippe Le H&#xE9;garet and Arnaud Le Hors wrote the <a class="normative" href="http://dev.w3.org/cvsweb/java/classes/org/w3c/tools/specgenerator/">Java programs</a> which are the <a class="def" href="#glossary-DOM-application">DOM application</a>.</p>
        <p>Thanks also to Jan K&#xE4;rrman, author of <a class="normative" href="http://user.it.uu.se/~jan/html2ps.html">html2ps</a>, which we use in creating the PostScript version of the specification.</p>
      </div>
<!-- div2 Productions -->
    </div>
    
    
    <div id="references-References">
      <h2 class="references">
        <a id="references-role-references" href="#references-role-references">Appendix G: References</a>
      </h2>
      <p class="1st">For the latest version of any W3C specification please consult the list of <a class="normative" href="http://www.w3.org/TR">W3C Technical Reports</a> available at http://www.w3.org/TR.</p>
      <div>
        <h3><a id="references-References-Normative" href="#references-References-Normative">F.1 Normative References</a></h3>

        <dl>
          <dt id="ref-BCP-47"><strong>[<a id="BCP-47">BCP-47</a>]</strong> Best Current Practice 47: Tags for Identifying Languages
          </dt>
          <dd>A. Phillips, M. Davis, Editors, September 2009. The specification for describing the structure, content, construction, and semantics of language tags to indicate the human language used. Available at <a href="http://www.rfc-editor.org/rfc/bcp/bcp47.txt">http://www.rfc-editor.org/rfc/bcp/bcp47.txt</a></dd>

          <dt>
            <strong>[<a id="references-charmod">CharMod</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2005/REC-charmod-20050215/">Character Model for the World Wide Web 1.0: Fundamentals</a></cite>, M. D&#xFC;rst, F. Yergeau, R. Ishida, M. Wolf, T. Texin, Editors. World Wide Web Consortium, 15 February 2005. This version of the Character Model for the World Wide Web 1.0: Fundamentals specification is http://www.w3.org/TR/2005/REC-charmod-20050215/. The <a class="normative" href="http://www.w3.org/TR/charmod/">latest version of Character Model for the World Wide Web 1.0: Fundamentals</a> is available at http://www.w3.org/TR/charmod/.</dd>

          <dt>
            <strong>[<a id="references-DOMCore">DOM3 Core</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407">Document Object Model Level 3 Core Specification</a></cite>, A. Le Hors, et al., Editors. World Wide Web Consortium, April 2004. This version of the Document Object Model Level 3 Core Specification is http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407. The <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-Core">latest version of DOM Level 3 Core</a> is available at http://www.w3.org/TR/DOM-Level-3-Core.</dd>

          <dt>
            <strong>[<a id="references-DOM2Events">DOM2 Events</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2000/REC-DOM-Level-2-Events-20001113">Document Object Model Level 2 Events Specification</a></cite>, T. Pixley, Editor. World Wide Web Consortium, November 2000. This version of the Document Object Model Level 2 Events Specification is http://www.w3.org/TR/2000/REC-DOM-Level-2-Events-20001113. The <a class="normative" href="http://www.w3.org/TR/DOM-Level-2-Events">latest version of Document Object Model Level 2 Events</a> is available at http://www.w3.org/TR/DOM-Level-2-Events.</dd>

          <dt>
            <strong>[<a id="references-ECMAScript">ECMAScript</a>]</strong>
          </dt>
          <dd><cite>ECMAScript Language Specification</cite>, Third Edition. European Computer Manufacturers Association, Standard ECMA-262, December 1999. This version of the ECMAScript Language is available from http://www.ecma-international.org/.</dd>

          <dt>
            <strong>[<a id="references-Java">Java</a>]</strong>
          </dt>
          <dd><cite><a href="http://java.sun.com/docs/books/jls">The Java Language Specification</a></cite>, J. Gosling, B. Joy, and G. Steele, Authors. Addison-Wesley, September 1996. Available at http://java.sun.com/docs/books/jls</dd>

          <dt>
            <strong>[<a id="references-OMGIDL">OMG IDL</a>]</strong>
          </dt>
          <dd><cite>"OMG IDL Syntax and Semantics"</cite> defined in <cite><a href="http://www.omg.org/technology/documents/formal/corba_2.htm">The Common Object Request Broker: Architecture and Specification, version 2</a></cite>, Object Management Group. The latest version of CORBA version 2.0 is available at http://www.omg.org/technology/documents/formal/corba_2.htm.</dd>

          <dt id="ref-rfc2119"><strong>[<a id="RFC2119">RFC2119</a>]</strong> Key words for use in RFCs to indicate Requirement Levels</dt>
          <dd>S Bradner, 1997. The specification for how to use English to specify normativity, as if it were a technical language. Available at <a href="http://rfc.net/rfc2119.html">http://rfc.net/rfc2119.html</a></dd>

          <dt><strong>[<a id="references-Unicode">Unicode</a>]</strong></dt>
          <dd><cite>The Unicode Standard, Version 5.0</cite>, ISBN 0-321-48091-0, as updated periodically by the publication of new versions. See also <a class="normative" href="http://www.unicode.org/unicode/standard/versions">Versions of the Unicode Standard</a>, available at http://www.unicode.org/unicode/standard/versions, for latest version and additional information on versions of the standard and of the Unicode Character Database.</dd>

          <dt>
            <strong>[<a id="references-UnicodeNormalization">UAX #15</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.unicode.org/reports/tr15/">Unicode Normalization Forms</a></cite>, The Unicode Standard Annex #15. The Unicode Consortium, 2006. The latest version of this annex is available at http://www.unicode.org/reports/tr15/.</dd>

          <dt>
            <strong>[<a id="references-Namespaces10">XML Namespaces 1.0</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2006/REC-xml-names-20060816">Namespaces in XML 1.0</a></cite>, T. Bray, D. Hollander, A. Layman, and R. Tobin, Editors. World Wide Web Consortium, 16 August 2006. This version of the Namespaces in XML 1.0 Specification is http://www.w3.org/TR/2006/REC-xml-names-20060816. The <a class="normative" href="http://www.w3.org/TR/xml-names/">latest version of Namespaces in XML 1.0</a> is available at http://www.w3.org/TR/xml-names/.</dd>

        </dl>
      </div>
      
<!-- div2 References-Informative -->
      <div>
        <h3><a id="references-References-Informative" href="#references-References-Informative">G.2 Informative References</a></h3>

        <dl>
          <dt id="ref-ARIA">
            <strong class="informref">[ARIA]</strong>
          </dt>
          <dd><cite class="w3cwd"><a href="http://www.w3.org/TR/2009/WD-wai-aria-20091215/">Accessible Rich Internet Applications (WAI-ARIA) Version 1.0</a></cite>,
            M. Cooper, R. Schwerdtfeger, L. Seeman, L. Pappas, eds.
            World Wide Web Consortium, <span class="wip">work in progress</span>, 15 December 2009.
            <br />This edition of WAI-ARIA is http://www.w3.org/TR/2009/WD-wai-aria-20091215/.
            <br />The <a href="http://www.w3.org/TR/wai-aria/">latest edition of WAI-ARIA</a> is available at
            http://www.w3.org/TR/wai-aria/.
          </dd>

          <dt id="ref-xforms">
            <strong class="informref">[XFORMS]</strong>
          </dt>
          <dd><cite class="w3crec"><a href="http://www.w3.org/TR/2009/REC-xforms-20091020/">XForms 1.1</a></cite>,
            J. Boyer, ed.
            World Wide Web Consortium, <span class="wip">work in progress</span>, 20 October 2009.
            <br />This edition of XForms 1.1 is http://www.w3.org/TR/2009/REC-xforms-20091020/.
            <br />The <a href="http://www.w3.org/TR/xforms/">latest edition of XForms</a> is available at
            http://www.w3.org/TR/xforms/.
          </dd>

          <dt class="wip">
            <strong>[<a id="references-CSS2">CSS2</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2009/CR-CSS2-20090908">Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification</a></cite>, B. Bos, T. &#xC7;elik, I. Hickson, H.W. Lie, Editors. World Wide Web Consortium, 08 September 2009, <strong>Work in Progress</strong>. This version of the CSS 2.1 Specification is http://www.w3.org/TR/2009/CR-CSS2-20090908. The <a class="normative" href="http://www.w3.org/TR/CSS2/">latest version of CSS 2.1</a> is available at http://www.w3.org/TR/CSS2/.</dd>

          <dt>
            <strong>[<a id="references-DOMLS">DOM3 Load and Save</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2004/REC-DOM-Level-3-LS-20040407">Document Object Model Level 3 Load and Save Specification</a></cite>, J. Stenback, A. Heninger, Editors. World Wide Web Consortium, April 2004. This version of the DOM Level 3 Load and Save Specification is http://www.w3.org/TR/2004/REC-DOM-Level-3-LS-20040407. The <a class="normative" href="http://www.w3.org/TR/DOM-Level-3-LS">latest version of DOM Level 3 Load and Save</a> is available at http://www.w3.org/TR/DOM-Level-3-LS.</dd>

          <dt>
            <strong>[<a id="references-DWW95">DWW95</a>]</strong>
          </dt>
          <dd><cite>Developing International Software for Windows 95 and Windows NT: A Handbook for International Software Design</cite>, N. Kano, Author. Microsoft Press, 1995. ISBN 1-55615-840-8.</dd>

          <dt>
            <strong>[<a id="references-HTML40">HTML 4.01</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01 Specification</a></cite>, D. Raggett, A. Le Hors, and I. Jacobs, Editors. World Wide Web Consortium, December 1999. This version of the HTML 4.01 Recommendation is http://www.w3.org/TR/1999/REC-html401-19991224. The <a class="normative" href="http://www.w3.org/TR/html4">latest version of HTML 4</a> is available at http://www.w3.org/TR/html4.</dd>

          <dt id="references-HTML5">
            <strong class="informref">[HTML5]</strong>
          </dt>
          <dd><cite class="w3cwd"><a href="http://www.w3.org/TR/2009/WD-html5-20090825/">HTML 5</a></cite>,
            I. Hickson, editor.
            World Wide Web Consortium, <span class="wip">work in progress</span>, 24 June 2010.
            <br />This edition of HTML 5 is http://www.w3.org/TR/2010/WD-html5-20100624/.
            <br />The <a href="http://www.w3.org/TR/html5/">latest edition of HTML 5</a> is available at
            http://www.w3.org/TR/html5/.
          </dd>

          <dt>
            <strong>[<a id="references-ISO-9995-2-3">ISO9995-2/3</a>]</strong>
          </dt>
          <dd>
            <cite>
              <a href="http://www.iso.org/iso/search.htm?qt=9995&amp;published=on">ISO/IEC 9995, Information technology -- Keyboard layouts for text and office systems -- Part 2: Alphanumeric Section and Part 3: Complementary layouts of the alphanumeric zone of the alphanumeric section.</a>
            </cite>
          </dd>

          <dt>
            <strong>[<a id="references-ISO-9995-8">ISO9995-8</a>]</strong>
          </dt>
          <dd>
            <cite>
              <a href="http://www.iso.org/iso/search.htm?qt=9995&amp;published=on">ISO/IEC 9995-8:2006, Information technology -- Keyboard layouts for text and office systems -- Part 8: Allocation of letters to the keys of a numeric keypad.</a>
            </cite>
          </dd>

          <dt>
            <strong>[<a id="references-KeyEvent">KeyEvent for Java</a>]</strong>
          </dt>
          <dd><cite><a href="http://java.sun.com/javase/6/docs/api/java/awt/event/KeyEvent.html">Java&#x2122; Platform, Standard Edition 6 API Specification, Class java.awt.events.KeyEvent</a></cite>. Sun Microsystems. Available at http://java.sun.com/javase/6/docs/api/java/awt/event/KeyEvent.html.</dd>

          <dt>
            <strong>[<a id="references-Keys">Keys enumeration for .Net</a>]</strong>
          </dt>
          <dd><cite><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.keys%28VS.100,loband%29.aspx">.NET Framework 4.0 Class Library, Keys Enumeration</a></cite>. Microsoft. Available at http://msdn.microsoft.com/en-us/library/system.windows.forms.keys(VS.100,loband).aspx.</dd>


          <dt id="references-KeyProps">
            <strong class="informref">[KeyProps]</strong>
          </dt>
          <dd><cite class="w3cwd"><a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/Note-KeyProps.html">Legacy Keyboard Event Properties</a></cite>,
            D. Schepers, editor.
            World Wide Web Consortium, <span class="wip">work in progress</span>, 04 August 2010.
            <br />This edition of Legacy Keyboard Event Properties is http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/Note-KeyProps.html.
            <br />The <a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/Note-KeyProps.html">latest edition of Legacy Keyboard Event Properties</a> is available at
            http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/Note-KeyProps.html.
          </dd>


          <dt>
            <strong>[<a id="references-pcre">PCRE</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.pcre.org/">Perl Compatible Regular Expressions library</a></cite>.  Available at http://www.pcre.org/.</dd>


          <dt id="ref-rfc20"><strong>[<a id="RFC20">RFC20</a>]</strong>ASCII format for Network Interchange</dt>
          <dd>V. Cerf, 1969. Available at <a href="http://tools.ietf.org/rfc/rfc20.txt">http://tools.ietf.org/rfc/rfc20.txt</a></dd>

          <dt id="ref-US-ASCII"><strong>[<a id="US-ASCII">US-ASCII</a>]</strong>Coded Character Set - 7-Bit American Standard Code for Information Interchange</dt>
          <dd>Standard ANSI X3.4-1986, ANSI, 1986.</dd>

          <dt>
            <strong class="informref">[<a id="references-UAAG2">UAAG 2.0</a>]</strong>
          </dt>
          <dd>
            <cite><a href="http://www.w3.org/WAI/UA/2010/ED-UAAG20-20100308/">User Agent Accessibility Guidelines (UAAG) 2.0</a></cite>, 
            J. Allan, K. Ford, J. Richards, J. Spellman, editors.  
            World Wide Web Consortium, <span class="wip">work in progress</span>, 8 March 2010.  
            This version of the UAAG 2.0 specfication is http://www.w3.org/WAI/UA/2010/ED-UAAG20-20100308/. The <a class="normative" href="http://www.w3.org/TR/UAAG20/">latest version of UAAG 2.0</a> is available at http://www.w3.org/TR/UAAG20/.
          </dd>
          <dt id="references-WebIDL">
            <strong class="WebIDL">[Web IDL]</strong>
          </dt>
          <dd><cite class="w3cwd"><a href="http://www.w3.org/TR/2010/WD-WebIDL-20101021/">Web IDL</a></cite>,
            C. McCormack, editor.
            World Wide Web Consortium, <span class="wip">work in progress</span>, 21 October 2010.
            <br />This edition of Web IDL is http://www.w3.org/TR/2010/WD-WebIDL-20101021/.
            <br />The <a href="http://www.w3.org/TR/WebIDL/">latest edition of Web IDL</a> is available at http://www.w3.org/TR/WebIDL/.
          </dd>

          <dt>
            <strong>[<a id="references-XML">XML 1.0</a>]</strong>
          </dt>
          <dd><cite><a href="http://www.w3.org/TR/2006/REC-xml-20060816">Extensible Markup Language (XML) 1.0</a></cite>, T. Bray, J. Paoli, C. M. Sperberg-McQueen, et. al, Editors. World Wide Web Consortium, August 2006. This version of the XML 1.0 Recommendation is http://www.w3.org/TR/2006/REC-xml-20060816. The <a class="normative" href="http://www.w3.org/TR/xml">latest version of XML 1.0</a> is available at http://www.w3.org/TR/xml.</dd>

          <dt><strong>[<a id="references-DASE">DASE</a>]</strong></dt>
          <dd><cite><a href="http://www.atsc.org/cms/standards/a100/a_100_2.pdf">ATSC A/100-2, DTV Application Software Environment Level 1 (DASE-1) Part 2: Declarative Applications and Environment</a></cite>.  Advanced Television Systems Committee, 09 March 2003. Available at <a href="http://www.atsc.org/cms/standards/a100/a_100_2.pdf">http://www.atsc.org/cms/standards/a100/a_100_2.pdf</a>.</dd>

          <dt><strong>[<a id="references-OCAP">OCAP</a>]</strong></dt>
          <dd><cite><a href="http://www.cablelabs.com/specifications/OC-SP-OCAP1.1.3-100603.pdf">Open Cable Application Platform 1.1.3</a></cite>.  Cable Television Laboratories, Inc., 03 June 2010. Available at <a href="http://www.cablelabs.com/specifications/OC-SP-OCAP1.1.3-100603.pdf">http://www.cablelabs.com/specifications/OC-SP-OCAP1.1.3-100603.pdf</a>.</dd>

          <dt><strong>[<a id="references-WEB4CE">WEB4CE</a>]</strong></dt>
          <dd><cite><a href="http://www.ce.org/Standards/browseByCommittee_2757.asp">ANSI/CEA-2014-B, Web-based Protocol and Framework for Remote User Interface on UPnPTM Networks and the Internet (Web4CE)</a></cite>. Consumer Electronics Association, January 2011. Available at <a href="http://www.ce.org/Standards/browseByCommittee_2757.asp">http://www.ce.org/Standards/browseByCommittee_2757.asp</a>.</dd>
        </dl>
      </div>
<!-- div2 References-Informative -->
    </div>
<!-- div1 References -->
  </body>
</html>