-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathhtmlglobal.mata
1864 lines (1215 loc) · 60.8 KB
/
htmlglobal.mata
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Switch to Mata interpreter/compiler
mata:
// Drops class object if it already exists
// mata drop htmlglobal()
// Static methods for HTML Global attributes
class htmlglobal {
// Define private member variables
private:
// String scalar attributes
string scalar htmlaccesskey, htmlclass, htmlcontenteditable,
htmlcontextmenu, htmldata, htmldir, htmldraggable,
htmldropzone, htmlhidden, htmlid, htmllang, htmlonabort,
htmlonafterprint, htmlonbeforeprint, htmlonbeforeunload,
htmlonblur, htmloncanplay, htmloncanplaythrough,
htmlonchange, htmlonclick, htmloncontextmenu, htmloncopy,
htmloncuechange, htmloncut, htmlondblclick, htmlondrag,
htmlondragend, htmlondragenter, htmlondragleave,
htmlondragover, htmlondragstart, htmlondrop,
htmlondurationchange, htmlonemptied, htmlonended,
htmlonerror, htmlonfocus, htmlonhashchange, htmloninput,
htmloninvalid, htmlonkeydown, htmlonkeypress, htmlonkeyup,
htmlonload, htmlonloadeddata, htmlonloadedmetadata,
htmlonloadstart, htmlonmessage, htmlonmousedown,
htmlonmousemove, htmlonmouseout, htmlonmouseover,
htmlonmouseup, htmlonmousewheel, htmlonoffline,
htmlononline, htmlonpagehide, htmlonpageshow, htmlonpaste,
htmlonpause, htmlonplay, htmlonplaying, htmlonpopstate,
htmlonprogress, htmlonratechange, htmlonreset, htmlonresize,
htmlonscroll, htmlonsearch, htmlonseeked, htmlonseeking,
htmlonselect, htmlonshow, htmlonstalled, htmlonstorage,
htmlonsubmit, htmlonsuspend, htmlontimeupdate, htmlontoggle,
htmlonunload, htmlonvolumechange, htmlonwaiting,
htmlonwheel, htmlspellcheck, htmlstyle, htmltabindex,
htmltitle, htmltranslate
// Define public members/methods
public:
// Setter methods
class htmlglobal scalar setAccesskey(), setClass(), setContenteditable(),
setContextmenu(), setData(), setDir(), setDraggable(),
setDropzone(), setHidden(), setId(), setLang(),
setOnabort(), setOnafterprint(), setOnbeforeprint(),
setOnbeforeunload(), setOnblur(), setOncanplay(),
setOncanplaythrough(), setOnchange(), setOnclick(),
setOncontextmenu(), setOncopy(), setOncuechange(),
setOncut(), setOndblclick(), setOndrag(), setOndragend(),
setOndragenter(), setOndragleave(), setOndragover(),
setOndragstart(), setOndrop(), setOndurationchange(),
setOnemptied(), setOnended(), setOnerror(), setOnfocus(),
setOnhashchange(), setOninput(), setOninvalid(),
setOnkeydown(), setOnkeypress(), setOnkeyup(), setOnload(),
setOnloadeddata(), setOnloadedmetadata(), setOnloadstart(),
setOnmessage(), setOnmousedown(), setOnmousemove(),
setOnmouseout(), setOnmouseover(), setOnmouseup(),
setOnmousewheel(), setOnoffline(), setOnonline(),
setOnpagehide(), setOnpageshow(), setOnpaste(),
setOnpause(), setOnplay(), setOnplaying(), setOnpopstate(),
setOnprogress(), setOnratechange(), setOnreset(),
setOnresize(), setOnscroll(), setOnsearch(), setOnseeked(),
setOnseeking(), setOnselect(), setOnshow(), setOnstalled(),
setOnstorage(), setOnsubmit(), setOnsuspend(),
setOntimeupdate(), setOntoggle(), setOnunload(),
setOnvolumechange(), setOnwaiting(), setOnwheel(),
setSpellcheck(), setStyle(), setTabindex(), setTitle(),
setTranslate(), setName()
// Getter methods
string scalar getAccesskey(), getClass(), getContenteditable(),
getContextmenu(), getData(), getDir(), getDraggable(),
getDropzone(), getHidden(), getId(), getLang(),
getOnabort(), getOnafterprint(), getOnbeforeprint(),
getOnbeforeunload(), getOnblur(), getOncanplay(),
getOncanplaythrough(), getOnchange(), getOnclick(),
getOncontextmenu(), getOncopy(), getOncuechange(),
getOncut(), getOndblclick(), getOndrag(), getOndragend(),
getOndragenter(), getOndragleave(), getOndragover(),
getOndragstart(), getOndrop(), getOndurationchange(),
getOnemptied(), getOnended(), getOnerror(), getOnfocus(),
getOnhashchange(), getOninput(), getOninvalid(),
getOnkeydown(), getOnkeypress(), getOnkeyup(), getOnload(),
getOnloadeddata(), getOnloadedmetadata(), getOnloadstart(),
getOnmessage(), getOnmousedown(), getOnmousemove(),
getOnmouseout(), getOnmouseover(), getOnmouseup(),
getOnmousewheel(), getOnoffline(), getOnonline(),
getOnpagehide(), getOnpageshow(), getOnpaste(),
getOnpause(), getOnplay(), getOnplaying(), getOnpopstate(),
getOnprogress(), getOnratechange(), getOnreset(),
getOnresize(), getOnscroll(), getOnsearch(), getOnseeked(),
getOnseeking(), getOnselect(), getOnshow(), getOnstalled(),
getOnstorage(), getOnsubmit(), getOnsuspend(),
getOntimeupdate(), getOntoggle(), getOnunload(),
getOnvolumechange(), getOnwaiting(), getOnwheel(),
getSpellcheck(), getStyle(), getTabindex(), getTitle(),
getTranslate()
// Print method
string scalar globalAttrs()
} // End class definition for HTML Global attributes
// Specifies a shortcut key to activate/focus an element
class htmlglobal scalar htmlglobal::setAccesskey(| string scalar methodarg) {
// Set the attribute accesskey for this class
this.htmlaccesskey = `" accesskey=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method accesskey declaration for class htmlglobal
// Specifies one or more classnames for an element (refers to a class in a style sheet)
class htmlglobal scalar htmlglobal::setClass(| string scalar methodarg) {
// Set the attribute class for this class
this.htmlclass = `" class=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method class declaration for class htmlglobal
// Specifies one or more classnames for an element (refers to a class in a style sheet)
class htmlglobal scalar htmlglobal::setName(| string scalar methodarg) {
// Set the attribute class for this class
this.htmlclass = `" name=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method class declaration for class htmlglobal
// Specifies whether the content of an element is editable or not
class htmlglobal scalar htmlglobal::setContenteditable(| string scalar methodarg) {
// Validate argument
if (methodarg == "true" | methodarg == "false") {
// Set the attribute value
this.htmlcontenteditable = `" contenteditable=""' + methodarg + `"""'
} // End IF Block for validated argument value
// Return a copy of the object
return(this)
} // End of Method contenteditable declaration for class htmlglobal
// Specifies a context menu for an element. The context menu appears when a user right-clicks on the element
class htmlglobal scalar htmlglobal::setContextmenu(| string scalar methodarg) {
// Set the attribute contextmenu for this class
this.htmlcontextmenu = `" contextmenu=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method contextmenu declaration for class htmlglobal
// Used to store custom data private to the page or application
class htmlglobal scalar htmlglobal::setData(| string scalar methodarg) {
// Set the attribute data for this class
this.htmldata = `" data=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method data declaration for class htmlglobal
// Specifies the text direction for the content in an element
class htmlglobal scalar htmlglobal::setDir(| string scalar methodarg) {
// Validate argument
if (methodarg == "ltr" | methodarg == "rtl" | methodarg == "auto") {
// Set the attribute value
this.htmldir = `" dir=""' + methodarg + `"""'
} // End IF Block for validated argument value
// Return a copy of the object
return(this)
} // End of Method dir declaration for class htmlglobal
// Specifies whether an element is draggable or not
class htmlglobal scalar htmlglobal::setDraggable(| string scalar methodarg) {
// Validate argument
if (methodarg == "true" | methodarg == "false" | methodarg == "auto") {
// Set the attribute value
this.htmldraggable = `" draggable=""' + methodarg + `"""'
} // End IF Block for validated argument value
// Return a copy of the object
return(this)
} // End of Method draggable declaration for class htmlglobal
// Specifies whether the dragged data is copied, moved, or linked, when dropped
class htmlglobal scalar htmlglobal::setDropzone(| string scalar methodarg) {
// Validate argument
if (methodarg == "copy" | methodarg == "move" | methodarg == "link") {
// Set the attribute value
this.htmldropzone = `" dropzone=""' + methodarg + `"""'
} // End IF Block for validated argument value
// Return a copy of the object
return(this)
} // End of Method dropzone declaration for class htmlglobal
// Specifies that an element is not yet, or is no longer, relevant
class htmlglobal scalar htmlglobal::setHidden(| string scalar methodarg) {
// Set the attribute hidden for this class
this.htmlhidden = `" hidden=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method hidden declaration for class htmlglobal
// Specifies a unique id for an element
class htmlglobal scalar htmlglobal::setId(| string scalar methodarg) {
// Set the attribute id for this class
this.htmlid = `" id=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method id declaration for class htmlglobal
// Specifies the language of the element's content
class htmlglobal scalar htmlglobal::setLang(| string scalar methodarg) {
// Set the attribute lang for this class
this.htmllang = `" lang=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method lang declaration for class htmlglobal
// Script to be run on abort
class htmlglobal scalar htmlglobal::setOnabort(| string scalar methodarg) {
// Set the attribute onabort for this class
this.htmlonabort = `" onabort=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onabort declaration for class htmlglobal
// Script to be run after the document is printed
class htmlglobal scalar htmlglobal::setOnafterprint(| string scalar methodarg) {
// Set the attribute onafterprint for this class
this.htmlonafterprint = `" onafterprint=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onafterprint declaration for class htmlglobal
// Script to be run before the document is printed
class htmlglobal scalar htmlglobal::setOnbeforeprint(| string scalar methodarg) {
// Set the attribute onbeforeprint for this class
this.htmlonbeforeprint = `" onbeforeprint=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onbeforeprint declaration for class htmlglobal
// Script to be run when the document is about to be unloaded
class htmlglobal scalar htmlglobal::setOnbeforeunload(| string scalar methodarg) {
// Set the attribute onbeforeunload for this class
this.htmlonbeforeunload = `" onbeforeunload=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onbeforeunload declaration for class htmlglobal
// Fires the moment that the element loses focus
class htmlglobal scalar htmlglobal::setOnblur(| string scalar methodarg) {
// Set the attribute onblur for this class
this.htmlonblur = `" onblur=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onblur declaration for class htmlglobal
// Script to be run when a file is ready to start playing (when it has buffered enough to begin)
class htmlglobal scalar htmlglobal::setOncanplay(| string scalar methodarg) {
// Set the attribute oncanplay for this class
this.htmloncanplay = `" oncanplay=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncanplay declaration for class htmlglobal
// Script to be run when a file can be played all the way to the end without pausing for buffering
class htmlglobal scalar htmlglobal::setOncanplaythrough(| string scalar methodarg) {
// Set the attribute oncanplaythrough for this class
this.htmloncanplaythrough = `" oncanplaythrough=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncanplaythrough declaration for class htmlglobal
// Fires the moment when the value of the element is changed
class htmlglobal scalar htmlglobal::setOnchange(| string scalar methodarg) {
// Set the attribute onchange for this class
this.htmlonchange = `" onchange=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onchange declaration for class htmlglobal
// Fires on a mouse click on the element
class htmlglobal scalar htmlglobal::setOnclick(| string scalar methodarg) {
// Set the attribute onclick for this class
this.htmlonclick = `" onclick=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onclick declaration for class htmlglobal
// Script to be run when a context menu is triggered
class htmlglobal scalar htmlglobal::setOncontextmenu(| string scalar methodarg) {
// Set the attribute oncontextmenu for this class
this.htmloncontextmenu = `" oncontextmenu=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncontextmenu declaration for class htmlglobal
// Fires when the user copies the content of an element
class htmlglobal scalar htmlglobal::setOncopy(| string scalar methodarg) {
// Set the attribute oncopy for this class
this.htmloncopy = `" oncopy=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncopy declaration for class htmlglobal
// Script to be run when the cue changes in a <track> element
class htmlglobal scalar htmlglobal::setOncuechange(| string scalar methodarg) {
// Set the attribute oncuechange for this class
this.htmloncuechange = `" oncuechange=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncuechange declaration for class htmlglobal
// Fires when the user cuts the content of an element
class htmlglobal scalar htmlglobal::setOncut(| string scalar methodarg) {
// Set the attribute oncut for this class
this.htmloncut = `" oncut=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oncut declaration for class htmlglobal
// Fires on a mouse double-click on the element
class htmlglobal scalar htmlglobal::setOndblclick(| string scalar methodarg) {
// Set the attribute ondblclick for this class
this.htmlondblclick = `" ondblclick=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondblclick declaration for class htmlglobal
// Script to be run when an element is dragged
class htmlglobal scalar htmlglobal::setOndrag(| string scalar methodarg) {
// Set the attribute ondrag for this class
this.htmlondrag = `" ondrag=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondrag declaration for class htmlglobal
// Script to be run at the end of a drag operation
class htmlglobal scalar htmlglobal::setOndragend(| string scalar methodarg) {
// Set the attribute ondragend for this class
this.htmlondragend = `" ondragend=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondragend declaration for class htmlglobal
// Script to be run when an element has been dragged to a valid drop target
class htmlglobal scalar htmlglobal::setOndragenter(| string scalar methodarg) {
// Set the attribute ondragenter for this class
this.htmlondragenter = `" ondragenter=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondragenter declaration for class htmlglobal
// Script to be run when an element leaves a valid drop target
class htmlglobal scalar htmlglobal::setOndragleave(| string scalar methodarg) {
// Set the attribute ondragleave for this class
this.htmlondragleave = `" ondragleave=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondragleave declaration for class htmlglobal
// Script to be run when an element is being dragged over a valid drop target
class htmlglobal scalar htmlglobal::setOndragover(| string scalar methodarg) {
// Set the attribute ondragover for this class
this.htmlondragover = `" ondragover=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondragover declaration for class htmlglobal
// Script to be run at the start of a drag operation
class htmlglobal scalar htmlglobal::setOndragstart(| string scalar methodarg) {
// Set the attribute ondragstart for this class
this.htmlondragstart = `" ondragstart=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondragstart declaration for class htmlglobal
// Script to be run when dragged element is being dropped
class htmlglobal scalar htmlglobal::setOndrop(| string scalar methodarg) {
// Set the attribute ondrop for this class
this.htmlondrop = `" ondrop=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondrop declaration for class htmlglobal
// Script to be run when the length of the media changes
class htmlglobal scalar htmlglobal::setOndurationchange(| string scalar methodarg) {
// Set the attribute ondurationchange for this class
this.htmlondurationchange = `" ondurationchange=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ondurationchange declaration for class htmlglobal
// Script to be run when something bad happens and the file is suddenly unavailable (like unexpectedly disconnects)
class htmlglobal scalar htmlglobal::setOnemptied(| string scalar methodarg) {
// Set the attribute onemptied for this class
this.htmlonemptied = `" onemptied=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onemptied declaration for class htmlglobal
// Script to be run when the media has reach the end (a useful event for messages like "thanks for listening")
class htmlglobal scalar htmlglobal::setOnended(| string scalar methodarg) {
// Set the attribute onended for this class
this.htmlonended = `" onended=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onended declaration for class htmlglobal
// Fires when an error occurs while loading an external file Script to be run when an error occur Script to be run when an error occurs when the file is being loaded
class htmlglobal scalar htmlglobal::setOnerror(| string scalar methodarg) {
// Set the attribute onerror for this class
this.htmlonerror = `" onerror=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onerror declaration for class htmlglobal
// Fires the moment when the element gets focus
class htmlglobal scalar htmlglobal::setOnfocus(| string scalar methodarg) {
// Set the attribute onfocus for this class
this.htmlonfocus = `" onfocus=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onfocus declaration for class htmlglobal
// Script to be run when there has been changes to the anchor part of the a URL
class htmlglobal scalar htmlglobal::setOnhashchange(| string scalar methodarg) {
// Set the attribute onhashchange for this class
this.htmlonhashchange = `" onhashchange=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onhashchange declaration for class htmlglobal
// Script to be run when an element gets user input
class htmlglobal scalar htmlglobal::setOninput(| string scalar methodarg) {
// Set the attribute oninput for this class
this.htmloninput = `" oninput=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oninput declaration for class htmlglobal
// Script to be run when an element is invalid
class htmlglobal scalar htmlglobal::setOninvalid(| string scalar methodarg) {
// Set the attribute oninvalid for this class
this.htmloninvalid = `" oninvalid=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method oninvalid declaration for class htmlglobal
// Fires when a user is pressing a key
class htmlglobal scalar htmlglobal::setOnkeydown(| string scalar methodarg) {
// Set the attribute onkeydown for this class
this.htmlonkeydown = `" onkeydown=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onkeydown declaration for class htmlglobal
// Fires when a user presses a key
class htmlglobal scalar htmlglobal::setOnkeypress(| string scalar methodarg) {
// Set the attribute onkeypress for this class
this.htmlonkeypress = `" onkeypress=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onkeypress declaration for class htmlglobal
// Fires when a user releases a key
class htmlglobal scalar htmlglobal::setOnkeyup(| string scalar methodarg) {
// Set the attribute onkeyup for this class
this.htmlonkeyup = `" onkeyup=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onkeyup declaration for class htmlglobal
// Fires after the page is finished loading
class htmlglobal scalar htmlglobal::setOnload(| string scalar methodarg) {
// Set the attribute onload for this class
this.htmlonload = `" onload=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onload declaration for class htmlglobal
// Script to be run when media data is loaded
class htmlglobal scalar htmlglobal::setOnloadeddata(| string scalar methodarg) {
// Set the attribute onloadeddata for this class
this.htmlonloadeddata = `" onloadeddata=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onloadeddata declaration for class htmlglobal
// Script to be run when meta data (like dimensions and duration) are loaded
class htmlglobal scalar htmlglobal::setOnloadedmetadata(| string scalar methodarg) {
// Set the attribute onloadedmetadata for this class
this.htmlonloadedmetadata = `" onloadedmetadata=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onloadedmetadata declaration for class htmlglobal
// Script to be run just as the file begins to load before anything is actually loaded
class htmlglobal scalar htmlglobal::setOnloadstart(| string scalar methodarg) {
// Set the attribute onloadstart for this class
this.htmlonloadstart = `" onloadstart=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onloadstart declaration for class htmlglobal
// Script to be run when the message is triggered
class htmlglobal scalar htmlglobal::setOnmessage(| string scalar methodarg) {
// Set the attribute onmessage for this class
this.htmlonmessage = `" onmessage=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmessage declaration for class htmlglobal
// Fires when a mouse button is pressed down on an element
class htmlglobal scalar htmlglobal::setOnmousedown(| string scalar methodarg) {
// Set the attribute onmousedown for this class
this.htmlonmousedown = `" onmousedown=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmousedown declaration for class htmlglobal
// Fires when the mouse pointer is moving while it is over an element
class htmlglobal scalar htmlglobal::setOnmousemove(| string scalar methodarg) {
// Set the attribute onmousemove for this class
this.htmlonmousemove = `" onmousemove=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmousemove declaration for class htmlglobal
// Fires when the mouse pointer moves out of an element
class htmlglobal scalar htmlglobal::setOnmouseout(| string scalar methodarg) {
// Set the attribute onmouseout for this class
this.htmlonmouseout = `" onmouseout=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmouseout declaration for class htmlglobal
// Fires when the mouse pointer moves over an element
class htmlglobal scalar htmlglobal::setOnmouseover(| string scalar methodarg) {
// Set the attribute onmouseover for this class
this.htmlonmouseover = `" onmouseover=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmouseover declaration for class htmlglobal
// Fires when a mouse button is released over an element
class htmlglobal scalar htmlglobal::setOnmouseup(| string scalar methodarg) {
// Set the attribute onmouseup for this class
this.htmlonmouseup = `" onmouseup=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmouseup declaration for class htmlglobal
// Deprecated. Use the onwheel attribute instead
class htmlglobal scalar htmlglobal::setOnmousewheel(| string scalar methodarg) {
// Set the attribute onmousewheel for this class
this.htmlonmousewheel = `" onmousewheel=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onmousewheel declaration for class htmlglobal
// Script to be run when the browser starts to work offline
class htmlglobal scalar htmlglobal::setOnoffline(| string scalar methodarg) {
// Set the attribute onoffline for this class
this.htmlonoffline = `" onoffline=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onoffline declaration for class htmlglobal
// Script to be run when the browser starts to work online
class htmlglobal scalar htmlglobal::setOnonline(| string scalar methodarg) {
// Set the attribute ononline for this class
this.htmlononline = `" ononline=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ononline declaration for class htmlglobal
// Script to be run when a user navigates away from a page
class htmlglobal scalar htmlglobal::setOnpagehide(| string scalar methodarg) {
// Set the attribute onpagehide for this class
this.htmlonpagehide = `" onpagehide=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onpagehide declaration for class htmlglobal
// Script to be run when a user navigates to a page
class htmlglobal scalar htmlglobal::setOnpageshow(| string scalar methodarg) {
// Set the attribute onpageshow for this class
this.htmlonpageshow = `" onpageshow=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onpageshow declaration for class htmlglobal
// Fires when the user pastes some content in an element
class htmlglobal scalar htmlglobal::setOnpaste(| string scalar methodarg) {
// Set the attribute onpaste for this class
this.htmlonpaste = `" onpaste=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onpaste declaration for class htmlglobal
// Script to be run when the media is paused either by the user or programmatically
class htmlglobal scalar htmlglobal::setOnpause(| string scalar methodarg) {
// Set the attribute onpause for this class
this.htmlonpause = `" onpause=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onpause declaration for class htmlglobal
// Script to be run when the media is ready to start playing
class htmlglobal scalar htmlglobal::setOnplay(| string scalar methodarg) {
// Set the attribute onplay for this class
this.htmlonplay = `" onplay=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onplay declaration for class htmlglobal
// Script to be run when the media actually has started playing
class htmlglobal scalar htmlglobal::setOnplaying(| string scalar methodarg) {
// Set the attribute onplaying for this class
this.htmlonplaying = `" onplaying=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onplaying declaration for class htmlglobal
// Script to be run when the window's history changes
class htmlglobal scalar htmlglobal::setOnpopstate(| string scalar methodarg) {
// Set the attribute onpopstate for this class
this.htmlonpopstate = `" onpopstate=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onpopstate declaration for class htmlglobal
// Script to be run when the browser is in the process of getting the media data
class htmlglobal scalar htmlglobal::setOnprogress(| string scalar methodarg) {
// Set the attribute onprogress for this class
this.htmlonprogress = `" onprogress=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onprogress declaration for class htmlglobal
// Script to be run each time the playback rate changes (like when a user switches to a slow motion or fast forward mode)
class htmlglobal scalar htmlglobal::setOnratechange(| string scalar methodarg) {
// Set the attribute onratechange for this class
this.htmlonratechange = `" onratechange=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onratechange declaration for class htmlglobal
// Fires when the Reset button in a form is clicked
class htmlglobal scalar htmlglobal::setOnreset(| string scalar methodarg) {
// Set the attribute onreset for this class
this.htmlonreset = `" onreset=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onreset declaration for class htmlglobal
// Fires when the browser window is resized
class htmlglobal scalar htmlglobal::setOnresize(| string scalar methodarg) {
// Set the attribute onresize for this class
this.htmlonresize = `" onresize=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onresize declaration for class htmlglobal
// Script to be run when an element's scrollbar is being scrolled
class htmlglobal scalar htmlglobal::setOnscroll(| string scalar methodarg) {
// Set the attribute onscroll for this class
this.htmlonscroll = `" onscroll=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onscroll declaration for class htmlglobal
// Fires when the user writes something in a search field (for <input="search">)
class htmlglobal scalar htmlglobal::setOnsearch(| string scalar methodarg) {
// Set the attribute onsearch for this class
this.htmlonsearch = `" onsearch=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onsearch declaration for class htmlglobal
// Script to be run when the seeking attribute is set to false indicating that seeking has ended
class htmlglobal scalar htmlglobal::setOnseeked(| string scalar methodarg) {
// Set the attribute onseeked for this class
this.htmlonseeked = `" onseeked=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onseeked declaration for class htmlglobal
// Script to be run when the seeking attribute is set to true indicating that seeking is active
class htmlglobal scalar htmlglobal::setOnseeking(| string scalar methodarg) {
// Set the attribute onseeking for this class
this.htmlonseeking = `" onseeking=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onseeking declaration for class htmlglobal
// Fires after some text has been selected in an element
class htmlglobal scalar htmlglobal::setOnselect(| string scalar methodarg) {
// Set the attribute onselect for this class
this.htmlonselect = `" onselect=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onselect declaration for class htmlglobal
// Fires when a <menu> element is shown as a context menu
class htmlglobal scalar htmlglobal::setOnshow(| string scalar methodarg) {
// Set the attribute onshow for this class
this.htmlonshow = `" onshow=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onshow declaration for class htmlglobal
// Script to be run when the browser is unable to fetch the media data for whatever reason
class htmlglobal scalar htmlglobal::setOnstalled(| string scalar methodarg) {
// Set the attribute onstalled for this class
this.htmlonstalled = `" onstalled=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onstalled declaration for class htmlglobal
// Script to be run when a Web Storage area is updated
class htmlglobal scalar htmlglobal::setOnstorage(| string scalar methodarg) {
// Set the attribute onstorage for this class
this.htmlonstorage = `" onstorage=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onstorage declaration for class htmlglobal
// Fires when a form is submitted
class htmlglobal scalar htmlglobal::setOnsubmit(| string scalar methodarg) {
// Set the attribute onsubmit for this class
this.htmlonsubmit = `" onsubmit=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onsubmit declaration for class htmlglobal
// Script to be run when fetching the media data is stopped before it is completely loaded for whatever reason
class htmlglobal scalar htmlglobal::setOnsuspend(| string scalar methodarg) {
// Set the attribute onsuspend for this class
this.htmlonsuspend = `" onsuspend=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method onsuspend declaration for class htmlglobal
// Script to be run when the playing position has changed (like when the user fast forwards to a different point in the media)
class htmlglobal scalar htmlglobal::setOntimeupdate(| string scalar methodarg) {
// Set the attribute ontimeupdate for this class
this.htmlontimeupdate = `" ontimeupdate=""' + methodarg + `"""'
// Return a copy of the object
return(this)
} // End of Method ontimeupdate declaration for class htmlglobal
// Fires when the user opens or closes the <details> element
class htmlglobal scalar htmlglobal::setOntoggle(| string scalar methodarg) {
// Set the attribute ontoggle for this class
this.htmlontoggle = `" ontoggle=""' + methodarg + `"""'