2
This file is part of the Free Component Library
4
Implementation of DOM HTML interfaces
6
Areca Systems GmbH / Sebastian Guenther, sg@freepascal.org
8
See the file COPYING.FPC, included in this distribution,
9
for details about the copyright.
11
This program is distributed in the hope that it will be useful,
12
but WITHOUT ANY WARRANTY; without even the implied warranty of
13
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15
**********************************************************************}
17
{ Please note that this is a very early version, most properties and methods
18
are not implemented yet. }
29
THTMLDocument = class;
30
THTMLFormElement = class;
31
THTMLTableCaptionElement = class;
32
THTMLTableSectionElement = class;
34
THTMLCollection = class
36
property Length: Cardinal; // !!!: ro
37
function Item(Index: Cardinal): TDOMNode;
38
function NamedItem(const Index: DOMString): TDOMNode;
41
THTMLOptionsCollection = class
43
property Length: Cardinal; // !!!: ro
44
function Item(Index: Cardinal): TDOMNode;
45
function NamedItem(const Index: DOMString): TDOMNode;
48
THTMLElement = class(TDOMElement)
50
function GetID: DOMString;
51
procedure SetID(const Value: DOMString);
52
function GetTitle: DOMString;
53
procedure SetTitle(const Value: DOMString);
54
function GetLang: DOMString;
55
procedure SetLang(const Value: DOMString);
56
function GetDir: DOMString;
57
procedure SetDir(const Value: DOMString);
58
function GetClassName: DOMString;
59
procedure SetClassName(const Value: DOMString);
61
constructor Create(AOwner: THTMLDocument; const ATagName: DOMString);
63
property ID: DOMString read GetID write SetID;
64
property Title: DOMString read GetTitle write SetTitle;
65
property Lang: DOMString read GetLang write SetLang;
66
property Dir: DOMString read GetDir write SetDir;
67
property ClassName: DOMString read GetClassName write SetClassName;
70
THTMLHtmlElement = class(THTMLElement)
72
function GetVersion: DOMString;
73
procedure SetVersion(const Value: DOMString);
75
property Version: DOMString read GetVersion write SetVersion;
78
THTMLHeadElement = class(THTMLElement)
80
function GetProfile: DOMString;
81
procedure SetProfile(const Value: DOMString);
83
property Profile: DOMString read GetProfile write SetProfile;
86
THTMLLinkElement = class(THTMLElement)
88
property Disabled: Boolean; // !!!: rw
89
property Charset: DOMString; // !!!: rw
90
property HRef: DOMString; // !!!: rw
91
property HRefLang: DOMString; // !!!: rw
92
property Media: DOMString; // !!!: rw
93
property Rel: DOMString; // !!!: rw
94
property Rev: DOMString; // !!!: rw
95
property Target: DOMString; // !!!: rw
96
property HTMLType: DOMString; // !!!: rw
99
THTMLTitleElement = class(THTMLElement)
101
property Text: DOMString; // !!!: rw
104
THTMLMetaElement = class(THTMLElement)
106
property Content: DOMString; // !!!: rw
107
property HTTPEqiv: DOMString; // !!!: rw
108
property Name: DOMString; // !!!: rw
109
property Scheme: DOMString; // !!!: rw
112
THTMLBaseElement = class(THTMLElement)
114
property HRef: DOMString; // !!!: rw
115
property Target: DOMString; // !!!: rw
118
THTMLIsIndexElement = class(THTMLElement)
120
property Form: THTMLFormElement; // !!!: ro
121
property Prompt: DOMString; // !!!: rw
124
THTMLStyleElement = class(THTMLElement)
126
property Disabled: Boolean; // !!!: rw
127
property Media: DOMString; // !!!: rw
128
property HTMLType: DOMString; // !!!: rw
131
THTMLBodyElement = class(THTMLElement)
133
property ALink: DOMString; // !!!: rw
134
property Background: DOMString; // !!!: rw
135
property BgColor: DOMString; // !!!: rw
136
property Link: DOMString; // !!!: rw
137
property Text: DOMString; // !!!: rw
138
property VLink: DOMString; // !!!: rw
141
THTMLFormElement = class(THTMLElement)
143
property Elements: THTMLCollection; // !!!: ro
144
property Length: Integer; // !!!: ro
145
property Name: DOMString; // !!!: rw
146
property AcceptCharset: DOMString; // !!!: rw
147
property Action: DOMString; // !!!: rw
148
property EncType: DOMString; // !!!: rw
149
property Method: DOMString; // !!!: rw
150
property Target: DOMString; // !!!: rw
151
procedure Submit; virtual; abstract;
152
procedure Reset; virtual; abstract;
155
THTMLSelectElement = class(THTMLElement)
157
property HTMLType: DOMString; // !!!: ro
158
property SelectedIndex: Integer; // !!!: rw
159
property Value: DOMString; // !!!: rw
160
property Length: Cardinal; // !!!: rw
161
property Form: THTMLFormElement; // !!!: ro
162
property Options: THTMLOptionsCollection; // !!!: ro
163
property Disabled: Boolean; // !!!: rw
164
property Multiple: Boolean; // !!!: rw
165
property Name: DOMString; // !!!: rw
166
property Size: Integer; // !!!: rw
167
property TabIndex: Integer; // !!!: rw
168
procedure Add(Element, Before: THTMLElement);
169
procedure Remove(Index: Integer);
170
procedure Blur; virtual; abstract;
171
procedure Focus; virtual; abstract;
174
THTMLOptGroupElement = class(THTMLElement)
176
property Disabled: Boolean; // !!!: rw
177
property GroupLabel: DOMString; // !!!: rw
180
THTMLOptionElement = class(THTMLElement)
182
property Form: THTMLFormElement; // !!!: ro
183
property DefaultSelected: Boolean; // !!!: rw
184
property Text: DOMString; // !!!: ro
185
property Index: Integer; // !!!: ro
186
property Disabled: Boolean; // !!!: rw
187
property OptionLabel: DOMString; // !!!: rw
188
property Selected: Boolean; // !!!: rw
189
property Value: DOMString; // !!!: rw
192
THTMLInputElement = class(THTMLElement)
194
property DefaultValue: DOMString; // !!!: rw
195
property DefaultChecked: Boolean; // !!!: rw
196
property Form: THTMLFormElement; // !!!: ro
197
property Accept: DOMString; // !!!: rw
198
property AccessKey: DOMString; // !!!: rw
199
property Align: DOMString; // !!!: rw
200
property Alt: DOMString; // !!!: rw
201
property Checked: Boolean; // !!!: rw
202
property Disabled: Boolean; // !!!: rw
203
property MaxLength: Integer; // !!!: rw
204
property Name: DOMString; // !!!: rw
205
property ReadOnly: Boolean; // !!!: rw
206
property Size: Cardinal; // !!!: rw
207
property Src: DOMString; // !!!: rw
208
property TabIndex: Integer; // !!!: rw
209
property HTMLType: DOMString; // !!!: rw
210
property UseMap: DOMString; // !!!: rw
211
property Value: DOMString; // !!!: rw
212
procedure Blur; virtual; abstract;
213
procedure Focus; virtual; abstract;
214
procedure Select; virtual; abstract;
215
procedure Click; virtual; abstract;
218
THTMLTextAreaElement = class(THTMLElement)
220
property DefaultValue: DOMString; // !!!: rw
221
property Form: THTMLFormElement; // !!!: ro
222
property AccessKey: DOMString; // !!!: rw
223
property Cols: Integer; // !!!: rw
224
property Disabled: Boolean; // !!!: rw
225
property Name: DOMString; // !!!: rw
226
property ReadOnly: Boolean; // !!!: rw
227
property Rows: Integer; // !!!: rw
228
property TabIndex: Integer; // !!!: rw
229
property HTMLType: DOMString; // !!!: rw
230
property Value: DOMString; // !!!: rw
231
procedure Blur; virtual; abstract;
232
procedure Focus; virtual; abstract;
233
procedure Select; virtual; abstract;
236
THTMLButtonElement = class(THTMLElement)
238
property Form: THTMLFormElement; // !!!: ro
239
property AccessKey: DOMString; // !!!: rw
240
property Disabled: Boolean; // !!!: rw
241
property Name: DOMString; // !!!: rw
242
property TabIndex: Integer; // !!!: rw
243
property HTMLType: DOMString; // !!!: rw
244
property Value: DOMString; // !!!: rw
247
THTMLLabelElement = class(THTMLElement)
249
property Form: THTMLFormElement; // !!!: ro
250
property AccessKey: DOMString; // !!!: rw
251
property HtmlFor: DOMString; // !!!: rw
254
THTMLFieldSetElement = class(THTMLElement)
256
property Form: THTMLFormElement; // !!!: ro
259
THTMLLegendElement = class(THTMLElement)
261
property Form: THTMLFormElement; // !!!: ro
262
property AccessKey: DOMString; // !!!: rw
263
property Align: DOMString; // !!!: rw
266
THTMLUListElement = class(THTMLElement)
268
property Compact: Boolean; // !!!: rw
269
property HTMLType: DOMString; // !!!: rw
272
THTMLOListElement = class(THTMLElement)
274
property Compact: Boolean; // !!!: rw
275
property Start: Integer; // !!!: rw
276
property HTMLType: DOMString; // !!!: rw
279
THTMLDListElement = class(THTMLElement)
281
property Compact: Boolean; // !!!: rw
284
THTMLDirectoryElement = class(THTMLElement)
286
property Compact: Boolean; // !!!: rw
289
THTMLMenuElement = class(THTMLElement)
291
property Compact: Boolean; // !!!: rw
294
THTMLLIElement = class(THTMLElement)
296
property HTMLType: DOMString; // !!!: rw
297
property Value: Integer; // !!!: rw
300
THTMLDivElement = class(THTMLElement)
302
property Align: DOMString; // !!!: rw
305
THTMLParagraphElement = class(THTMLElement)
307
property Align: DOMString; // !!!: rw
310
THTMLHeadingElement = class(THTMLElement)
312
property Align: DOMString; // !!!: rw
315
THTMLQuoteElement = class(THTMLElement)
317
property Cite: DOMString; // !!!: rw
320
THTMLPreElement = class(THTMLElement)
322
property Width: Integer; // !!!: rw
325
THTMLBREElement = class(THTMLElement)
327
property Clear: DOMString; // !!!: rw
330
THTMLBaseFontElement = class(THTMLElement)
332
property Color: DOMString; // !!!: rw
333
property Face: DOMString; // !!!: rw
334
property Size: Integer; // !!!: rw
337
THTMLFontElement = class(THTMLElement)
339
property Color: DOMString; // !!!: rw
340
property Face: DOMString; // !!!: rw
341
property Size: Integer; // !!!: rw
344
THTMLHRElement = class(THTMLElement)
346
property Align: DOMString; // !!!: rw
347
property NoShade: Boolean; // !!!: rw
348
property Size: DOMString; // !!!: rw
349
property Width: DOMString; // !!!: rw
352
THTMLModElement = class(THTMLElement)
354
property Cite: DOMString; // !!!: rw
355
property DateTime: DOMString; // !!!: rw
358
THTMLAnchorElement = class(THTMLElement)
360
property AccessKey: DOMString; // !!!: rw
361
property Charset: DOMString; // !!!: rw
362
property Coords: DOMString; // !!!: rw
363
property HRef: DOMString; // !!!: rw
364
property HRefLang: DOMString; // !!!: rw
365
property Name: DOMString; // !!!: rw
366
property Rel: DOMString; // !!!: rw
367
property Rev: DOMString; // !!!: rw
368
property Shape: DOMString; // !!!: rw
369
property TabIndex: Integer; // !!!: rw
370
property Target: DOMString; // !!!: rw
371
property HTMLType: DOMString; // !!!: rw
372
procedure Blur; virtual; abstract;
373
procedure Focus; virtual; abstract;
376
THTMLImageElement = class(THTMLElement)
378
property Name: DOMString; // !!!: rw
379
property Align: DOMString; // !!!: rw
380
property Alt: DOMString; // !!!: rw
381
property Border: DOMString; // !!!: rw
382
property Height: Integer; // !!!: rw
383
property HSpace: Integer; // !!!: rw
384
property IsMap: Boolean; // !!!: rw
385
property LongDesc: DOMString; // !!!: rw
386
property Src: Integer; // !!!: rw
387
property UseMap: DOMString; // !!!: rw
388
property VSpace: Integer; // !!!: rw
389
property Width: Integer; // !!!: rw
392
THTMLObjectElement = class(THTMLElement)
394
property Form: THTMLFormElement; // !!!: ro
395
property Code: DOMString; // !!!: rw
396
property Align: DOMString; // !!!: rw
397
property Archive: DOMString; // !!!: rw
398
property Border: DOMString; // !!!: rw
399
property CodeBase: DOMString; // !!!: rw
400
property CodeType: DOMString; // !!!: rw
401
property Data: DOMString; // !!!: rw
402
property Declare: Boolean; // !!!: rw
403
property Height: DOMString; // !!!: rw
404
property HSpace: Integer; // !!!: rw
405
property Name: DOMString; // !!!: rw
406
property StandBy: DOMString; // !!!: rw
407
property TabIndex: Integer; // !!!: rw
408
property HTMLType: DOMString; // !!!: rw
409
property UseMap: DOMString; // !!!: rw
410
property VSpace: Integer; // !!!: rw
411
property Width: Integer; // !!!: rw
412
property ContentDocument: TDOMDocument; // !!!: ro
415
THTMLParamElement = class(THTMLElement)
417
property Name: DOMString; // !!!: rw
418
property HTMLType: DOMString; // !!!: rw
419
property Value: DOMString; // !!!: rw
420
property ValueType: DOMString; // !!!: rw
423
THTMLAppletElement = class(THTMLElement)
425
property Align: DOMString; // !!!: rw
426
property Alt: DOMString; // !!!: rw
427
property Archive: DOMString; // !!!: rw
428
property Code: DOMString; // !!!: rw
429
property CodeBase: DOMString; // !!!: rw
430
property Height: DOMString; // !!!: rw
431
property HSpace: Integer; // !!!: rw
432
property Name: DOMString; // !!!: rw
433
property AppletObject: DOMString; // !!!: rw
434
property VSpace: Integer; // !!!: rw
435
property Width: Integer; // !!!: rw
438
THTMLMapElement = class(THTMLElement)
440
property Areas: THTMLCollection; // !!!: ro
441
property Name: DOMString; // !!!: rw
444
THTMLAreaElement = class(THTMLElement)
446
property AccessKey: DOMString; // !!!: rw
447
property Alt: DOMString; // !!!: rw
448
property Coords: DOMString; // !!!: rw
449
property HRef: DOMString; // !!!: rw
450
property NoHRef: Boolean; // !!!: rw
451
property Shape: DOMString; // !!!: rw
452
property TabIndex: Integer; // !!!: rw
453
property Target: DOMString; // !!!: rw
456
THTMLScriptElement = class(THTMLElement)
458
property Text: DOMString; // !!!: rw
459
property HtmlFor: DOMString; // !!!: rw
460
property Event: DOMString; // !!!: rw
461
property Charset: DOMString; // !!!: rw
462
property Defer: Boolean; // !!!: rw
463
property Src: DOMString; // !!!: rw
464
property HTMLType: DOMString; // !!!: rw
467
THTMLTableElement = class(THTMLElement)
469
property Caption: THTMLTableCaptionElement; // !!!: rw
470
property THead: THTMLTableSectionElement; // !!!: rw
471
property TFoot: THTMLTableSectionElement; // !!!: rw
472
property Rows: THTMLCollection; // !!!: ro
473
property TBodies: THTMLCollection; // !!!: ro
474
property Align: DOMString; // !!!: rw
475
property BgColor: DOMString; // !!!: rw
476
property Border: DOMString; // !!!: rw
477
property CellPadding: DOMString; // !!!: rw
478
property CellSpacing: DOMString; // !!!: rw
479
property Frame: DOMString; // !!!: rw
480
property Rules: DOMString; // !!!: rw
481
property Summary: DOMString; // !!!: rw
482
property Width: DOMString; // !!!: rw
483
function CreateTHead: THTMLElement;
484
procedure DeleteTHead;
485
function CreateTFoot: THTMLElement;
486
procedure DeleteTFoot;
487
function CreateCaption: THTMLElement;
488
procedure DeleteCaption;
489
function InsertRow(Index: Integer): THTMLElement;
490
procedure DeleteRow(Index: Integer);
493
THTMLTableCaptionElement = class(THTMLElement)
495
property Align: DOMString; // !!!: rw
498
THTMLTableColElement = class(THTMLElement)
500
property Align: DOMString; // !!!: rw
501
property Ch: DOMString; // !!!: rw
502
property ChOff: DOMString; // !!!: rw
503
property Span: Integer; // !!!: rw
504
property VAlign: DOMString; // !!!: rw
505
property Width: DOMString; // !!!: rw
508
THTMLTableSectionElement = class(THTMLElement)
510
property Align: DOMString; // !!!: rw
511
property Ch: DOMString; // !!!: rw
512
property ChOff: DOMString; // !!!: rw
513
property VAlign: DOMString; // !!!: rw
514
property Rows: THTMLCollection; // !!!: ro
515
function InsertRow(Index: Integer): THTMLElement;
516
procedure DeleteRow(Index: Integer);
519
THTMLTableRowElement = class(THTMLElement)
521
property RowIndex: Integer; // !!!: ro
522
property SectionRowIndex: Integer; // !!!: ro
523
property Cells: THTMLCollection; // !!!: ro
524
property Align: DOMString; // !!!: rw
525
property BgColor: DOMString; // !!!: rw
526
property Ch: DOMString; // !!!: rw
527
property ChOff: DOMString; // !!!: rw
528
property VAlign: DOMString; // !!!: rw
529
function InsertCell(Index: Integer): THTMLElement;
530
procedure DeleteCell(Index: Integer);
533
THTMLTableCellElement = class(THTMLElement)
535
property CellIndex: Integer; // !!!: ro
536
property Abbr: DOMString; // !!!: rw
537
property Align: DOMString; // !!!: rw
538
property Axis: DOMString; // !!!: rw
539
property BgColor: DOMString; // !!!: rw
540
property Ch: DOMString; // !!!: rw
541
property ChOff: DOMString; // !!!: rw
542
property ColSpan: Integer; // !!!: rw
543
property Headers: DOMString; // !!!: rw
544
property Height: DOMString; // !!!: rw
545
property NoWrap: Boolean; // !!!: rw
546
property RowSpan: Integer; // !!!: rw
547
property Scope: DOMString; // !!!: rw
548
property VAlign: DOMString; // !!!: rw
549
property Width: DOMString; // !!!: rw
552
THTMLFrameSetElement = class(THTMLElement)
554
property Cols: DOMString; // !!!: rw
555
property Rows: DOMString; // !!!: rw
558
THTMLFrameElement = class(THTMLElement)
560
property FrameBorder: DOMString; // !!!: rw
561
property LongDesc: DOMString; // !!!: rw
562
property MarginHeight: DOMString; // !!!: rw
563
property MarginWidth: DOMString; // !!!: rw
564
property Name: DOMString; // !!!: rw
565
property NoResize: Boolean; // !!!: rw
566
property Scrolling: DOMString; // !!!: rw
567
property Src: DOMString; // !!!: rw
568
property ContentDocument: TDOMDocument; // !!!: ro
571
THTMLIFrameElement = class(THTMLElement)
573
property Align: DOMString; // !!!: rw
574
property FrameBorder: DOMString; // !!!: rw
575
property Height: DOMString; // !!!: rw
576
property LongDesc: DOMString; // !!!: rw
577
property MarginHeight: DOMString; // !!!: rw
578
property MarginWidth: DOMString; // !!!: rw
579
property Name: DOMString; // !!!: rw
580
property Scrolling: DOMString; // !!!: rw
581
property Src: DOMString; // !!!: rw
582
property Width: DOMString; // !!!: rw
583
property ContentDocument: TDOMDocument; // !!!: ro
586
THTMLDocument = class(TXMLDocument)
588
function GetTitle: DOMString;
589
procedure SetTitle(const Value: DOMString);
591
property Title: DOMString read GetTitle write SetTitle;
592
property Referrer: DOMString; // !!!: ro
593
property Domain: DOMString; // !!!: ro
594
property URL: DOMString; // !!!: ro
595
property Body: THTMLElement; // !!!: rw
596
property Images: THTMLCollection; // !!!: ro
597
property Applets: THTMLCollection; // !!!: ro
598
property Links: THTMLCollection; // !!!: ro
599
property Forms: THTMLCollection; // !!!: ro
600
property Anchors: THTMLCollection; // !!!: ro
601
property Cookie: DOMString; // !!!: rw
603
procedure Open; virtual; abstract;
604
procedure Close; virtual; abstract;
605
procedure Write(const AText: DOMString);
606
procedure WriteLn(const AText: DOMString);
607
function GetElementsByName(const ElementName: DOMString): TDOMNodeList;
609
// Helper functions (not in DOM standard):
610
function CreateElement(const tagName: DOMString): THTMLElement;
611
function CreateSubElement: THTMLElement;
612
function CreateSupElement: THTMLElement;
613
function CreateSpanElement: THTMLElement;
614
function CreateBDOElement: THTMLElement;
615
function CreateTTElement: THTMLElement;
616
function CreateIElement: THTMLElement;
617
function CreateBElement: THTMLElement;
618
function CreateUElement: THTMLElement;
619
function CreateSElement: THTMLElement;
620
function CreateStrikeElement: THTMLElement;
621
function CreateBigElement: THTMLElement;
622
function CreateSmallElement: THTMLElement;
623
function CreateEmElement: THTMLElement;
624
function CreateStrongElement: THTMLElement;
625
function CreateDfnElement: THTMLElement;
626
function CreateCodeElement: THTMLElement;
627
function CreateSampElement: THTMLElement;
628
function CreateKbdElement: THTMLElement;
629
function CreateVarElement: THTMLElement;
630
function CreateCiteElement: THTMLElement;
631
function CreateAcronymElement: THTMLElement;
632
function CreateAbbrElement: THTMLElement;
633
function CreateDDElement: THTMLElement;
634
function CreateDTElement: THTMLElement;
635
function CreateNoFramesElement: THTMLElement;
636
function CreateNoScriptElement: THTMLElement;
637
function CreateAddressElement: THTMLElement;
638
function CreateCenterElement: THTMLElement;
639
function CreateHtmlElement: THTMLHtmlElement;
640
function CreateHeadElement: THTMLHeadElement;
641
function CreateLinkElement: THTMLLinkElement;
642
{ function CreateTitleElement: THTMLTitleElement;
643
function CreateMetaElement: THTMLMetaElement;
644
function CreateBaseElement: THTMLBaseElement;
645
function CreateIsIndexElement: THTMLIsIndexElement;
646
function CreateStyleElement: THTMLStyleElement;}
647
function CreateBodyElement: THTMLBodyElement;
648
{ function CreateFormElement: THTMLFormElement;
649
function CreateSelectElement: THTMLSelectElement;
650
function CreateOptGroupElement: THTMLOptGroupElement;
651
function CreateOptionElement: THTMLOptionElement;
652
function CreateInputElement: THTMLInputElement;
653
function CreateTextAreaElement: THTMLTextAreaElement;
654
function CreateButtonElement: THTMLButtonElement;
655
function CreateLabelElement: THTMLLabelElement;
656
function CreateFieldSetElement: THTMLFieldSetElement;
657
function CreateLegendElement: THTMLLegendElement;}
658
function CreateUListElement: THTMLUListElement;
659
function CreateOListElement: THTMLOListElement;
660
function CreateDListElement: THTMLDListElement;
661
{ function CreateDirectoryElement: THTMLDirectoryElement;
662
function CreateMenuElement: THTMLMenuElement;}
663
function CreateLIElement: THTMLLIElement;
664
{ function CreateDivElement: THTMLDivElement;}
665
function CreateParagraphElement: THTMLParagraphElement;
666
{ function CreateHeadingElement: THTMLHeadingElement;
667
function CreateQuoteElement: THTMLQuoteElement;
668
function CreatePreElement: THTMLPreElement;
669
function CreateBRElement: THTMLBreElement;
670
function CreateBaseFontElement: THTMLBaseFontElement;
671
function CreateFontElement: THTMFontLElement;
672
function CreateHRElement: THTMLHREElement;
673
function CreateModElement: THTMLModElement;
674
function CreateAnchorElement: THTMLAnchorElement;
675
function CreateImageElement: THTMLImageElement;
676
function CreateObjectElement: THTMLObjectElement;
677
function CreateParamElement: THTMLParamElement;
678
function CreateAppletElement: THTMLAppletElement;
679
function CreateMapElement: THTMLMapElement;
680
function CreateAreaElement: THTMLAreaElement;
681
function CreateScriptElement: THTMLScriptElement;
682
function CreateTableElement: THTMLTableElement;
683
function CreateTableCaptionElement: THTMLTableCaptionElement;
684
function CreateTableColElement: THTMLTableColElement;
685
function CreateTableSectionElement: THTMLTableSectionElement;
686
function CreateTableRowElement: THTMLTableRowElement;
687
function CreateTableCellElement: THTMLTableCellElement;
688
function CreateFrameSetElement: THTMLFrameSetElement;
689
function CreateFrameElement: THTMLFrameElement;
690
function CreateIFrameElement: THTMLIFrameElement;}
697
function THTMLCollection.Item(Index: Cardinal): TDOMNode;
702
function THTMLCollection.NamedItem(const Index: DOMString): TDOMNode;
708
function THTMLOptionsCollection.Item(Index: Cardinal): TDOMNode;
713
function THTMLOptionsCollection.NamedItem(const Index: DOMString): TDOMNode;
719
constructor THTMLElement.Create(AOwner: THTMLDocument; const ATagName: DOMString);
721
inherited Create(AOwner);
722
FNodeName := ATagName;
725
function THTMLElement.GetID: DOMString; begin Result := GetAttribute('id') end;
726
procedure THTMLElement.SetID(const Value: DOMString); begin SetAttribute('id', Value) end;
727
function THTMLElement.GetTitle: DOMString; begin Result := GetAttribute('title') end;
728
procedure THTMLElement.SetTitle(const Value: DOMString); begin SetAttribute('title', Value) end;
729
function THTMLElement.GetLang: DOMString; begin Result := GetAttribute('lang') end;
730
procedure THTMLElement.SetLang(const Value: DOMString); begin SetAttribute('lang', Value) end;
731
function THTMLElement.GetDir: DOMString; begin Result := GetAttribute('dir') end;
732
procedure THTMLElement.SetDir(const Value: DOMString); begin SetAttribute('dir', Value) end;
733
function THTMLElement.GetClassName: DOMString; begin Result := GetAttribute('class') end;
734
procedure THTMLElement.SetClassName(const Value: DOMString); begin SetAttribute('class', Value) end;
737
function THTMLHtmlElement.GetVersion: DOMString; begin Result := GetAttribute('version') end;
738
procedure THTMLHtmlElement.SetVersion(const Value: DOMString); begin SetAttribute('version', Value) end;
741
function THTMLHeadElement.GetProfile: DOMString; begin Result := GetAttribute('profile') end;
742
procedure THTMLHeadElement.SetProfile(const Value: DOMString); begin SetAttribute('profile', Value) end;
745
procedure THTMLSelectElement.Add(Element, Before: THTMLElement);
749
procedure THTMLSelectElement.Remove(Index: Integer);
754
function THTMLTableElement.CreateTHead: THTMLElement;
759
procedure THTMLTableElement.DeleteTHead;
763
function THTMLTableElement.CreateTFoot: THTMLElement;
768
procedure THTMLTableElement.DeleteTFoot;
772
function THTMLTableElement.CreateCaption: THTMLElement;
777
procedure THTMLTableElement.DeleteCaption;
781
function THTMLTableElement.InsertRow(Index: Integer): THTMLElement;
786
procedure THTMLTableElement.DeleteRow(Index: Integer);
791
function THTMLTableSectionElement.InsertRow(Index: Integer): THTMLElement;
796
procedure THTMLTableSectionElement.DeleteRow(Index: Integer);
801
function THTMLTableRowElement.InsertCell(Index: Integer): THTMLElement;
806
procedure THTMLTableRowElement.DeleteCell(Index: Integer);
811
function THTMLDocument.GetTitle: DOMString;
816
if not Assigned(DocumentElement) then
818
Node := DocumentElement.FirstChild;
819
while Assigned(Node) and (Node.NodeName <> 'head') do
820
Node := Node.NextSibling;
821
if not Assigned(Node) then
823
Node := Node.FirstChild;
824
while Assigned(Node) and (Node.NodeName <> 'title') do
825
Node := Node.NextSibling;
826
if not Assigned(Node) then
828
Node := Node.FirstChild;
829
if Assigned(Node) and (Node.NodeType = TEXT_NODE) then
830
Result := Node.NodeValue;
833
procedure THTMLDocument.SetTitle(const Value: DOMString);
836
TitleEl: TDOMElement;
838
if not Assigned(DocumentElement) then
839
AppendChild(CreateHtmlElement);
840
Node := DocumentElement.FirstChild;
841
while Assigned(Node) and (Node.NodeName <> 'head') do
842
Node := Node.NextSibling;
843
if not Assigned(Node) then
845
Node := CreateHeadElement;
846
DocumentElement.InsertBefore(Node, DocumentElement.FirstChild);
848
TitleEl := TDOMElement(Node.FirstChild);
849
while Assigned(TitleEl) and (TitleEl.NodeName <> 'title') do
850
TitleEl := TDOMElement(TitleEl.NextSibling);
851
if not Assigned(TitleEl) then
853
TitleEl := CreateElement('title');
854
Node.AppendChild(TitleEl);
856
while Assigned(TitleEl.FirstChild) do
857
TitleEl.RemoveChild(TitleEl.FirstChild);
858
TitleEl.AppendChild(CreateTextNode(Value));
861
procedure THTMLDocument.Write(const AText: DOMString);
865
procedure THTMLDocument.WriteLn(const AText: DOMString);
869
function THTMLDocument.GetElementsByName(const ElementName: DOMString): TDOMNodeList;
874
function THTMLDocument.CreateElement(const tagName: DOMString): THTMLElement;
876
Result := THTMLElement.Create(Self, tagName);
879
function THTMLDocument.CreateSubElement: THTMLElement; begin Result := CreateElement('sub') end;
880
function THTMLDocument.CreateSupElement: THTMLElement; begin Result := CreateElement('sup') end;
881
function THTMLDocument.CreateSpanElement: THTMLElement; begin Result := CreateElement('span') end;
882
function THTMLDocument.CreateBDOElement: THTMLElement; begin Result := CreateElement('bdo') end;
883
function THTMLDocument.CreateTTElement: THTMLElement; begin Result := CreateElement('tt') end;
884
function THTMLDocument.CreateIElement: THTMLElement; begin Result := CreateElement('i') end;
885
function THTMLDocument.CreateBElement: THTMLElement; begin Result := CreateElement('b') end;
886
function THTMLDocument.CreateUElement: THTMLElement; begin Result := CreateElement('u') end;
887
function THTMLDocument.CreateSElement: THTMLElement; begin Result := CreateElement('s') end;
888
function THTMLDocument.CreateStrikeElement: THTMLElement; begin Result := CreateElement('strike') end;
889
function THTMLDocument.CreateBigElement: THTMLElement; begin Result := CreateElement('big') end;
890
function THTMLDocument.CreateSmallElement: THTMLElement; begin Result := CreateElement('small') end;
891
function THTMLDocument.CreateEmElement: THTMLElement; begin Result := CreateElement('em') end;
892
function THTMLDocument.CreateStrongElement: THTMLElement; begin Result := CreateElement('strong') end;
893
function THTMLDocument.CreateDfnElement: THTMLElement; begin Result := CreateElement('dfn') end;
894
function THTMLDocument.CreateCodeElement: THTMLElement; begin Result := CreateElement('code') end;
895
function THTMLDocument.CreateSampElement: THTMLElement; begin Result := CreateElement('samp') end;
896
function THTMLDocument.CreateKbdElement: THTMLElement; begin Result := CreateElement('kbd') end;
897
function THTMLDocument.CreateVarElement: THTMLElement; begin Result := CreateElement('var') end;
898
function THTMLDocument.CreateCiteElement: THTMLElement; begin Result := CreateElement('cite') end;
899
function THTMLDocument.CreateAcronymElement: THTMLElement; begin Result := CreateElement('acronym') end;
900
function THTMLDocument.CreateAbbrElement: THTMLElement; begin Result := CreateElement('abbr') end;
901
function THTMLDocument.CreateDDElement: THTMLElement; begin Result := CreateElement('dd') end;
902
function THTMLDocument.CreateDTElement: THTMLElement; begin Result := CreateElement('dt') end;
903
function THTMLDocument.CreateNoFramesElement: THTMLElement; begin Result := CreateElement('noframes') end;
904
function THTMLDocument.CreateNoScriptElement: THTMLElement; begin Result := CreateElement('noscript') end;
905
function THTMLDocument.CreateAddressElement: THTMLElement; begin Result := CreateElement('address') end;
906
function THTMLDocument.CreateCenterElement: THTMLElement; begin Result := CreateElement('center') end;
907
function THTMLDocument.CreateHtmlElement: THTMLHtmlElement; begin Result := THTMLHtmlElement.Create(Self, 'html') end;
908
function THTMLDocument.CreateHeadElement: THTMLHeadElement; begin Result := THTMLHeadElement.Create(Self, 'head') end;
909
function THTMLDocument.CreateLinkElement: THTMLLinkElement; begin Result := THTMLLinkElement.Create(Self, 'a') end;
911
function THTMLDocument.CreateBodyElement: THTMLBodyElement; begin Result := THTMLBodyElement.Create(Self, 'body') end;
913
function THTMLDocument.CreateUListElement: THTMLUListElement; begin Result := THTMLUListElement.Create(Self, 'ul') end;
914
function THTMLDocument.CreateOListElement: THTMLOListElement; begin Result := THTMLOListElement.Create(Self, 'ol') end;
915
function THTMLDocument.CreateDListElement: THTMLDListElement; begin Result := THTMLDListElement.Create(Self, 'dl') end;
917
function THTMLDocument.CreateLIElement: THTMLLIElement; begin Result := THTMLLIElement.Create(Self, 'li') end;
919
function THTMLDocument.CreateParagraphElement: THTMLParagraphElement; begin Result := THTMLParagraphElement.Create(Self, 'p') end;