2012-12-26 06:00:47 +04:00
|
|
|
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* 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/.
|
|
|
|
*/
|
|
|
|
|
2013-04-20 20:04:09 +04:00
|
|
|
[OverrideBuiltins]
|
2012-12-26 06:00:47 +04:00
|
|
|
interface HTMLDocument : Document {
|
|
|
|
[Throws]
|
|
|
|
attribute DOMString? domain;
|
|
|
|
[Throws]
|
|
|
|
attribute DOMString cookie;
|
|
|
|
// DOM tree accessors
|
2012-12-20 13:56:11 +04:00
|
|
|
[Throws]
|
|
|
|
getter object (DOMString name);
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure, SetterThrows]
|
2012-12-26 06:00:47 +04:00
|
|
|
attribute HTMLElement? body;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLHeadElement? head;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection images;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection embeds;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection plugins;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection links;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection forms;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection scripts;
|
|
|
|
NodeList getElementsByName(DOMString elementName);
|
|
|
|
NodeList getItems(optional DOMString typeNames = ""); // microdata
|
|
|
|
|
|
|
|
// dynamic markup insertion
|
|
|
|
[Throws]
|
|
|
|
Document open(optional DOMString type = "text/html", optional DOMString replace = "");
|
|
|
|
[Throws]
|
|
|
|
WindowProxy open(DOMString url, DOMString name, DOMString features, optional boolean replace = false);
|
|
|
|
[Throws]
|
|
|
|
void close();
|
|
|
|
[Throws]
|
|
|
|
void write(DOMString... text);
|
|
|
|
[Throws]
|
|
|
|
void writeln(DOMString... text);
|
|
|
|
|
|
|
|
[SetterThrows]
|
|
|
|
attribute DOMString designMode;
|
|
|
|
[Throws]
|
|
|
|
boolean execCommand(DOMString commandId, optional boolean showUI = false,
|
|
|
|
optional DOMString value = "");
|
|
|
|
[Throws]
|
|
|
|
boolean queryCommandEnabled(DOMString commandId);
|
|
|
|
[Throws]
|
|
|
|
boolean queryCommandIndeterm(DOMString commandId);
|
|
|
|
[Throws]
|
|
|
|
boolean queryCommandState(DOMString commandId);
|
|
|
|
boolean queryCommandSupported(DOMString commandId);
|
|
|
|
[Throws]
|
|
|
|
DOMString queryCommandValue(DOMString commandId);
|
|
|
|
|
|
|
|
[TreatNullAs=EmptyString] attribute DOMString fgColor;
|
|
|
|
[TreatNullAs=EmptyString] attribute DOMString linkColor;
|
|
|
|
[TreatNullAs=EmptyString] attribute DOMString vlinkColor;
|
|
|
|
[TreatNullAs=EmptyString] attribute DOMString alinkColor;
|
|
|
|
[TreatNullAs=EmptyString] attribute DOMString bgColor;
|
|
|
|
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection anchors;
|
2013-10-09 22:58:15 +04:00
|
|
|
[Pure]
|
2012-12-26 06:00:47 +04:00
|
|
|
readonly attribute HTMLCollection applets;
|
|
|
|
|
|
|
|
void clear();
|
|
|
|
|
2014-05-20 23:52:21 +04:00
|
|
|
readonly attribute HTMLAllCollection all;
|
2013-06-12 10:55:00 +04:00
|
|
|
|
2012-12-26 06:00:47 +04:00
|
|
|
// https://dvcs.w3.org/hg/editing/raw-file/tip/editing.html#selections
|
|
|
|
[Throws]
|
2013-12-17 18:12:33 +04:00
|
|
|
Selection? getSelection();
|
2013-08-01 01:44:51 +04:00
|
|
|
|
|
|
|
// @deprecated These are old Netscape 4 methods. Do not use,
|
|
|
|
// the implementation is no-op.
|
|
|
|
// XXXbz do we actually need these anymore?
|
2014-02-09 12:04:39 +04:00
|
|
|
void captureEvents();
|
|
|
|
void releaseEvents();
|
2012-12-26 06:00:47 +04:00
|
|
|
};
|