mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +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
|
// http://dev.w3.org/2006/webapi/FileAPI/#dfn-Blob
|
||||||
//[Exposed=Window,Worker][Constructor,
|
//[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,
|
||||||
Constructor(DOMString blobParts, optional BlobPropertyBag options)]
|
Constructor(DOMString blobParts, optional BlobPropertyBag options)]
|
||||||
interface Blob {
|
interface Blob {
|
||||||
|
|
|
@ -94,14 +94,18 @@ interface CanvasRenderingContext2D {
|
||||||
void clip(optional CanvasWindingRule fillRule = "nonzero");
|
void clip(optional CanvasWindingRule fillRule = "nonzero");
|
||||||
//void clip(Path2D path, optional CanvasWindingRule fillRule = "nonzero");
|
//void clip(Path2D path, optional CanvasWindingRule fillRule = "nonzero");
|
||||||
//void resetClip();
|
//void resetClip();
|
||||||
//boolean isPointInPath(unrestricted double x, unrestricted double y, optional CanvasWindingRule fillRule = "nonzero");
|
//boolean isPointInPath(unrestricted double x, unrestricted double y,
|
||||||
//boolean isPointInPath(Path2D path, unrestricted double x, unrestricted double y, optional CanvasWindingRule fillRule = "nonzero");
|
// 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(unrestricted double x, unrestricted double y);
|
||||||
//boolean isPointInStroke(Path2D path, unrestricted double x, unrestricted double y);
|
//boolean isPointInStroke(Path2D path, unrestricted double x, unrestricted double y);
|
||||||
|
|
||||||
// text (see also the CanvasDrawingStyles interface)
|
// text (see also the CanvasDrawingStyles interface)
|
||||||
//void fillText(DOMString text, unrestricted double x, unrestricted double y, optional unrestricted double maxWidth);
|
//void fillText(DOMString text, unrestricted double x, unrestricted double y,
|
||||||
//void strokeText(DOMString text, unrestricted double x, unrestricted double y, optional unrestricted double maxWidth);
|
// optional unrestricted double maxWidth);
|
||||||
|
//void strokeText(DOMString text, unrestricted double x, unrestricted double y,
|
||||||
|
// optional unrestricted double maxWidth);
|
||||||
//TextMetrics measureText(DOMString text);
|
//TextMetrics measureText(DOMString text);
|
||||||
|
|
||||||
// drawing images
|
// drawing images
|
||||||
|
@ -128,7 +132,10 @@ interface CanvasRenderingContext2D {
|
||||||
[Throws]
|
[Throws]
|
||||||
ImageData getImageData(double sx, double sy, double sw, double sh);
|
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);
|
||||||
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]
|
[NoInterfaceObject]
|
||||||
|
@ -147,7 +154,8 @@ interface CanvasDrawingStyles {
|
||||||
// text
|
// text
|
||||||
//attribute DOMString font; // (default 10px sans-serif)
|
//attribute DOMString font; // (default 10px sans-serif)
|
||||||
//attribute DOMString textAlign; // "start", "end", "left", "right", "center" (default: "start")
|
//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")
|
//attribute DOMString direction; // "ltr", "rtl", "inherit" (default: "inherit")
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -157,7 +165,8 @@ interface CanvasPathMethods {
|
||||||
void closePath();
|
void closePath();
|
||||||
void moveTo(unrestricted double x, unrestricted double y);
|
void moveTo(unrestricted double x, unrestricted double y);
|
||||||
void lineTo(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,
|
void bezierCurveTo(unrestricted double cp1x,
|
||||||
unrestricted double cp1y,
|
unrestricted double cp1y,
|
||||||
|
@ -170,16 +179,19 @@ interface CanvasPathMethods {
|
||||||
void arcTo(unrestricted double x1, unrestricted double y1,
|
void arcTo(unrestricted double x1, unrestricted double y1,
|
||||||
unrestricted double x2, unrestricted double y2,
|
unrestricted double x2, unrestricted double y2,
|
||||||
unrestricted double radius);
|
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);
|
void rect(unrestricted double x, unrestricted double y, unrestricted double w, unrestricted double h);
|
||||||
|
|
||||||
[Throws]
|
[Throws]
|
||||||
void arc(double x, double y, double radius, double startAngle, double endAngle, optional boolean anticlockwise = false);
|
void arc(double x, double y, double radius, double startAngle, double endAngle,
|
||||||
// NOT IMPLEMENTED [LenientFloat] void ellipse(double x, double y, double radiusX, double radiusY, double rotation, double startAngle, double endAngle, boolean anticlockwise);
|
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 CanvasDrawingStyles;
|
||||||
CanvasRenderingContext2D implements CanvasPathMethods;
|
CanvasRenderingContext2D implements CanvasPathMethods;
|
||||||
|
|
||||||
|
|
|
@ -59,9 +59,11 @@ interface Document : Node {
|
||||||
|
|
||||||
// NodeFilter.SHOW_ALL = 0xFFFFFFFF
|
// NodeFilter.SHOW_ALL = 0xFFFFFFFF
|
||||||
[NewObject]
|
[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]
|
[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;
|
Document implements ParentNode;
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,9 @@ callback EventHandlerNonNull = any (Event event);
|
||||||
typedef EventHandlerNonNull? EventHandler;
|
typedef EventHandlerNonNull? EventHandler;
|
||||||
|
|
||||||
[TreatNonObjectAsNull]
|
[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;
|
typedef OnErrorEventHandlerNonNull? OnErrorEventHandler;
|
||||||
|
|
||||||
[NoInterfaceObject]
|
[NoInterfaceObject]
|
||||||
|
|
|
@ -64,7 +64,8 @@ interface HTMLInputElement : HTMLElement {
|
||||||
// attribute unsigned long selectionEnd;
|
// attribute unsigned long selectionEnd;
|
||||||
// attribute DOMString selectionDirection;
|
// attribute DOMString selectionDirection;
|
||||||
//void setRangeText(DOMString replacement);
|
//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);
|
//void setSelectionRange(unsigned long start, unsigned long end, optional DOMString direction);
|
||||||
|
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
|
|
|
@ -4,7 +4,9 @@
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// https://www.whatwg.org/html/#htmloptionelement
|
// 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 {
|
interface HTMLOptionElement : HTMLElement {
|
||||||
attribute boolean disabled;
|
attribute boolean disabled;
|
||||||
//readonly attribute HTMLFormElement? form;
|
//readonly attribute HTMLFormElement? form;
|
||||||
|
|
|
@ -42,6 +42,7 @@ interface HTMLTextAreaElement : HTMLElement {
|
||||||
// attribute unsigned long selectionEnd;
|
// attribute unsigned long selectionEnd;
|
||||||
// attribute DOMString selectionDirection;
|
// attribute DOMString selectionDirection;
|
||||||
//void setRangeText(DOMString replacement);
|
//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);
|
//void setSelectionRange(unsigned long start, unsigned long end, optional DOMString direction);
|
||||||
};
|
};
|
||||||
|
|
|
@ -30,7 +30,9 @@ interface KeyboardEvent : UIEvent {
|
||||||
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#idl-interface-KeyboardEvent-initializers
|
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#idl-interface-KeyboardEvent-initializers
|
||||||
partial interface KeyboardEvent {
|
partial interface KeyboardEvent {
|
||||||
// Originally introduced (and deprecated) in DOM Level 3
|
// 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
|
// 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
|
// https://dvcs.w3.org/hg/dom3events/raw-file/tip/html/DOM3-Events.html#idl-def-MouseEvent-1
|
||||||
partial interface MouseEvent {
|
partial interface MouseEvent {
|
||||||
// Deprecated in DOM Level 3
|
// 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);
|
||||||
};
|
};
|
||||||
|
|
|
@ -38,7 +38,8 @@
|
||||||
//readonly attribute WindowProxy parent;
|
//readonly attribute WindowProxy parent;
|
||||||
readonly attribute Window parent;
|
readonly attribute Window parent;
|
||||||
readonly attribute Element? frameElement;
|
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 WindowProxy (unsigned long index);
|
||||||
//getter object (DOMString name);
|
//getter object (DOMString name);
|
||||||
|
|
||||||
|
|
|
@ -44,7 +44,9 @@ interface XMLHttpRequest : XMLHttpRequestEventTarget {
|
||||||
[Throws]
|
[Throws]
|
||||||
void open(ByteString method, /* [EnsureUTF16] */ DOMString url);
|
void open(ByteString method, /* [EnsureUTF16] */ DOMString url);
|
||||||
[Throws]
|
[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]
|
[Throws]
|
||||||
void setRequestHeader(ByteString name, ByteString value);
|
void setRequestHeader(ByteString name, ByteString value);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue