Document.idl 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  1. interface Document : Node {
  2. constructor();
  3. boolean hasFocus();
  4. // FIXME: These attributes currently don't do anything.
  5. [PutForwards=href, LegacyUnforgeable] readonly attribute Location? location;
  6. readonly attribute DOMImplementation implementation;
  7. readonly attribute DOMString characterSet;
  8. readonly attribute DOMString charset;
  9. readonly attribute DOMString inputEncoding;
  10. readonly attribute DOMString contentType;
  11. readonly attribute Window? defaultView;
  12. undefined write(DOMString... text);
  13. undefined writeln(DOMString... text);
  14. attribute DOMString cookie;
  15. readonly attribute USVString referrer;
  16. readonly attribute Element? activeElement;
  17. Element? getElementById(DOMString id);
  18. HTMLCollection getElementsByName(DOMString name);
  19. HTMLCollection getElementsByTagName(DOMString tagName);
  20. HTMLCollection getElementsByTagNameNS(DOMString? namespace, DOMString localName);
  21. HTMLCollection getElementsByClassName(DOMString className);
  22. readonly attribute HTMLCollection applets;
  23. readonly attribute HTMLCollection anchors;
  24. readonly attribute HTMLCollection images;
  25. readonly attribute HTMLCollection embeds;
  26. readonly attribute HTMLCollection plugins;
  27. readonly attribute HTMLCollection links;
  28. readonly attribute HTMLCollection forms;
  29. readonly attribute HTMLCollection scripts;
  30. Element createElement(DOMString tagName);
  31. Element createElementNS(DOMString? namespace, DOMString qualifiedName);
  32. DocumentFragment createDocumentFragment();
  33. Text createTextNode(DOMString data);
  34. Comment createComment(DOMString data);
  35. Range createRange();
  36. Event createEvent(DOMString interface);
  37. [CEReactions, NewObject] Node importNode(Node node, optional boolean deep = false);
  38. [CEReactions, ImplementedAs=adopt_node_binding] Node adoptNode(Node node);
  39. [ImplementedAs=style_sheets_for_bindings] readonly attribute StyleSheetList styleSheets;
  40. readonly attribute DOMString compatMode;
  41. readonly attribute DocumentType? doctype;
  42. readonly attribute Element? documentElement;
  43. attribute HTMLElement? body;
  44. readonly attribute HTMLHeadElement? head;
  45. readonly attribute HTMLScriptElement? currentScript;
  46. readonly attribute DOMString readyState;
  47. attribute DOMString title;
  48. // FIXME: These should all come from a ParentNode mixin
  49. readonly attribute Element? firstElementChild;
  50. readonly attribute Element? lastElementChild;
  51. readonly attribute unsigned long childElementCount;
  52. [CEReactions, Unscopable] undefined prepend((Node or DOMString)... nodes);
  53. [CEReactions, Unscopable] undefined append((Node or DOMString)... nodes);
  54. [CEReactions, Unscopable] undefined replaceChildren((Node or DOMString)... nodes);
  55. Element? querySelector(DOMString selectors);
  56. [NewObject] NodeList querySelectorAll(DOMString selectors);
  57. [SameObject] readonly attribute HTMLCollection children;
  58. // FIXME: These should all come from a GlobalEventHandlers mixin
  59. attribute EventHandler onabort;
  60. attribute EventHandler onauxclick;
  61. attribute EventHandler onblur;
  62. attribute EventHandler oncancel;
  63. attribute EventHandler oncanplay;
  64. attribute EventHandler oncanplaythrough;
  65. attribute EventHandler onchange;
  66. attribute EventHandler onclick;
  67. attribute EventHandler onclose;
  68. attribute EventHandler oncontextmenu;
  69. attribute EventHandler oncuechange;
  70. attribute EventHandler ondblclick;
  71. attribute EventHandler ondrag;
  72. attribute EventHandler ondragend;
  73. attribute EventHandler ondragenter;
  74. attribute EventHandler ondragleave;
  75. attribute EventHandler ondragover;
  76. attribute EventHandler ondragstart;
  77. attribute EventHandler ondrop;
  78. attribute EventHandler ondurationchange;
  79. attribute EventHandler onemptied;
  80. attribute EventHandler onended;
  81. // FIXME: Should be an OnErrorEventHandler
  82. attribute EventHandler onerror;
  83. attribute EventHandler onfocus;
  84. attribute EventHandler onformdata;
  85. attribute EventHandler oninput;
  86. attribute EventHandler oninvalid;
  87. attribute EventHandler onkeydown;
  88. attribute EventHandler onkeypress;
  89. attribute EventHandler onkeyup;
  90. attribute EventHandler onload;
  91. attribute EventHandler onloadeddata;
  92. attribute EventHandler onloadedmetadata;
  93. attribute EventHandler onloadstart;
  94. attribute EventHandler onmousedown;
  95. [LegacyLenientThis] attribute EventHandler onmouseenter;
  96. [LegacyLenientThis] attribute EventHandler onmouseleave;
  97. attribute EventHandler onmousemove;
  98. attribute EventHandler onmouseout;
  99. attribute EventHandler onmouseover;
  100. attribute EventHandler onmouseup;
  101. attribute EventHandler onpause;
  102. attribute EventHandler onplay;
  103. attribute EventHandler onplaying;
  104. attribute EventHandler onprogress;
  105. attribute EventHandler onratechange;
  106. attribute EventHandler onreset;
  107. attribute EventHandler onresize;
  108. attribute EventHandler onscroll;
  109. attribute EventHandler onsecuritypolicyviolation;
  110. attribute EventHandler onseeked;
  111. attribute EventHandler onseeking;
  112. attribute EventHandler onselect;
  113. attribute EventHandler onslotchange;
  114. attribute EventHandler onstalled;
  115. attribute EventHandler onsubmit;
  116. attribute EventHandler onsuspend;
  117. attribute EventHandler ontimeupdate;
  118. attribute EventHandler ontoggle;
  119. attribute EventHandler onvolumechange;
  120. attribute EventHandler onwaiting;
  121. attribute EventHandler onwebkitanimationend;
  122. attribute EventHandler onwebkitanimationiteration;
  123. attribute EventHandler onwebkitanimationstart;
  124. attribute EventHandler onwebkittransitionend;
  125. attribute EventHandler onwheel;
  126. readonly boolean hidden;
  127. readonly DOMString visibilityState;
  128. };