mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Clean up whitespace, long lines for WebIDLs
This commit is contained in:
parent
d1acefa452
commit
9415c92a5c
15 changed files with 63 additions and 31 deletions
|
@ -5,7 +5,8 @@
|
|||
|
||||
// http://dev.w3.org/2006/webapi/FileAPI/#dfn-Blob
|
||||
//[Exposed=Window,Worker][Constructor,
|
||||
// Constructor(sequence<(ArrayBuffer or ArrayBufferView or Blob or DOMString)> blobParts, optional BlobPropertyBag options)]
|
||||
// Constructor(sequence<(ArrayBuffer or ArrayBufferView or Blob or DOMString)> blobParts,
|
||||
// optional BlobPropertyBag options)]
|
||||
[Constructor,
|
||||
Constructor(DOMString blobParts, optional BlobPropertyBag options)]
|
||||
interface Blob {
|
||||
|
|
|
@ -94,14 +94,18 @@ interface CanvasRenderingContext2D {
|
|||
void clip(optional CanvasWindingRule fillRule = "nonzero");
|
||||
//void clip(Path2D path, optional CanvasWindingRule fillRule = "nonzero");
|
||||
//void resetClip();
|
||||
//boolean isPointInPath(unrestricted double x, unrestricted double y, optional CanvasWindingRule fillRule = "nonzero");
|
||||
//boolean isPointInPath(Path2D path, unrestricted double x, unrestricted double y, optional CanvasWindingRule fillRule = "nonzero");
|
||||
//boolean isPointInPath(unrestricted double x, unrestricted double y,
|
||||
// optional CanvasWindingRule fillRule = "nonzero");
|
||||
//boolean isPointInPath(Path2D path, unrestricted double x, unrestricted double y,
|
||||
// optional CanvasWindingRule fillRule = "nonzero");
|
||||
//boolean isPointInStroke(unrestricted double x, unrestricted double y);
|
||||
//boolean isPointInStroke(Path2D path, unrestricted double x, unrestricted double y);
|
||||
|
||||
// text (see also the CanvasDrawingStyles interface)
|
||||
//void fillText(DOMString text, unrestricted double x, unrestricted double y, optional unrestricted double maxWidth);
|
||||
//void strokeText(DOMString text, unrestricted double x, unrestricted double y, optional unrestricted double maxWidth);
|
||||
//void fillText(DOMString text, unrestricted double x, unrestricted double y,
|
||||
// optional unrestricted double maxWidth);
|
||||
//void strokeText(DOMString text, unrestricted double x, unrestricted double y,
|
||||
// optional unrestricted double maxWidth);
|
||||
//TextMetrics measureText(DOMString text);
|
||||
|
||||
// drawing images
|
||||
|
@ -128,7 +132,10 @@ interface CanvasRenderingContext2D {
|
|||
[Throws]
|
||||
ImageData getImageData(double sx, double sy, double sw, double sh);
|
||||
void putImageData(ImageData imagedata, double dx, double dy);
|
||||
void putImageData(ImageData imagedata, double dx, double dy, double dirtyX, double dirtyY, double dirtyWidth, double dirtyHeight);
|
||||
void putImageData(ImageData imagedata,
|
||||
double dx, double dy,
|
||||
double dirtyX, double dirtyY,
|
||||
double dirtyWidth, double dirtyHeight);
|
||||
};
|
||||
|
||||
[NoInterfaceObject]
|
||||
|
@ -147,7 +154,8 @@ interface CanvasDrawingStyles {
|
|||
// text
|
||||
//attribute DOMString font; // (default 10px sans-serif)
|
||||
//attribute DOMString textAlign; // "start", "end", "left", "right", "center" (default: "start")
|
||||
//attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic", "ideographic", "bottom" (default: "alphabetic")
|
||||
//attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic",
|
||||
// "ideographic", "bottom" (default: "alphabetic")
|
||||
//attribute DOMString direction; // "ltr", "rtl", "inherit" (default: "inherit")
|
||||
};
|
||||
|
||||
|
@ -157,7 +165,8 @@ interface CanvasPathMethods {
|
|||
void closePath();
|
||||
void moveTo(unrestricted double x, unrestricted double y);
|
||||
void lineTo(unrestricted double x, unrestricted double y);
|
||||
void quadraticCurveTo(unrestricted double cpx, unrestricted double cpy, unrestricted double x, unrestricted double y);
|
||||
void quadraticCurveTo(unrestricted double cpx, unrestricted double cpy,
|
||||
unrestricted double x, unrestricted double y);
|
||||
|
||||
void bezierCurveTo(unrestricted double cp1x,
|
||||
unrestricted double cp1y,
|
||||
|
@ -170,16 +179,19 @@ interface CanvasPathMethods {
|
|||
void arcTo(unrestricted double x1, unrestricted double y1,
|
||||
unrestricted double x2, unrestricted double y2,
|
||||
unrestricted double radius);
|
||||
// NOT IMPLEMENTED [LenientFloat] void arcTo(double x1, double y1, double x2, double y2, double radiusX, double radiusY, double rotation);
|
||||
// [LenientFloat] void arcTo(double x1, double y1, double x2, double y2,
|
||||
// double radiusX, double radiusY, double rotation);
|
||||
|
||||
void rect(unrestricted double x, unrestricted double y, unrestricted double w, unrestricted double h);
|
||||
|
||||
[Throws]
|
||||
void arc(double x, double y, double radius, double startAngle, double endAngle, optional boolean anticlockwise = false);
|
||||
// NOT IMPLEMENTED [LenientFloat] void ellipse(double x, double y, double radiusX, double radiusY, double rotation, double startAngle, double endAngle, boolean anticlockwise);
|
||||
void arc(double x, double y, double radius, double startAngle, double endAngle,
|
||||
optional boolean anticlockwise = false);
|
||||
// [LenientFloat] void ellipse(double x, double y, double radiusX, double radiusY,
|
||||
// double rotation, double startAngle, double endAngle,
|
||||
// boolean anticlockwise);
|
||||
};
|
||||
|
||||
|
||||
CanvasRenderingContext2D implements CanvasDrawingStyles;
|
||||
CanvasRenderingContext2D implements CanvasPathMethods;
|
||||
|
||||
|
|
|
@ -59,9 +59,11 @@ interface Document : Node {
|
|||
|
||||
// NodeFilter.SHOW_ALL = 0xFFFFFFFF
|
||||
[NewObject]
|
||||
NodeIterator createNodeIterator(Node root, optional unsigned long whatToShow = 0xFFFFFFFF, optional NodeFilter? filter = null);
|
||||
NodeIterator createNodeIterator(Node root, optional unsigned long whatToShow = 0xFFFFFFFF,
|
||||
optional NodeFilter? filter = null);
|
||||
[NewObject]
|
||||
TreeWalker createTreeWalker(Node root, optional unsigned long whatToShow = 0xFFFFFFFF, optional NodeFilter? filter = null);
|
||||
TreeWalker createTreeWalker(Node root, optional unsigned long whatToShow = 0xFFFFFFFF,
|
||||
optional NodeFilter? filter = null);
|
||||
};
|
||||
Document implements ParentNode;
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#the-errorevent-interface
|
||||
// https://html.spec.whatwg.org/multipage/#the-errorevent-interface
|
||||
|
||||
[Constructor(DOMString type, optional ErrorEventInit eventInitDict)/*, Exposed=(Window,Worker)*/]
|
||||
interface ErrorEvent : Event {
|
||||
|
|
|
@ -16,7 +16,9 @@ callback EventHandlerNonNull = any (Event event);
|
|||
typedef EventHandlerNonNull? EventHandler;
|
||||
|
||||
[TreatNonObjectAsNull]
|
||||
callback OnErrorEventHandlerNonNull = boolean ((Event or DOMString) event, optional DOMString source, optional unsigned long lineno, optional unsigned long column, optional any error);
|
||||
callback OnErrorEventHandlerNonNull = boolean ((Event or DOMString) event, optional DOMString source,
|
||||
optional unsigned long lineno, optional unsigned long column,
|
||||
optional any error);
|
||||
typedef OnErrorEventHandlerNonNull? OnErrorEventHandler;
|
||||
|
||||
[NoInterfaceObject]
|
||||
|
|
|
@ -64,7 +64,8 @@ interface HTMLInputElement : HTMLElement {
|
|||
// attribute unsigned long selectionEnd;
|
||||
// attribute DOMString selectionDirection;
|
||||
//void setRangeText(DOMString replacement);
|
||||
//void setRangeText(DOMString replacement, unsigned long start, unsigned long end, optional SelectionMode selectionMode = "preserve");
|
||||
//void setRangeText(DOMString replacement, unsigned long start, unsigned long end,
|
||||
// optional SelectionMode selectionMode = "preserve");
|
||||
//void setSelectionRange(unsigned long start, unsigned long end, optional DOMString direction);
|
||||
|
||||
// also has obsolete members
|
||||
|
|
|
@ -4,7 +4,9 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://www.whatwg.org/html/#htmloptionelement
|
||||
//[NamedConstructor=Option(optional DOMString text = "", optional DOMString value, optional boolean defaultSelected = false, optional boolean selected = false)]
|
||||
//[NamedConstructor=Option(optional DOMString text = "", optional DOMString value,
|
||||
// optional boolean defaultSelected = false,
|
||||
// optional boolean selected = false)]
|
||||
interface HTMLOptionElement : HTMLElement {
|
||||
attribute boolean disabled;
|
||||
//readonly attribute HTMLFormElement? form;
|
||||
|
|
|
@ -42,6 +42,7 @@ interface HTMLTextAreaElement : HTMLElement {
|
|||
// attribute unsigned long selectionEnd;
|
||||
// attribute DOMString selectionDirection;
|
||||
//void setRangeText(DOMString replacement);
|
||||
//void setRangeText(DOMString replacement, unsigned long start, unsigned long end, optional SelectionMode selectionMode = "preserve");
|
||||
//void setRangeText(DOMString replacement, unsigned long start, unsigned long end,
|
||||
// optional SelectionMode selectionMode = "preserve");
|
||||
//void setSelectionRange(unsigned long start, unsigned long end, optional DOMString direction);
|
||||
};
|
||||
|
|
|
@ -14,10 +14,10 @@
|
|||
//Constructor(Uint8ClampedArray data, unsigned long sw, optional unsigned long sh),
|
||||
//Exposed=(Window,Worker)]
|
||||
interface ImageData {
|
||||
//[Constant]
|
||||
readonly attribute unsigned long width;
|
||||
//[Constant]
|
||||
readonly attribute unsigned long height;
|
||||
//[Constant, StoreInSlot]
|
||||
readonly attribute Uint8ClampedArray data;
|
||||
//[Constant]
|
||||
readonly attribute unsigned long width;
|
||||
//[Constant]
|
||||
readonly attribute unsigned long height;
|
||||
//[Constant, StoreInSlot]
|
||||
readonly attribute Uint8ClampedArray data;
|
||||
};
|
||||
|
|
|
@ -30,7 +30,9 @@ interface KeyboardEvent : UIEvent {
|
|||
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#idl-interface-KeyboardEvent-initializers
|
||||
partial interface KeyboardEvent {
|
||||
// Originally introduced (and deprecated) in DOM Level 3
|
||||
void initKeyboardEvent (DOMString typeArg, boolean bubblesArg, boolean cancelableArg, Window? viewArg, DOMString keyArg, unsigned long locationArg, DOMString modifiersListArg, boolean repeat, DOMString locale);
|
||||
void initKeyboardEvent (DOMString typeArg, boolean bubblesArg, boolean cancelableArg, Window? viewArg,
|
||||
DOMString keyArg, unsigned long locationArg, DOMString modifiersListArg,
|
||||
boolean repeat, DOMString locale);
|
||||
};
|
||||
|
||||
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#KeyboardEvent-supplemental-interface
|
||||
|
|
|
@ -38,5 +38,11 @@ dictionary MouseEventInit : SharedKeyboardAndMouseEventInit {
|
|||
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#idl-def-MouseEvent-1
|
||||
partial interface MouseEvent {
|
||||
// Deprecated in DOM Level 3
|
||||
void initMouseEvent (DOMString typeArg, boolean bubblesArg, boolean cancelableArg, Window? viewArg, long detailArg, long screenXArg, long screenYArg, long clientXArg, long clientYArg, boolean ctrlKeyArg, boolean altKeyArg, boolean shiftKeyArg, boolean metaKeyArg, short buttonArg, EventTarget? relatedTargetArg);
|
||||
void initMouseEvent (DOMString typeArg, boolean bubblesArg, boolean cancelableArg,
|
||||
Window? viewArg, long detailArg,
|
||||
long screenXArg, long screenYArg,
|
||||
long clientXArg, long clientYArg,
|
||||
boolean ctrlKeyArg, boolean altKeyArg,
|
||||
boolean shiftKeyArg, boolean metaKeyArg,
|
||||
short buttonArg, EventTarget? relatedTargetArg);
|
||||
};
|
||||
|
|
|
@ -71,7 +71,7 @@ interface Range {
|
|||
partial interface Range {
|
||||
// [NewObject, Throws]
|
||||
// DocumentFragment createContextualFragment(DOMString fragment);
|
||||
};//
|
||||
};//
|
||||
|
||||
// http://dev.w3.org/csswg/cssom-view/#extensions-to-the-range-interface
|
||||
partial interface Range {
|
||||
|
|
|
@ -38,7 +38,8 @@
|
|||
//readonly attribute WindowProxy parent;
|
||||
readonly attribute Window parent;
|
||||
readonly attribute Element? frameElement;
|
||||
//WindowProxy open(optional DOMString url = "about:blank", optional DOMString target = "_blank", optional DOMString features = "", optional boolean replace = false);
|
||||
//WindowProxy open(optional DOMString url = "about:blank", optional DOMString target = "_blank",
|
||||
// optional DOMString features = "", optional boolean replace = false);
|
||||
//getter WindowProxy (unsigned long index);
|
||||
//getter object (DOMString name);
|
||||
|
||||
|
|
|
@ -44,7 +44,9 @@ interface XMLHttpRequest : XMLHttpRequestEventTarget {
|
|||
[Throws]
|
||||
void open(ByteString method, /* [EnsureUTF16] */ DOMString url);
|
||||
[Throws]
|
||||
void open(ByteString method, /* [EnsureUTF16] */ DOMString url, boolean async, optional /* [EnsureUTF16] */ DOMString? username = null, optional /* [EnsureUTF16] */ DOMString? password = null);
|
||||
void open(ByteString method, /* [EnsureUTF16] */ DOMString url, boolean async,
|
||||
optional /* [EnsureUTF16] */ DOMString? username = null,
|
||||
optional /* [EnsureUTF16] */ DOMString? password = null);
|
||||
|
||||
[Throws]
|
||||
void setRequestHeader(ByteString name, ByteString value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue