ladybird/Userland/Libraries/LibWeb/DOM/Range.idl

52 lines
1.6 KiB
Plaintext
Raw Normal View History

#import <DOM/Node.idl>
#import <DOM/AbstractRange.idl>
#import <Geometry/DOMRect.idl>
// https://dom.spec.whatwg.org/#interface-range
[Exposed=Window]
interface Range : AbstractRange {
constructor();
readonly attribute Node commonAncestorContainer;
undefined setStart(Node node, unsigned long offset);
undefined setEnd(Node node, unsigned long offset);
undefined setStartBefore(Node node);
undefined setStartAfter(Node node);
undefined setEndBefore(Node node);
undefined setEndAfter(Node node);
2022-01-31 21:42:36 +03:00
undefined collapse(optional boolean toStart = false);
2022-01-31 21:33:41 +03:00
undefined selectNode(Node node);
undefined selectNodeContents(Node node);
const unsigned short START_TO_START = 0;
const unsigned short START_TO_END = 1;
const unsigned short END_TO_END = 2;
const unsigned short END_TO_START = 3;
short compareBoundaryPoints(unsigned short how, Range sourceRange);
[CEReactions] undefined deleteContents();
[CEReactions, NewObject] DocumentFragment extractContents();
[CEReactions, NewObject] DocumentFragment cloneContents();
[CEReactions] undefined insertNode(Node node);
[CEReactions] undefined surroundContents(Node newParent);
Range cloneRange();
2022-01-31 21:58:08 +03:00
undefined detach();
2022-02-01 21:45:34 +03:00
boolean isPointInRange(Node node, unsigned long offset);
2022-02-01 21:53:58 +03:00
short comparePoint(Node node, unsigned long offset);
2022-02-01 21:45:34 +03:00
2022-01-31 22:10:12 +03:00
boolean intersectsNode(Node node);
DOMRectList getClientRects();
DOMRect getBoundingClientRect();
stringifier;
// Extensions from the DOM Parsing specification:
[CEReactions, NewObject] DocumentFragment createContextualFragment(DOMString fragment);
};