2
* Copyright (c) 2004 World Wide Web Consortium,
4
* (Massachusetts Institute of Technology, European Research Consortium for
5
* Informatics and Mathematics, Keio University). All Rights Reserved. This
6
* work is distributed under the W3C(r) Software License [1] in the hope that
7
* it will be useful, but WITHOUT ANY WARRANTY; without even the implied
8
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10
* [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
13
// File: http://www.w3.org/TR/2004/NOTE-DOM-Level-3-Views-20040226/views.idl
20
#pragma prefix "dom.w3c.org"
24
typedef dom::Node Node;
25
typedef dom::DOMString DOMString;
28
interface VisualResource;
29
interface VisualCharacter;
30
interface VisualCharacterRun;
31
interface VisualFrame;
32
interface VisualImage;
33
interface VisualFormButton;
34
interface VisualFormField;
36
// Introduced in DOM Level 3:
38
void select(in Node boundary,
39
in unsigned long offset,
42
Segment createSegment();
43
boolean matchFirstSegment(inout Segment todo)
44
raises(dom::DOMException);
45
long getIntegerProperty(in DOMString name)
46
raises(dom::DOMException);
47
DOMString getStringProperty(in DOMString name)
48
raises(dom::DOMException);
49
boolean getBooleanProperty(in boolean name)
50
raises(dom::DOMException);
51
Node getContentPropertyNode(in DOMString name)
52
raises(dom::DOMException);
53
unsigned long getContentPropertyOffset(in DOMString name)
54
raises(dom::DOMException);
57
// Introduced in DOM Level 3:
61
const unsigned short IS_EQUAL = 0;
62
const unsigned short IS_NOT_EQUAL = 1;
63
const unsigned short INT_PRECEDES = 2;
64
const unsigned short INT_PRECEDES_OR_EQUALS = 3;
65
const unsigned short INT_FOLLOWS = 4;
66
const unsigned short INT_FOLLOWS_OR_EQUALS = 5;
67
const unsigned short STR_STARTS_WITH = 6;
68
const unsigned short STR_ENDS_WITH = 7;
69
const unsigned short STR_CONTAINS = 8;
70
const unsigned short SET_ANY = 9;
71
const unsigned short SET_ALL = 10;
72
const unsigned short SET_NOT_ANY = 11;
73
const unsigned short SET_NOT_ALL = 12;
75
readonly attribute unsigned short test;
78
// Introduced in DOM level 3:
79
interface MatchString : Match {
80
readonly attribute DOMString name;
81
readonly attribute DOMString value;
84
// Introduced in DOM level 3:
85
interface MatchInteger : Match {
86
readonly attribute DOMString name;
87
readonly attribute long value;
90
// Introduced in DOM level 3:
91
interface MatchBoolean : Match {
92
readonly attribute DOMString name;
93
readonly attribute boolean value;
96
// Introduced in DOM level 3:
97
interface MatchContent : Match {
98
readonly attribute DOMString name;
99
readonly attribute Node nodeArg;
100
readonly attribute unsigned long offset;
103
// Introduced in DOM level 3:
104
interface MatchSet : Match {
105
readonly attribute Node nodeArg;
106
void addMatch(in Match add);
107
Match getMatch(in unsigned long index);
110
// Introduced in DOM Level 3:
112
readonly attribute boolean exists;
113
readonly attribute DOMString name;
116
// Introduced in DOM Level 3:
117
interface StringItem : Item {
118
readonly attribute DOMString value;
121
// Introduced in DOM Level 3:
122
interface IntegerItem : Item {
123
readonly attribute long value;
126
// Introduced in DOM Level 3:
127
interface BooleanItem : Item {
128
attribute boolean value;
131
// Introduced in DOM Level 3:
132
interface ContentItem : Item {
133
attribute Node nodeArg;
134
attribute unsigned long offset;
137
interface VisualView {
138
readonly attribute DOMString fontScheme;
139
readonly attribute unsigned long width;
140
readonly attribute unsigned long height;
141
readonly attribute unsigned long horizontalDPI;
142
readonly attribute unsigned long verticalDPI;
143
VisualCharacter createVisualCharacter();
144
VisualCharacterRun createVisualCharacterRun();
145
VisualFrame createVisualFrame();
146
VisualImage createVisualImage();
147
VisualFormButton createVisualFormButton();
148
VisualFormField createVisualFormField();
149
void select(in Node boundary,
150
in unsigned long offset,
153
void matchSegment(in VisualResource segment);
156
interface VisualResource {
159
interface VisualFont : VisualResource {
160
attribute DOMString matchFontName;
161
readonly attribute boolean exists;
162
readonly attribute DOMString fontName;
166
interface VisualSegment : VisualResource {
167
attribute boolean matchPosition;
168
attribute boolean matchInside;
169
attribute boolean matchContaining;
170
attribute long matchX;
171
attribute long matchY;
172
attribute long matchXR;
173
attribute long matchYR;
174
attribute boolean matchContent;
175
attribute boolean matchRange;
176
attribute Node matchNode;
177
attribute unsigned long matchOffset;
178
attribute Node matchNodeR;
179
attribute unsigned long matchOffsetR;
180
attribute boolean matchContainsSelected;
181
attribute boolean matchContainsVisible;
182
readonly attribute boolean exists;
183
readonly attribute Node startNode;
184
readonly attribute unsigned long startOffset;
185
readonly attribute Node endNode;
186
readonly attribute unsigned long endOffset;
187
readonly attribute long topOffset;
188
readonly attribute long bottomOffset;
189
readonly attribute long leftOffset;
190
readonly attribute long rightOffset;
191
readonly attribute unsigned long width;
192
readonly attribute unsigned long height;
193
readonly attribute boolean selected;
194
readonly attribute boolean visible;
195
readonly attribute unsigned long foregroundColor;
196
readonly attribute unsigned long backgroundColor;
197
readonly attribute DOMString fontName;
198
readonly attribute DOMString fontHeight;
202
interface VisualCharacter : VisualSegment {
205
interface VisualCharacterRun : VisualSegment {
208
interface VisualFrame : VisualSegment {
209
readonly attribute VisualSegment embedded;
212
interface VisualImage : VisualSegment {
213
readonly attribute DOMString imageURL;
214
readonly attribute boolean isLoaded;
217
interface VisualFormButton : VisualSegment {
218
readonly attribute boolean isPressed;
221
interface VisualFormField : VisualSegment {
222
readonly attribute DOMString formValue;
225
// Introduced in DOM Level 3:
226
interface Segment : Match {
227
attribute Match criteria;
228
attribute DOMString order;
229
void addItem(in Item add);
230
MatchString createMatchString(in unsigned short test,
233
MatchInteger createMatchInteger(in unsigned short test,
236
MatchBoolean createMatchBoolean(in unsigned short test,
239
MatchContent createMatchContent(in unsigned short test,
241
in unsigned long offset,
243
MatchSet createMatchSet(in unsigned short test);
244
StringItem createStringItem(in DOMString name);
245
IntegerItem createIntegerItem(in DOMString name);
246
BooleanItem createBooleanItem(in DOMString name);
247
ContentItem createContentItem(in DOMString name);
248
void getItem(in unsigned long index);
253
#endif // _VIEWS_IDL_