--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/respecEdConfig.js Tue Dec 04 11:08:43 2012 -0800
@@ -0,0 +1,27 @@
+// Configuration for the Editor's Draft of DOM Parsing and Serialization
+
+var respecConfig = {
+ specStatus: "ED",
+ editors: [
+ {
+ name: "Travis Leithead",
+ company: "Microsoft Corp.",
+ url: "mailto:travis.leithead@microsoft.com?subject=%5BD4E%5D%20Spec%20Feedback",
+ companyURL: "http://www.microsoft.com"
+ }
+ ],
+ //publishDate: "2012-09-20",
+ edDraftURI: "http://dvcs.w3.org/hg/dom4events/raw-file/tip/index.html",
+ previousPublishDate: null,
+ prevED: undefined,
+ noIDLIn: true,
+ inlineCSS: true,
+ //noRecTrack: true,
+ shortName: "dom4events",
+ extraCSS: ["http://dev.w3.org/2009/dap/ReSpec.js/css/respec.css"],
+ wg: ["Web Applications Working Group"],
+ wgURI: ["http://www.w3.org/2008/webapps/"],
+ wgPublicList: "www-dom",
+ wgPatentURI: ["http://www.w3.org/2004/01/pp-impl/42538/status"],
+ maxTocLevel: 2
+};
\ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/source_respec.htm Tue Dec 04 11:08:43 2012 -0800
@@ -0,0 +1,390 @@
+<!DOCTYPE html>
+
+<html>
+<head>
+ <meta charset="utf-8" />
+ <title>DOM4 Events</title>
+ <script type="text/javascript" src='http://darobin.github.com/respec/builds/respec-w3c-common.js' class='remove'></script>
+ <script type="text/javascript" src="respecEdConfig.js" class='remove'></script>
+</head>
+<body>
+ <section id="abstract">
+ <p>This specification defines the Document Object Model Events Level 4,
+ which extends the events and features defined in DOM Events Level 3.</p>
+ </section>
+
+ <section id="sotd">
+ <p>Comments submitted in regard to this document should have their subject
+ line prefixed with the string <q>[D4E]</q> to help facilitate
+ tracking on the
+ <a href="http://lists.w3.org/Archives/Public/www-dom/">www-dom
+ mailing list</a>.</p>
+ </section>
+
+ <section id="conformance">
+ <p>All diagrams, examples, and notes in this specification are non-normative,
+ as are all sections explicitly marked non-normative. Everything else in
+ this specification is normative.</p>
+
+ <p>Requirements phrased in the imperative as part of algorithms(such as "strip
+ any leading space characters" or "return false and terminate these steps")
+ are to be interpreted with the meaning of the key word ("must", "should",
+ "may", etc) used in introducing the algorithm.</p>
+
+ <p>Conformance requirements phrased as algorithms or specific steps may be
+ implemented in any manner, so long as the end result is equivalent.
+ (In particular, the algorithms defined in this specification are intended
+ to be easy to follow, and not intended to be performant.)</p>
+
+ <p>User agents may impose implementation-specific limits on otherwise
+ unconstrained inputs, e.g. to prevent denial of service attacks, to guard
+ against running out of memory, or to work around platform-specific
+ limitations.</p>
+
+ <p>When a method or an attribute is said to call another method or attribute,
+ the user agent must invoke its internal API for that attribute or method so
+ that e.g. the author can't change the behavior by overriding attributes or
+ methods with custom properties or functions in ECMAScript.</p>
+
+ <p>Unless otherwise stated, string comparisons are done in a case-sensitive
+ manner.</p>
+
+ <p>Implementations of this spec must also implement the following event
+ constructor dictionary defined in [[!DOM4]]:</p>
+
+ <ul>
+ <li><code>EventInit</code></li>
+ </ul>
+ </section>
+
+ <section id="goals">
+ <h1>Goals</h1>
+ <p>DOM4 Events builds on the event model defined in DOM Level 3 Events
+ (and also DOM4). Features in scope for this specification are:</p>
+
+ <ul>
+ <li>Methods for creating and dispatching synthetic events (event constructors)</li>
+ <li>Additional Keyboard event properties to allow for physical key location scenarios</li>
+ </ul>
+ </section>
+
+ <section id="event-constructors">
+ <h1>Event Constructors</h1>
+
+ <p><em>This section is informative</em></p>
+
+ <p>DOM Level 3 Events defines several events, but does not normatively provide a
+ mechanism for programmatically-creating those events. Traditionally, an
+ <code>init*Event</code> method was defined, but the parameter list to such
+ methods became cumbersome and required an explicit order that was hard to
+ maintain without the help of a tool.
+ </p>
+
+ <p>For each event interface defined in [[!DOM-LEVEL-3-EVENTS]], there exists an initialization
+ method for synthesizing untrusted events. This mechanism does not scale well
+ to event interfaces with many members. Event Constructors (introduced for
+ the Event interface in [[DOM4]]) are a mechanism for creating and
+ initializing untrusted event objects more easily.
+ </p>
+
+ <p class="note"><strong>Example: </strong>Synthesizing an untrusted event <b>using legacy initialization
+ methods:</b><tt style="white-space: pre">
+var event = document.createEvent("MouseEvent");
+event.initMouseEvent("mouseover",
+ true,
+ true,
+ window,
+ null,
+ null,
+ null,
+ 0,
+ 0,
+ null,
+ null,
+ null,
+ null,
+ previousEventTarget);
+eventTarget.dispatchEvent(event); </tt></p>
+
+ <p class="note"><strong>Example: </strong>Synthesizing an untrusted event <b>using constructors</b>:<tt style="white-space: pre">
+var event = new MouseEvent("mouseover",
+ {bubbles: true,
+ cancelable: true,
+ relatedTarget: previousEventTarget
+ });
+eventTarget.dispatchEvent(event);</tt>
+ </p>
+
+ <p>In the above example, the author only has to set the event object properties
+ that he or she wants. Using legacy initialization methods, such as
+ <code>initMouseEvent()</code>, often requires the author to specify values
+ for numerous additional properties that are not needed.
+ </p>
+
+ <p>The following sections define constructors for the interfaces from DOM3 Events
+ [[!DOM-LEVEL-3-EVENTS]].
+ </p>
+
+ <section id="constructor-uievent">
+ <h2><code>UIEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString type, optional UIEventInit eventInitDict)] partial interface UIEvent : Event">
+ </dl>
+
+ <dl class="idl" title="dictionary UIEventInit : EventInit">
+ <dt>Window? view = null</dt>
+ <dd>Should be initialized to the Window object of the global environment
+ in which this event will be dispatched. If this event will be dispatched
+ to an element, the view property should be set to the Window object
+ containing the element's <code>ownerDocument</code>.
+ </dd>
+ <dt>long detail = 0</dt>
+ <dd>This value is initialized to a number that is application-specific.</dd>
+ </dl>
+ </section>
+
+ <section id="constructor-focusevent">
+ <h2><code>FocusEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString typeArg, optional FocusEventInit focusEventInitDict)] partial interface FocusEvent: UIEvent">
+ </dl>
+
+ <dl class="idl" title="dictionary FocusEventInit : UIEventInit">
+ <dt>EventTarget? relatedTarget = null</dt>
+ <dd>The <code>relatedTarget</code> should be initialized to the element
+ losing focus (in the case of a <em>focus</em> or <em>focusin</em>
+ event) or the element gaining focus (in the case of a <em>blur</em>
+ or <em>focusout</em> event).
+ </dd>
+ </dl>
+ </section>
+
+ <section id="constructor-mouseevent">
+ <h2><code>MouseEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString typeArg, optional MouseEventInit mouseEventInitDict)] partial interface MouseEvent: UIEvent">
+ </dl>
+
+ <dl class="idl" title="dictionary MouseEventInit : UIEventInit">
+ <dt>long screenX = 0</dt>
+ <dd>See <code>screenY</code> (substituting "horizontal" for "veritcal")</dd>
+ <dt>long screenY = 0</dt>
+ <dd>Initializes the <code>screenY</code> attribute of the MouseEvent
+ object to the desired vertical relative position of the mouse
+ pointer on the user's screen.
+
+ <p>Initializing the event object to the given mouse position must
+ not move the user's mouse pointer to the initialized position.
+ </p>
+ </dd>
+ <dt>long clientX = 0</dt>
+ <dd>See <code>clientY</code> (substituting "horizontal" for "vertical")</dd>
+ <dt>long clientY = 0</dt>
+ <dd>Initializes the <code>clientY</code> attribute of the MouseEvent
+ object to the desired vertical position of the mouse pointer
+ relative to the client window of the user's browser.
+
+ <p>Initializing the event object to the given mouse position must
+ not move the user's mouse pointer to the initialized position.
+ </p>
+
+ <p class="issue"><strong>Issue: </strong>Some user agents automatically
+ convert the values of clientX and clientY into other implementation-
+ specific mouse pointer position properties, such as: offsetX, offsetY,
+ pageX, pageY, x, and y.
+ </p>
+ </dd>
+ <dt>boolean ctrlKey = false</dt>
+ <dd>Initializes the <code>ctrlKey</code> attribute of the MouseEvent
+ object to <code>true</code> if the <code>ctrlKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean shiftKey = false</dt>
+ <dd>Initializes the <code>shiftKey</code> attribute of the MouseEvent
+ object to <code>true</code> if the <code>shiftKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean altKey = false</dt>
+ <dd>Initializes the <code>altKey</code> attribute of the MouseEvent
+ object to <code>true</code> if the <code>altKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean metaKey = false</dt>
+ <dd>Initializes the <code>metaKey</code> attribute of the MouseEvent
+ object to <code>true</code> if the <code>metaKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>unsigned short button = 0</dt>
+ <dd>
+ Initializes the <code>button</code> attribute of the MouseEvent
+ object to a number representing one of the button(s) of the mouse
+ that is to be considered active.
+
+ <p class="note"><strong>Note: </strong>The value 0 is used to represent
+ the primary mouse button, 1 is used to represent the auxillery/
+ middle mouse button, and 2 to represent the right mouse button.
+ Numbers greater than 2 are also possible, but not well-defined
+ in DOM Level 3 Events [[DOM-LEVEL-3-EVENTS]].
+ </p>
+ </dd>
+ <dt>unsigned short buttons = 0</dt>
+ <dd>
+ Initializes the <code>buttons</code> attribute of the MouseEvent
+ object to a number representing one <em>or more</em> of the button(s) of the mouse
+ that are to be considered active.
+
+ <p class="note"><strong>Note: </strong>The <code>buttons</code>
+ attribute is a bit-field. To apply a value according to the
+ definition in DOM Level 3 Events [[DOM-LEVEL-3-EVENTS]], first, determine the
+ buttons that are to be considered active, then apply a bit-wise
+ OR operation the the result set. The value 1 is used to represent
+ the primary mouse button, 2 to represent the right mouse button,
+ and 4 to represent the auxillery/middle button. Numbers greater
+ than 4 are also possible and should be subsequent powers of 2 (8,
+ 16, etc.), but these additional values are not well-defined in DOM
+ Level 3 Events.
+ </p>
+ <p class="note"><strong>Example:</strong> In JavaScript, to initialize the
+ <code>buttons</code> attribute as if the right (2) and middle
+ button (4) were being pressed simultaneously, the buttons value
+ can be assigned as either:<br />
+ <code>{ buttons: 2 | 4 }</code><br />
+ or:<br />
+ <code>{ buttons: 6 }</code>
+ </p>
+ </dd>
+ <dt>EventTarget? relatedTarget = null</dt>
+ <dd>The <code>relatedTarget</code> should be initialized to the element
+ whose bounds the mouse pointer just left (in the case of a
+ <em>mouseover</em> or <em>mouseenter</em> event) or the element
+ whose bounds the mouse pointer is entering (in the case of a
+ <em>mouseout</em> or <em>mouseleave</em>
+ or <em>focusout</em> event). For other events, this value need not
+ be assigned (and will default to null).
+ </dd>
+ </dl>
+ </section>
+
+ <section id="constructor-wheelevent">
+ <h2><code>WheelEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString typeArg, optional WheelEventInit wheelEventInitDict)] partial interface WheelEvent: MouseEvent">
+ </dl>
+
+ <dl class="idl" title="dictionary WheelEventInit: MouseEventInit">
+ <dt>double deltaX = 0.0</dt>
+ <dd>See <code>deltaZ</code> attribute.</dd>
+ <dt>double deltaY = 0.0</dt>
+ <dd>See <code>deltaZ</code> attribute.</dd>
+ <dt>double deltaZ = 0.0</dt>
+ <dd>Initializes the <code>deltaZ</code> attribute of the WheelEvent object.
+ Relative positive values for this attribute (as well as the
+ <code>deltaX</code> and <code>deltaY</code> attributes) are given by
+ a right-hand coordinate system where the 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. Negative
+ relative values are in the respective opposite directions.
+ </dd>
+ <dt>unsigned long deltaMode = 0</dt>
+ <dd>Initializes the <code>deltaMode</code> attribute on the WheelEvent
+ object to the enumerated values 0, 1, or 2, which represent the amount
+ of pixels scrolled (DOM_DELTA_PIXEL), lines scrolled (DOM_DELTA_LINE),
+ or pages scrolled (DOM_DELTA_PAGE) if the rotation of the wheel would
+ have resulted in scrolling.
+ </dd>
+ </dl>
+ </section>
+
+ <section id="constructor-keyboardevent">
+ <h2><code>KeyboardEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString typeArg, optional KeyboardEventInit keyboardEventInitDict)] partial interface KeyboardEvent: UIEvent">
+ </dl>
+
+ <dl class="idl" title="dictionary KeyboardEventInit : UIEventInit">
+ <dt>DOMString char = ""</dt>
+ <dd>Initializes the <code>char</code> attribute of the KeyboardEvent
+ object to the unicode character string representing a printable
+ character. If the related <code>key</code> value is not a printable
+ character, then this attribute should be assigned the empty string
+ (which is the default value).
+ </dd>
+ <dt>DOMString key = ""</dt>
+ <dd>Initializes the <code>key</code> attribute of the KeyboardEvent
+ object to the unicode character string representing the meaning of a
+ key after taking into account all keyboard modifications (such as
+ shift-state). This value is the final effective value of the key.
+ If the key is not a printable character, then it should be one of
+ the key values defined in [[DOM-LEVEL-3-EVENTS]].
+ </dd>
+ <dt>unsigned long location = 0</dt>
+ <dd>
+ Initializes the <code>location</code> attribute of the KeyboardEvent
+ object to one of the following location numerical constants:
+ <ul>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_STANDARD</code> (numerical value 0)</li>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_LEFT</code> (numerical value 1)</li>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_RIGHT</code> (numerical value 2)</li>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_NUMPAD</code> (numerical value 3)</li>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_MOBILE</code> (numerical value 4)</li>
+ <li><code>KeyboardEvent.DOM_KEY_LOCATION_JOYSTICK</code> (numerical value 5)</li>
+ </ul>
+ </dd>
+ <dt>boolean ctrlKey = false</dt>
+ <dd>Initializes the <code>ctrlKey</code> attribute of the KeyboardEvent
+ object to <code>true</code> if the <code>ctrlKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean shiftKey = false</dt>
+ <dd>Initializes the <code>shiftKey</code> attribute of the KeyboardEvent
+ object to <code>true</code> if the <code>shiftKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean altKey = false</dt>
+ <dd>Initializes the <code>altKey</code> attribute of the KeyboardEvent
+ object to <code>true</code> if the <code>altKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean metaKey = false</dt>
+ <dd>Initializes the <code>metaKey</code> attribute of the KeyboardEvent
+ object to <code>true</code> if the <code>metaKey</code> modifier
+ key is to be considered depressed, <code>false</code> otherwise.
+ </dd>
+ <dt>boolean repeat = false</dt>
+ <dd>Initializes the <code>repeat</code> attribute of the KeyboardEvent
+ object to <code>true</code> if the the current KeyboardEvent is
+ considered part of a repeating sequence of similar events caused
+ by the long depression of any single key, <code>false</code> otherwise.
+ </dd>
+ <dt>DOMString locale = ""</dt>
+ <dd>Initializes the <code>locale</code> attribute of the KeyboardEvent
+ object to a BCP-47 string. This string should reflect the current language
+ that the keyboard originaing this event is configured to, for example <code>"en-US"</code>
+ for a keyboard configured for US English input. This value may be the
+ empty string if the locale of the given input is unknown.
+ </dd>
+ </dl>
+ </section>
+
+ <section id="constructor-compositionevent">
+ <h2><code>CompositionEvent</code> Constructor</h2>
+
+ <dl class="idl" title="[Constructor(DOMString typeArg, optional CompositionEventInit compositionEventInitDict)] partial interface CompositionEvent: UIEvent">
+ </dl>
+
+ <dl class="idl" title="dictionary CompositionEventInit : UIEventInit">
+ <dt>DOMString? data = ""</dt>
+ <dd>Initializes the <code>data</code> attribute of the CompositionEvent
+ object to the characters generated by the IME composition.
+ </dd>
+ <dt>DOMString locale = ""</dt>
+ <dd>Initializes the <code>locale</code> attribute of the CompositionEvent
+ object to a BCP-47 string. This string should reflect the current language
+ that the IME originaing this event is configured to, for example <code>"ja"</code>
+ for an IME configured for Japanese input. This value may be the
+ empty string if the locale of the IME is unknown.
+ </dd>
+ </dl>
+ </section>
+</body>
+</html>
\ No newline at end of file