dxopal 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (64) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +5 -0
  3. data/.ignore +5 -0
  4. data/.nojekyll +4 -0
  5. data/CHANGELOG.md +90 -0
  6. data/DEVELOPMENT.md +57 -0
  7. data/Gemfile +2 -0
  8. data/Gemfile.lock +39 -0
  9. data/README.md +22 -0
  10. data/Rakefile +66 -0
  11. data/TODO.md +278 -0
  12. data/build/dxopal.js +46590 -0
  13. data/build/dxopal.min.js +1 -0
  14. data/config.ru +39 -0
  15. data/doc/api/DXOpal.html +129 -0
  16. data/doc/api/DXOpal/Font.html +485 -0
  17. data/doc/api/DXOpal/Image.html +2533 -0
  18. data/doc/api/DXOpal/Input.html +1086 -0
  19. data/doc/api/DXOpal/Input/MouseCodes.html +146 -0
  20. data/doc/api/DXOpal/RemoteResource.html +641 -0
  21. data/doc/api/DXOpal/Sound.html +568 -0
  22. data/doc/api/DXOpal/SoundEffect.html +444 -0
  23. data/doc/api/DXOpal/SoundEffect/WaveTypes.html +130 -0
  24. data/doc/api/DXOpal/Sprite.html +1419 -0
  25. data/doc/api/DXOpal/Window.html +1915 -0
  26. data/doc/api/_index.html +228 -0
  27. data/doc/api/class_list.html +51 -0
  28. data/doc/api/css/common.css +1 -0
  29. data/doc/api/css/full_list.css +58 -0
  30. data/doc/api/css/style.css +492 -0
  31. data/doc/api/file.CHANGELOG.html +162 -0
  32. data/doc/api/file.README.html +124 -0
  33. data/doc/api/file_list.html +61 -0
  34. data/doc/api/frames.html +17 -0
  35. data/doc/api/index.html +124 -0
  36. data/doc/api/js/app.js +248 -0
  37. data/doc/api/js/full_list.js +216 -0
  38. data/doc/api/js/jquery.js +4 -0
  39. data/doc/api/method_list.html +939 -0
  40. data/doc/api/top-level-namespace.html +110 -0
  41. data/doc/en/index.html +93 -0
  42. data/doc/ja/index.html +92 -0
  43. data/dxopal.gemspec +29 -0
  44. data/exe/dxopal +44 -0
  45. data/index.html +56 -0
  46. data/opal/dxopal.rb +54 -0
  47. data/opal/dxopal/constants/colors.rb +16 -0
  48. data/opal/dxopal/font.rb +20 -0
  49. data/opal/dxopal/image.rb +301 -0
  50. data/opal/dxopal/input.rb +170 -0
  51. data/opal/dxopal/input/key_codes.rb +168 -0
  52. data/opal/dxopal/remote_resource.rb +65 -0
  53. data/opal/dxopal/sound.rb +53 -0
  54. data/opal/dxopal/sound_effect.rb +84 -0
  55. data/opal/dxopal/sprite.rb +94 -0
  56. data/opal/dxopal/sprite/collision_area.rb +288 -0
  57. data/opal/dxopal/sprite/collision_check.rb +106 -0
  58. data/opal/dxopal/sprite/collision_checker.rb +169 -0
  59. data/opal/dxopal/sprite/physics.rb +82 -0
  60. data/opal/dxopal/version.rb +3 -0
  61. data/opal/dxopal/window.rb +173 -0
  62. data/template/index.html +13 -0
  63. data/template/main.rb +9 -0
  64. metadata +191 -0
@@ -0,0 +1,1915 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Module: DXOpal::Window
8
+
9
+ &mdash; Documentation by YARD 0.9.9
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ pathId = "DXOpal::Window";
19
+ relpath = '../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../_index.html">Index (W)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../DXOpal.html" title="DXOpal (module)">DXOpal</a></span></span>
41
+ &raquo;
42
+ <span class="title">Window</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Module: DXOpal::Window
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+
70
+
71
+
72
+
73
+
74
+
75
+
76
+
77
+
78
+
79
+ <dl>
80
+ <dt>Defined in:</dt>
81
+ <dd>opal/dxopal/window.rb</dd>
82
+ </dl>
83
+
84
+ </div>
85
+
86
+
87
+ <h2>Constant Summary</h2>
88
+ <dl class="constants">
89
+
90
+ <dt id="fps-classvariable" class="">@@fps =
91
+
92
+ </dt>
93
+ <dd><pre class="code"><span class='int'>60</span></pre></dd>
94
+
95
+ <dt id="real_fps-classvariable" class="">@@real_fps =
96
+
97
+ </dt>
98
+ <dd><pre class="code"><span class='int'>0</span></pre></dd>
99
+
100
+ <dt id="real_fps_ct-classvariable" class="">@@real_fps_ct =
101
+
102
+ </dt>
103
+ <dd><pre class="code"><span class='int'>1</span></pre></dd>
104
+
105
+ <dt id="real_fps_t-classvariable" class="">@@real_fps_t =
106
+
107
+ </dt>
108
+ <dd><pre class="code"><span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span></pre></dd>
109
+
110
+ <dt id="width-classvariable" class="">@@width =
111
+
112
+ </dt>
113
+ <dd><pre class="code"><span class='int'>640</span></pre></dd>
114
+
115
+ <dt id="height-classvariable" class="">@@height =
116
+
117
+ </dt>
118
+ <dd><pre class="code"><span class='int'>480</span></pre></dd>
119
+
120
+ <dt id="block-classvariable" class="">@@block =
121
+
122
+ </dt>
123
+ <dd><pre class="code"><span class='kw'>nil</span></pre></dd>
124
+
125
+ <dt id="paused-classvariable" class="">@@paused =
126
+
127
+ </dt>
128
+ <dd><pre class="code"><span class='kw'>false</span></pre></dd>
129
+
130
+ <dt id="bgcolor-classvariable" class="">@@bgcolor =
131
+
132
+ </dt>
133
+ <dd><pre class="code"><span class='const'>Constants</span><span class='op'>::</span><span class='const'>Colors</span><span class='op'>::</span><span class='const'>C_BLACK</span></pre></dd>
134
+
135
+ </dl>
136
+
137
+
138
+
139
+
140
+
141
+
142
+
143
+
144
+ <h2>
145
+ Class Method Summary
146
+ <small><a href="#" class="summary_toggle">collapse</a></small>
147
+ </h2>
148
+
149
+ <ul class="summary">
150
+
151
+ <li class="public ">
152
+ <span class="summary_signature">
153
+
154
+ <a href="#_img-class_method" title="_img (class method)">.<strong>_img</strong> &#x21d2; Object </a>
155
+
156
+
157
+
158
+ </span>
159
+
160
+
161
+
162
+
163
+
164
+
165
+
166
+
167
+
168
+ <span class="summary_desc"><div class='inline'>
169
+ <p>Return internal DXOpal::Image object (for experimental/hacking use).</p>
170
+ </div></span>
171
+
172
+ </li>
173
+
174
+
175
+ <li class="public ">
176
+ <span class="summary_signature">
177
+
178
+ <a href="#_init-class_method" title="_init (class method)">.<strong>_init</strong>(w, h) &#x21d2; Object </a>
179
+
180
+
181
+
182
+ </span>
183
+
184
+
185
+
186
+
187
+
188
+
189
+
190
+
191
+
192
+ <span class="summary_desc"><div class='inline'></div></span>
193
+
194
+ </li>
195
+
196
+
197
+ <li class="public ">
198
+ <span class="summary_signature">
199
+
200
+ <a href="#_loop-class_method" title="_loop (class method)">.<strong>_loop</strong>(time, &amp;block) &#x21d2; Object </a>
201
+
202
+
203
+
204
+ </span>
205
+
206
+
207
+
208
+
209
+
210
+
211
+
212
+
213
+
214
+ <span class="summary_desc"><div class='inline'></div></span>
215
+
216
+ </li>
217
+
218
+
219
+ <li class="public ">
220
+ <span class="summary_signature">
221
+
222
+ <a href="#bgcolor-class_method" title="bgcolor (class method)">.<strong>bgcolor</strong> &#x21d2; Object </a>
223
+
224
+
225
+
226
+ </span>
227
+
228
+
229
+
230
+
231
+
232
+
233
+
234
+
235
+
236
+ <span class="summary_desc"><div class='inline'></div></span>
237
+
238
+ </li>
239
+
240
+
241
+ <li class="public ">
242
+ <span class="summary_signature">
243
+
244
+ <a href="#bgcolor=-class_method" title="bgcolor= (class method)">.<strong>bgcolor=</strong>(col) &#x21d2; Object </a>
245
+
246
+
247
+
248
+ </span>
249
+
250
+
251
+
252
+
253
+
254
+
255
+
256
+
257
+
258
+ <span class="summary_desc"><div class='inline'></div></span>
259
+
260
+ </li>
261
+
262
+
263
+ <li class="public ">
264
+ <span class="summary_signature">
265
+
266
+ <a href="#draw-class_method" title="draw (class method)">.<strong>draw</strong>(x, y, image, z = 0) &#x21d2; Object </a>
267
+
268
+
269
+
270
+ </span>
271
+
272
+
273
+
274
+
275
+
276
+
277
+
278
+
279
+
280
+ <span class="summary_desc"><div class='inline'></div></span>
281
+
282
+ </li>
283
+
284
+
285
+ <li class="public ">
286
+ <span class="summary_signature">
287
+
288
+ <a href="#draw_box-class_method" title="draw_box (class method)">.<strong>draw_box</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; Object </a>
289
+
290
+
291
+
292
+ </span>
293
+
294
+
295
+
296
+
297
+
298
+
299
+
300
+
301
+
302
+ <span class="summary_desc"><div class='inline'></div></span>
303
+
304
+ </li>
305
+
306
+
307
+ <li class="public ">
308
+ <span class="summary_signature">
309
+
310
+ <a href="#draw_box_fill-class_method" title="draw_box_fill (class method)">.<strong>draw_box_fill</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; Object </a>
311
+
312
+
313
+
314
+ </span>
315
+
316
+
317
+
318
+
319
+
320
+
321
+
322
+
323
+
324
+ <span class="summary_desc"><div class='inline'></div></span>
325
+
326
+ </li>
327
+
328
+
329
+ <li class="public ">
330
+ <span class="summary_signature">
331
+
332
+ <a href="#draw_circle-class_method" title="draw_circle (class method)">.<strong>draw_circle</strong>(x, y, r, color, z = 0) &#x21d2; Object </a>
333
+
334
+
335
+
336
+ </span>
337
+
338
+
339
+
340
+
341
+
342
+
343
+
344
+
345
+
346
+ <span class="summary_desc"><div class='inline'></div></span>
347
+
348
+ </li>
349
+
350
+
351
+ <li class="public ">
352
+ <span class="summary_signature">
353
+
354
+ <a href="#draw_circle_fill-class_method" title="draw_circle_fill (class method)">.<strong>draw_circle_fill</strong>(x, y, r, color, z = 0) &#x21d2; Object </a>
355
+
356
+
357
+
358
+ </span>
359
+
360
+
361
+
362
+
363
+
364
+
365
+
366
+
367
+
368
+ <span class="summary_desc"><div class='inline'></div></span>
369
+
370
+ </li>
371
+
372
+
373
+ <li class="public ">
374
+ <span class="summary_signature">
375
+
376
+ <a href="#draw_ex-class_method" title="draw_ex (class method)">.<strong>draw_ex</strong>(x, y, image, options = {}) &#x21d2; Object </a>
377
+
378
+
379
+
380
+ </span>
381
+
382
+
383
+
384
+
385
+
386
+
387
+
388
+
389
+
390
+ <span class="summary_desc"><div class='inline'></div></span>
391
+
392
+ </li>
393
+
394
+
395
+ <li class="public ">
396
+ <span class="summary_signature">
397
+
398
+ <a href="#draw_font-class_method" title="draw_font (class method)">.<strong>draw_font</strong>(x, y, string, font, option = {}) &#x21d2; Object </a>
399
+
400
+
401
+
402
+ </span>
403
+
404
+
405
+
406
+
407
+
408
+
409
+
410
+
411
+
412
+ <span class="summary_desc"><div class='inline'></div></span>
413
+
414
+ </li>
415
+
416
+
417
+ <li class="public ">
418
+ <span class="summary_signature">
419
+
420
+ <a href="#draw_line-class_method" title="draw_line (class method)">.<strong>draw_line</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; Object </a>
421
+
422
+
423
+
424
+ </span>
425
+
426
+
427
+
428
+
429
+
430
+
431
+
432
+
433
+
434
+ <span class="summary_desc"><div class='inline'></div></span>
435
+
436
+ </li>
437
+
438
+
439
+ <li class="public ">
440
+ <span class="summary_signature">
441
+
442
+ <a href="#draw_pause_screen-class_method" title="draw_pause_screen (class method)">.<strong>draw_pause_screen</strong> &#x21d2; Object </a>
443
+
444
+
445
+
446
+ </span>
447
+
448
+
449
+
450
+
451
+
452
+
453
+
454
+
455
+
456
+ <span class="summary_desc"><div class='inline'></div></span>
457
+
458
+ </li>
459
+
460
+
461
+ <li class="public ">
462
+ <span class="summary_signature">
463
+
464
+ <a href="#draw_pixel-class_method" title="draw_pixel (class method)">.<strong>draw_pixel</strong>(x, y, color, z = 0) &#x21d2; Object </a>
465
+
466
+
467
+
468
+ </span>
469
+
470
+
471
+
472
+
473
+
474
+
475
+
476
+
477
+
478
+ <span class="summary_desc"><div class='inline'></div></span>
479
+
480
+ </li>
481
+
482
+
483
+ <li class="public ">
484
+ <span class="summary_signature">
485
+
486
+ <a href="#draw_rot-class_method" title="draw_rot (class method)">.<strong>draw_rot</strong>(x, y, image, angle, center_x = nil, center_y = nil, z = 0) &#x21d2; Object </a>
487
+
488
+
489
+
490
+ </span>
491
+
492
+
493
+
494
+
495
+
496
+
497
+
498
+
499
+
500
+ <span class="summary_desc"><div class='inline'></div></span>
501
+
502
+ </li>
503
+
504
+
505
+ <li class="public ">
506
+ <span class="summary_signature">
507
+
508
+ <a href="#draw_triangle-class_method" title="draw_triangle (class method)">.<strong>draw_triangle</strong>(x1, y1, x2, y2, x3, y3, color, z = 0) &#x21d2; Object </a>
509
+
510
+
511
+
512
+ </span>
513
+
514
+
515
+
516
+
517
+
518
+
519
+
520
+
521
+
522
+ <span class="summary_desc"><div class='inline'></div></span>
523
+
524
+ </li>
525
+
526
+
527
+ <li class="public ">
528
+ <span class="summary_signature">
529
+
530
+ <a href="#draw_triangle_fill-class_method" title="draw_triangle_fill (class method)">.<strong>draw_triangle_fill</strong>(x1, y1, x2, y2, x3, y3, color, z = 0) &#x21d2; Object </a>
531
+
532
+
533
+
534
+ </span>
535
+
536
+
537
+
538
+
539
+
540
+
541
+
542
+
543
+
544
+ <span class="summary_desc"><div class='inline'></div></span>
545
+
546
+ </li>
547
+
548
+
549
+ <li class="public ">
550
+ <span class="summary_signature">
551
+
552
+ <a href="#enqueue_draw-class_method" title="enqueue_draw (class method)">.<strong>enqueue_draw</strong>(z, *args) &#x21d2; Object </a>
553
+
554
+
555
+
556
+ </span>
557
+
558
+
559
+
560
+
561
+
562
+
563
+
564
+
565
+
566
+ <span class="summary_desc"><div class='inline'></div></span>
567
+
568
+ </li>
569
+
570
+
571
+ <li class="public ">
572
+ <span class="summary_signature">
573
+
574
+ <a href="#fps-class_method" title="fps (class method)">.<strong>fps</strong> &#x21d2; Object </a>
575
+
576
+
577
+
578
+ </span>
579
+
580
+
581
+
582
+
583
+
584
+
585
+
586
+
587
+
588
+ <span class="summary_desc"><div class='inline'></div></span>
589
+
590
+ </li>
591
+
592
+
593
+ <li class="public ">
594
+ <span class="summary_signature">
595
+
596
+ <a href="#fps=-class_method" title="fps= (class method)">.<strong>fps=</strong>(w) &#x21d2; Object </a>
597
+
598
+
599
+
600
+ </span>
601
+
602
+
603
+
604
+
605
+
606
+
607
+
608
+
609
+
610
+ <span class="summary_desc"><div class='inline'></div></span>
611
+
612
+ </li>
613
+
614
+
615
+ <li class="public ">
616
+ <span class="summary_signature">
617
+
618
+ <a href="#height-class_method" title="height (class method)">.<strong>height</strong> &#x21d2; Object </a>
619
+
620
+
621
+
622
+ </span>
623
+
624
+
625
+
626
+
627
+
628
+
629
+
630
+
631
+
632
+ <span class="summary_desc"><div class='inline'></div></span>
633
+
634
+ </li>
635
+
636
+
637
+ <li class="public ">
638
+ <span class="summary_signature">
639
+
640
+ <a href="#height=-class_method" title="height= (class method)">.<strong>height=</strong>(h) &#x21d2; Object </a>
641
+
642
+
643
+
644
+ </span>
645
+
646
+
647
+
648
+
649
+
650
+
651
+
652
+
653
+
654
+ <span class="summary_desc"><div class='inline'></div></span>
655
+
656
+ </li>
657
+
658
+
659
+ <li class="public ">
660
+ <span class="summary_signature">
661
+
662
+ <a href="#load_resources-class_method" title="load_resources (class method)">.<strong>load_resources</strong>(&amp;block) &#x21d2; Object </a>
663
+
664
+
665
+
666
+ </span>
667
+
668
+
669
+
670
+
671
+
672
+
673
+
674
+
675
+
676
+ <span class="summary_desc"><div class='inline'>
677
+ <p>Load resources specified with Image.register or Sound.register Call block
678
+ when loaded.</p>
679
+ </div></span>
680
+
681
+ </li>
682
+
683
+
684
+ <li class="public ">
685
+ <span class="summary_signature">
686
+
687
+ <a href="#loop-class_method" title="loop (class method)">.<strong>loop</strong>(&amp;block) &#x21d2; Object </a>
688
+
689
+
690
+
691
+ </span>
692
+
693
+
694
+
695
+
696
+
697
+
698
+
699
+
700
+
701
+ <span class="summary_desc"><div class='inline'></div></span>
702
+
703
+ </li>
704
+
705
+
706
+ <li class="public ">
707
+ <span class="summary_signature">
708
+
709
+ <a href="#pause-class_method" title="pause (class method)">.<strong>pause</strong> &#x21d2; Object </a>
710
+
711
+
712
+
713
+ </span>
714
+
715
+
716
+
717
+
718
+
719
+
720
+
721
+
722
+
723
+ <span class="summary_desc"><div class='inline'>
724
+ <p>(DXOpal original) Pause &amp; resume.</p>
725
+ </div></span>
726
+
727
+ </li>
728
+
729
+
730
+ <li class="public ">
731
+ <span class="summary_signature">
732
+
733
+ <a href="#paused%3F-class_method" title="paused? (class method)">.<strong>paused?</strong> &#x21d2; Boolean </a>
734
+
735
+
736
+
737
+ </span>
738
+
739
+
740
+
741
+
742
+
743
+
744
+
745
+
746
+
747
+ <span class="summary_desc"><div class='inline'></div></span>
748
+
749
+ </li>
750
+
751
+
752
+ <li class="public ">
753
+ <span class="summary_signature">
754
+
755
+ <a href="#real_fps-class_method" title="real_fps (class method)">.<strong>real_fps</strong> &#x21d2; Object </a>
756
+
757
+
758
+
759
+ </span>
760
+
761
+
762
+
763
+
764
+
765
+
766
+
767
+
768
+
769
+ <span class="summary_desc"><div class='inline'></div></span>
770
+
771
+ </li>
772
+
773
+
774
+ <li class="public ">
775
+ <span class="summary_signature">
776
+
777
+ <a href="#resume-class_method" title="resume (class method)">.<strong>resume</strong> &#x21d2; Object </a>
778
+
779
+
780
+
781
+ </span>
782
+
783
+
784
+
785
+
786
+
787
+
788
+
789
+
790
+
791
+ <span class="summary_desc"><div class='inline'></div></span>
792
+
793
+ </li>
794
+
795
+
796
+ <li class="public ">
797
+ <span class="summary_signature">
798
+
799
+ <a href="#width-class_method" title="width (class method)">.<strong>width</strong> &#x21d2; Object </a>
800
+
801
+
802
+
803
+ </span>
804
+
805
+
806
+
807
+
808
+
809
+
810
+
811
+
812
+
813
+ <span class="summary_desc"><div class='inline'></div></span>
814
+
815
+ </li>
816
+
817
+
818
+ <li class="public ">
819
+ <span class="summary_signature">
820
+
821
+ <a href="#width=-class_method" title="width= (class method)">.<strong>width=</strong>(w) &#x21d2; Object </a>
822
+
823
+
824
+
825
+ </span>
826
+
827
+
828
+
829
+
830
+
831
+
832
+
833
+
834
+
835
+ <span class="summary_desc"><div class='inline'></div></span>
836
+
837
+ </li>
838
+
839
+
840
+ </ul>
841
+
842
+
843
+
844
+
845
+ <div id="class_method_details" class="method_details_list">
846
+ <h2>Class Method Details</h2>
847
+
848
+
849
+ <div class="method_details first">
850
+ <h3 class="signature first" id="_img-class_method">
851
+
852
+ .<strong>_img</strong> &#x21d2; <tt>Object</tt>
853
+
854
+
855
+
856
+
857
+
858
+ </h3><div class="docstring">
859
+ <div class="discussion">
860
+
861
+ <p>Return internal DXOpal::Image object (for experimental/hacking use)</p>
862
+
863
+
864
+ </div>
865
+ </div>
866
+ <div class="tags">
867
+
868
+
869
+ </div><table class="source_code">
870
+ <tr>
871
+ <td>
872
+ <pre class="lines">
873
+
874
+
875
+ 99</pre>
876
+ </td>
877
+ <td>
878
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 99</span>
879
+
880
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__img'>_img</span><span class='semicolon'>;</span> <span class='cvar'>@@img</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
881
+ </td>
882
+ </tr>
883
+ </table>
884
+ </div>
885
+
886
+ <div class="method_details ">
887
+ <h3 class="signature " id="_init-class_method">
888
+
889
+ .<strong>_init</strong>(w, h) &#x21d2; <tt>Object</tt>
890
+
891
+
892
+
893
+
894
+
895
+ </h3><table class="source_code">
896
+ <tr>
897
+ <td>
898
+ <pre class="lines">
899
+
900
+
901
+ 91
902
+ 92
903
+ 93
904
+ 94
905
+ 95
906
+ 96</pre>
907
+ </td>
908
+ <td>
909
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 91</span>
910
+
911
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__init'>_init</span><span class='lparen'>(</span><span class='id identifier rubyid_w'>w</span><span class='comma'>,</span> <span class='id identifier rubyid_h'>h</span><span class='rparen'>)</span>
912
+ <span class='id identifier rubyid_canvas'>canvas</span> <span class='op'>=</span> <span class='backtick'>`</span><span class='tstring_content'>document.getElementById(&quot;canvas&quot;)</span><span class='tstring_end'>`</span></span>
913
+ <span class='id identifier rubyid_img'>img</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Image.html" title="DXOpal::Image (class)">Image</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Image.html#initialize-instance_method" title="DXOpal::Image#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_w'>w</span><span class='comma'>,</span> <span class='id identifier rubyid_h'>h</span><span class='comma'>,</span> <span class='label'>canvas:</span> <span class='id identifier rubyid_canvas'>canvas</span><span class='rparen'>)</span>
914
+ <span class='const'><span class='object_link'><a href="Input.html" title="DXOpal::Input (module)">Input</a></span></span><span class='period'>.</span><span class='id identifier rubyid__init'><span class='object_link'><a href="Input.html#_init-class_method" title="DXOpal::Input._init (method)">_init</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_canvas'>canvas</span><span class='rparen'>)</span>
915
+ <span class='kw'>return</span> <span class='id identifier rubyid_img'>img</span>
916
+ <span class='kw'>end</span></pre>
917
+ </td>
918
+ </tr>
919
+ </table>
920
+ </div>
921
+
922
+ <div class="method_details ">
923
+ <h3 class="signature " id="_loop-class_method">
924
+
925
+ .<strong>_loop</strong>(time, &amp;block) &#x21d2; <tt>Object</tt>
926
+
927
+
928
+
929
+
930
+
931
+ </h3><table class="source_code">
932
+ <tr>
933
+ <td>
934
+ <pre class="lines">
935
+
936
+
937
+ 41
938
+ 42
939
+ 43
940
+ 44
941
+ 45
942
+ 46
943
+ 47
944
+ 48
945
+ 49
946
+ 50
947
+ 51
948
+ 52
949
+ 53
950
+ 54
951
+ 55
952
+ 56
953
+ 57
954
+ 58
955
+ 59
956
+ 60
957
+ 61
958
+ 62
959
+ 63
960
+ 64
961
+ 65
962
+ 66
963
+ 67
964
+ 68
965
+ 69
966
+ 70
967
+ 71
968
+ 72
969
+ 73
970
+ 74
971
+ 75
972
+ 76
973
+ 77
974
+ 78
975
+ 79
976
+ 80
977
+ 81
978
+ 82
979
+ 83
980
+ 84
981
+ 85
982
+ 86
983
+ 87
984
+ 88
985
+ 89</pre>
986
+ </td>
987
+ <td>
988
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 41</span>
989
+
990
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__loop'>_loop</span><span class='lparen'>(</span><span class='id identifier rubyid_time'>time</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
991
+ <span class='cvar'>@@img</span> <span class='op'>||=</span> <span class='id identifier rubyid__init'>_init</span><span class='lparen'>(</span><span class='cvar'>@@width</span><span class='comma'>,</span> <span class='cvar'>@@height</span><span class='rparen'>)</span>
992
+ <span class='id identifier rubyid_t0'>t0</span> <span class='op'>=</span> <span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span>
993
+
994
+ <span class='comment'># Calculate fps
995
+ </span> <span class='kw'>if</span> <span class='id identifier rubyid_t0'>t0</span> <span class='op'>-</span> <span class='cvar'>@@real_fps_t</span> <span class='op'>&gt;=</span> <span class='float'>1.0</span>
996
+ <span class='cvar'>@@real_fps</span> <span class='op'>=</span> <span class='cvar'>@@real_fps_ct</span>
997
+ <span class='cvar'>@@real_fps_ct</span> <span class='op'>=</span> <span class='int'>1</span>
998
+ <span class='cvar'>@@real_fps_t</span> <span class='op'>=</span> <span class='id identifier rubyid_t0'>t0</span>
999
+ <span class='kw'>else</span>
1000
+ <span class='cvar'>@@real_fps_ct</span> <span class='op'>+=</span> <span class='int'>1</span>
1001
+ <span class='kw'>end</span>
1002
+
1003
+ <span class='comment'># Update physics
1004
+ </span> <span class='const'><span class='object_link'><a href="Sprite.html" title="DXOpal::Sprite (class)">Sprite</a></span></span><span class='period'>.</span><span class='id identifier rubyid_matter_tick'>matter_tick</span><span class='lparen'>(</span><span class='id identifier rubyid_time'>time</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='const'><span class='object_link'><a href="Sprite.html" title="DXOpal::Sprite (class)">Sprite</a></span></span><span class='period'>.</span><span class='id identifier rubyid_matter_enabled?'>matter_enabled?</span>
1005
+
1006
+ <span class='comment'># Detect inputs
1007
+ </span> <span class='const'><span class='object_link'><a href="Input.html" title="DXOpal::Input (module)">Input</a></span></span><span class='period'>.</span><span class='id identifier rubyid__on_tick'><span class='object_link'><a href="Input.html#_on_tick-class_method" title="DXOpal::Input._on_tick (method)">_on_tick</a></span></span>
1008
+
1009
+ <span class='comment'># Call user code
1010
+ </span> <span class='cvar'>@@draw_queue</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
1011
+ <span class='kw'>if</span> <span class='cvar'>@@paused</span>
1012
+ <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_draw_pause_screen'><span class='object_link'><a href="#draw_pause_screen-class_method" title="DXOpal::Window.draw_pause_screen (method)">draw_pause_screen</a></span></span>
1013
+ <span class='kw'>else</span>
1014
+ <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span>
1015
+ <span class='kw'>end</span>
1016
+
1017
+ <span class='comment'># Draw
1018
+ </span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_box_fill'>box_fill</span><span class='lparen'>(</span><span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span><span class='comma'>,</span> <span class='cvar'>@@width</span><span class='comma'>,</span> <span class='cvar'>@@height</span><span class='comma'>,</span> <span class='cvar'>@@bgcolor</span><span class='rparen'>)</span>
1019
+ <span class='id identifier rubyid_sorted'>sorted</span> <span class='op'>=</span> <span class='cvar'>@@draw_queue</span><span class='period'>.</span><span class='id identifier rubyid_sort'>sort</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_a'>a</span><span class='comma'>,</span> <span class='id identifier rubyid_b'>b</span><span class='op'>|</span> <span class='id identifier rubyid_a'>a</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> <span class='op'>==</span> <span class='id identifier rubyid_b'>b</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> <span class='op'>?</span> <span class='id identifier rubyid_a'>a</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span> <span class='op'>&lt;=&gt;</span> <span class='id identifier rubyid_b'>b</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span> <span class='op'>:</span> <span class='id identifier rubyid_a'>a</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> <span class='op'>&lt;=&gt;</span> <span class='id identifier rubyid_a'>a</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span> <span class='rbrace'>}</span>
1020
+ <span class='id identifier rubyid_sorted'>sorted</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_item'>item</span><span class='op'>|</span>
1021
+ <span class='kw'>case</span> <span class='id identifier rubyid_item'>item</span><span class='lbracket'>[</span><span class='int'>2</span><span class='rbracket'>]</span>
1022
+ <span class='kw'>when</span> <span class='symbol'>:image</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_draw'>draw</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1023
+ <span class='kw'>when</span> <span class='symbol'>:image_rot</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_draw_rot'>draw_rot</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1024
+ <span class='kw'>when</span> <span class='symbol'>:draw_ex</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_draw_ex'>draw_ex</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1025
+ <span class='kw'>when</span> <span class='symbol'>:font</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_draw_font'>draw_font</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1026
+ <span class='kw'>when</span> <span class='symbol'>:pixel</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='op'>[]=</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1027
+ <span class='kw'>when</span> <span class='symbol'>:line</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_line'>line</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1028
+ <span class='kw'>when</span> <span class='symbol'>:box</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_box'>box</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1029
+ <span class='kw'>when</span> <span class='symbol'>:box_fill</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_box_fill'>box_fill</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1030
+ <span class='kw'>when</span> <span class='symbol'>:circle</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_circle'>circle</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1031
+ <span class='kw'>when</span> <span class='symbol'>:circle_fill</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_circle_fill'>circle_fill</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1032
+ <span class='kw'>when</span> <span class='symbol'>:triangle</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_triangle'>triangle</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1033
+ <span class='kw'>when</span> <span class='symbol'>:triangle_fill</span> <span class='kw'>then</span> <span class='cvar'>@@img</span><span class='period'>.</span><span class='id identifier rubyid_triangle_fill'>triangle_fill</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_item'>item</span><span class='period'>.</span><span class='id identifier rubyid_drop'>drop</span><span class='lparen'>(</span><span class='int'>3</span><span class='rparen'>)</span><span class='rparen'>)</span>
1034
+ <span class='kw'>end</span>
1035
+ <span class='kw'>end</span>
1036
+
1037
+ <span class='backtick'>`</span><span class='tstring_content'>window</span><span class='tstring_end'>`</span></span><span class='period'>.</span><span class='const'>JS</span><span class='period'>.</span><span class='id identifier rubyid_requestAnimationFrame'>requestAnimationFrame</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_time'>time</span><span class='op'>|</span> <span class='id identifier rubyid__loop'>_loop</span><span class='lparen'>(</span><span class='id identifier rubyid_time'>time</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
1038
+ <span class='kw'>end</span></pre>
1039
+ </td>
1040
+ </tr>
1041
+ </table>
1042
+ </div>
1043
+
1044
+ <div class="method_details ">
1045
+ <h3 class="signature " id="bgcolor-class_method">
1046
+
1047
+ .<strong>bgcolor</strong> &#x21d2; <tt>Object</tt>
1048
+
1049
+
1050
+
1051
+
1052
+
1053
+ </h3><table class="source_code">
1054
+ <tr>
1055
+ <td>
1056
+ <pre class="lines">
1057
+
1058
+
1059
+ 109</pre>
1060
+ </td>
1061
+ <td>
1062
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 109</span>
1063
+
1064
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_bgcolor'>bgcolor</span><span class='semicolon'>;</span> <span class='cvar'>@@bgcolor</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1065
+ </td>
1066
+ </tr>
1067
+ </table>
1068
+ </div>
1069
+
1070
+ <div class="method_details ">
1071
+ <h3 class="signature " id="bgcolor=-class_method">
1072
+
1073
+ .<strong>bgcolor=</strong>(col) &#x21d2; <tt>Object</tt>
1074
+
1075
+
1076
+
1077
+
1078
+
1079
+ </h3><table class="source_code">
1080
+ <tr>
1081
+ <td>
1082
+ <pre class="lines">
1083
+
1084
+
1085
+ 110</pre>
1086
+ </td>
1087
+ <td>
1088
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 110</span>
1089
+
1090
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_bgcolor='>bgcolor=</span><span class='lparen'>(</span><span class='id identifier rubyid_col'>col</span><span class='rparen'>)</span><span class='semicolon'>;</span> <span class='cvar'>@@bgcolor</span> <span class='op'>=</span> <span class='id identifier rubyid_col'>col</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1091
+ </td>
1092
+ </tr>
1093
+ </table>
1094
+ </div>
1095
+
1096
+ <div class="method_details ">
1097
+ <h3 class="signature " id="draw-class_method">
1098
+
1099
+ .<strong>draw</strong>(x, y, image, z = 0) &#x21d2; <tt>Object</tt>
1100
+
1101
+
1102
+
1103
+
1104
+
1105
+ </h3><table class="source_code">
1106
+ <tr>
1107
+ <td>
1108
+ <pre class="lines">
1109
+
1110
+
1111
+ 112
1112
+ 113
1113
+ 114</pre>
1114
+ </td>
1115
+ <td>
1116
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 112</span>
1117
+
1118
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw'>draw</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1119
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:image</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='rparen'>)</span>
1120
+ <span class='kw'>end</span></pre>
1121
+ </td>
1122
+ </tr>
1123
+ </table>
1124
+ </div>
1125
+
1126
+ <div class="method_details ">
1127
+ <h3 class="signature " id="draw_box-class_method">
1128
+
1129
+ .<strong>draw_box</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; <tt>Object</tt>
1130
+
1131
+
1132
+
1133
+
1134
+
1135
+ </h3><table class="source_code">
1136
+ <tr>
1137
+ <td>
1138
+ <pre class="lines">
1139
+
1140
+
1141
+ 138
1142
+ 139
1143
+ 140</pre>
1144
+ </td>
1145
+ <td>
1146
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 138</span>
1147
+
1148
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_box'>draw_box</span><span class='lparen'>(</span><span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1149
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:box</span><span class='comma'>,</span> <span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1150
+ <span class='kw'>end</span></pre>
1151
+ </td>
1152
+ </tr>
1153
+ </table>
1154
+ </div>
1155
+
1156
+ <div class="method_details ">
1157
+ <h3 class="signature " id="draw_box_fill-class_method">
1158
+
1159
+ .<strong>draw_box_fill</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; <tt>Object</tt>
1160
+
1161
+
1162
+
1163
+
1164
+
1165
+ </h3><table class="source_code">
1166
+ <tr>
1167
+ <td>
1168
+ <pre class="lines">
1169
+
1170
+
1171
+ 142
1172
+ 143
1173
+ 144</pre>
1174
+ </td>
1175
+ <td>
1176
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 142</span>
1177
+
1178
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_box_fill'>draw_box_fill</span><span class='lparen'>(</span><span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1179
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:box_fill</span><span class='comma'>,</span> <span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1180
+ <span class='kw'>end</span></pre>
1181
+ </td>
1182
+ </tr>
1183
+ </table>
1184
+ </div>
1185
+
1186
+ <div class="method_details ">
1187
+ <h3 class="signature " id="draw_circle-class_method">
1188
+
1189
+ .<strong>draw_circle</strong>(x, y, r, color, z = 0) &#x21d2; <tt>Object</tt>
1190
+
1191
+
1192
+
1193
+
1194
+
1195
+ </h3><table class="source_code">
1196
+ <tr>
1197
+ <td>
1198
+ <pre class="lines">
1199
+
1200
+
1201
+ 146
1202
+ 147
1203
+ 148</pre>
1204
+ </td>
1205
+ <td>
1206
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 146</span>
1207
+
1208
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_circle'>draw_circle</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_r'>r</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1209
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:circle</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_r'>r</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1210
+ <span class='kw'>end</span></pre>
1211
+ </td>
1212
+ </tr>
1213
+ </table>
1214
+ </div>
1215
+
1216
+ <div class="method_details ">
1217
+ <h3 class="signature " id="draw_circle_fill-class_method">
1218
+
1219
+ .<strong>draw_circle_fill</strong>(x, y, r, color, z = 0) &#x21d2; <tt>Object</tt>
1220
+
1221
+
1222
+
1223
+
1224
+
1225
+ </h3><table class="source_code">
1226
+ <tr>
1227
+ <td>
1228
+ <pre class="lines">
1229
+
1230
+
1231
+ 150
1232
+ 151
1233
+ 152</pre>
1234
+ </td>
1235
+ <td>
1236
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 150</span>
1237
+
1238
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_circle_fill'>draw_circle_fill</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_r'>r</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1239
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:circle_fill</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_r'>r</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1240
+ <span class='kw'>end</span></pre>
1241
+ </td>
1242
+ </tr>
1243
+ </table>
1244
+ </div>
1245
+
1246
+ <div class="method_details ">
1247
+ <h3 class="signature " id="draw_ex-class_method">
1248
+
1249
+ .<strong>draw_ex</strong>(x, y, image, options = {}) &#x21d2; <tt>Object</tt>
1250
+
1251
+
1252
+
1253
+
1254
+
1255
+ </h3><table class="source_code">
1256
+ <tr>
1257
+ <td>
1258
+ <pre class="lines">
1259
+
1260
+
1261
+ 120
1262
+ 121
1263
+ 122</pre>
1264
+ </td>
1265
+ <td>
1266
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 120</span>
1267
+
1268
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_ex'>draw_ex</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1269
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:z</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>0</span><span class='comma'>,</span> <span class='symbol'>:draw_ex</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
1270
+ <span class='kw'>end</span></pre>
1271
+ </td>
1272
+ </tr>
1273
+ </table>
1274
+ </div>
1275
+
1276
+ <div class="method_details ">
1277
+ <h3 class="signature " id="draw_font-class_method">
1278
+
1279
+ .<strong>draw_font</strong>(x, y, string, font, option = {}) &#x21d2; <tt>Object</tt>
1280
+
1281
+
1282
+
1283
+
1284
+
1285
+ </h3><table class="source_code">
1286
+ <tr>
1287
+ <td>
1288
+ <pre class="lines">
1289
+
1290
+
1291
+ 124
1292
+ 125
1293
+ 126
1294
+ 127
1295
+ 128</pre>
1296
+ </td>
1297
+ <td>
1298
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 124</span>
1299
+
1300
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_font'>draw_font</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_string'>string</span><span class='comma'>,</span> <span class='id identifier rubyid_font'>font</span><span class='comma'>,</span> <span class='id identifier rubyid_option'>option</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
1301
+ <span class='id identifier rubyid_z'>z</span> <span class='op'>=</span> <span class='id identifier rubyid_option'>option</span><span class='lbracket'>[</span><span class='symbol'>:z</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>0</span>
1302
+ <span class='id identifier rubyid_color'>color</span> <span class='op'>=</span> <span class='id identifier rubyid_option'>option</span><span class='lbracket'>[</span><span class='symbol'>:color</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='lbracket'>[</span><span class='int'>255</span><span class='comma'>,</span> <span class='int'>255</span><span class='comma'>,</span> <span class='int'>255</span><span class='rbracket'>]</span>
1303
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:font</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_string'>string</span><span class='comma'>,</span> <span class='id identifier rubyid_font'>font</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1304
+ <span class='kw'>end</span></pre>
1305
+ </td>
1306
+ </tr>
1307
+ </table>
1308
+ </div>
1309
+
1310
+ <div class="method_details ">
1311
+ <h3 class="signature " id="draw_line-class_method">
1312
+
1313
+ .<strong>draw_line</strong>(x1, y1, x2, y2, color, z = 0) &#x21d2; <tt>Object</tt>
1314
+
1315
+
1316
+
1317
+
1318
+
1319
+ </h3><table class="source_code">
1320
+ <tr>
1321
+ <td>
1322
+ <pre class="lines">
1323
+
1324
+
1325
+ 134
1326
+ 135
1327
+ 136</pre>
1328
+ </td>
1329
+ <td>
1330
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 134</span>
1331
+
1332
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_line'>draw_line</span><span class='lparen'>(</span><span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1333
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:line</span><span class='comma'>,</span> <span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1334
+ <span class='kw'>end</span></pre>
1335
+ </td>
1336
+ </tr>
1337
+ </table>
1338
+ </div>
1339
+
1340
+ <div class="method_details ">
1341
+ <h3 class="signature " id="draw_pause_screen-class_method">
1342
+
1343
+ .<strong>draw_pause_screen</strong> &#x21d2; <tt>Object</tt>
1344
+
1345
+
1346
+
1347
+
1348
+
1349
+ </h3><table class="source_code">
1350
+ <tr>
1351
+ <td>
1352
+ <pre class="lines">
1353
+
1354
+
1355
+ 36
1356
+ 37
1357
+ 38
1358
+ 39</pre>
1359
+ </td>
1360
+ <td>
1361
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 36</span>
1362
+
1363
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_pause_screen'>draw_pause_screen</span>
1364
+ <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_draw_box_fill'><span class='object_link'><a href="#draw_box_fill-class_method" title="DXOpal::Window.draw_box_fill (method)">draw_box_fill</a></span></span><span class='lparen'>(</span><span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span><span class='comma'>,</span> <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_width'><span class='object_link'><a href="#width-class_method" title="DXOpal::Window.width (method)">width</a></span></span><span class='comma'>,</span> <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_height'><span class='object_link'><a href="#height-class_method" title="DXOpal::Window.height (method)">height</a></span></span><span class='comma'>,</span> <span class='const'>C_BLACK</span><span class='rparen'>)</span>
1365
+ <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_draw_font'><span class='object_link'><a href="#draw_font-class_method" title="DXOpal::Window.draw_font (method)">draw_font</a></span></span><span class='lparen'>(</span><span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>...PAUSE...</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='const'><span class='object_link'><a href="Font.html" title="DXOpal::Font (class)">Font</a></span></span><span class='period'>.</span><span class='id identifier rubyid_default'><span class='object_link'><a href="Font.html#default-class_method" title="DXOpal::Font.default (method)">default</a></span></span><span class='comma'>,</span> <span class='label'>color:</span> <span class='const'>C_WHITE</span><span class='rparen'>)</span>
1366
+ <span class='kw'>end</span></pre>
1367
+ </td>
1368
+ </tr>
1369
+ </table>
1370
+ </div>
1371
+
1372
+ <div class="method_details ">
1373
+ <h3 class="signature " id="draw_pixel-class_method">
1374
+
1375
+ .<strong>draw_pixel</strong>(x, y, color, z = 0) &#x21d2; <tt>Object</tt>
1376
+
1377
+
1378
+
1379
+
1380
+
1381
+ </h3><table class="source_code">
1382
+ <tr>
1383
+ <td>
1384
+ <pre class="lines">
1385
+
1386
+
1387
+ 130
1388
+ 131
1389
+ 132</pre>
1390
+ </td>
1391
+ <td>
1392
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 130</span>
1393
+
1394
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_pixel'>draw_pixel</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1395
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:pixel</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1396
+ <span class='kw'>end</span></pre>
1397
+ </td>
1398
+ </tr>
1399
+ </table>
1400
+ </div>
1401
+
1402
+ <div class="method_details ">
1403
+ <h3 class="signature " id="draw_rot-class_method">
1404
+
1405
+ .<strong>draw_rot</strong>(x, y, image, angle, center_x = nil, center_y = nil, z = 0) &#x21d2; <tt>Object</tt>
1406
+
1407
+
1408
+
1409
+
1410
+
1411
+ </h3><table class="source_code">
1412
+ <tr>
1413
+ <td>
1414
+ <pre class="lines">
1415
+
1416
+
1417
+ 116
1418
+ 117
1419
+ 118</pre>
1420
+ </td>
1421
+ <td>
1422
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 116</span>
1423
+
1424
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_rot'>draw_rot</span><span class='lparen'>(</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='comma'>,</span> <span class='id identifier rubyid_angle'>angle</span><span class='comma'>,</span> <span class='id identifier rubyid_center_x'>center_x</span><span class='op'>=</span><span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_center_y'>center_y</span><span class='op'>=</span><span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1425
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:image_rot</span><span class='comma'>,</span> <span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='id identifier rubyid_image'>image</span><span class='comma'>,</span> <span class='id identifier rubyid_angle'>angle</span><span class='comma'>,</span> <span class='id identifier rubyid_center_x'>center_x</span><span class='comma'>,</span> <span class='id identifier rubyid_center_y'>center_y</span><span class='rparen'>)</span>
1426
+ <span class='kw'>end</span></pre>
1427
+ </td>
1428
+ </tr>
1429
+ </table>
1430
+ </div>
1431
+
1432
+ <div class="method_details ">
1433
+ <h3 class="signature " id="draw_triangle-class_method">
1434
+
1435
+ .<strong>draw_triangle</strong>(x1, y1, x2, y2, x3, y3, color, z = 0) &#x21d2; <tt>Object</tt>
1436
+
1437
+
1438
+
1439
+
1440
+
1441
+ </h3><table class="source_code">
1442
+ <tr>
1443
+ <td>
1444
+ <pre class="lines">
1445
+
1446
+
1447
+ 154
1448
+ 155
1449
+ 156</pre>
1450
+ </td>
1451
+ <td>
1452
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 154</span>
1453
+
1454
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_triangle'>draw_triangle</span><span class='lparen'>(</span><span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_x3'>x3</span><span class='comma'>,</span> <span class='id identifier rubyid_y3'>y3</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1455
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:triangle</span><span class='comma'>,</span> <span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_x3'>x3</span><span class='comma'>,</span> <span class='id identifier rubyid_y3'>y3</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1456
+ <span class='kw'>end</span></pre>
1457
+ </td>
1458
+ </tr>
1459
+ </table>
1460
+ </div>
1461
+
1462
+ <div class="method_details ">
1463
+ <h3 class="signature " id="draw_triangle_fill-class_method">
1464
+
1465
+ .<strong>draw_triangle_fill</strong>(x1, y1, x2, y2, x3, y3, color, z = 0) &#x21d2; <tt>Object</tt>
1466
+
1467
+
1468
+
1469
+
1470
+
1471
+ </h3><table class="source_code">
1472
+ <tr>
1473
+ <td>
1474
+ <pre class="lines">
1475
+
1476
+
1477
+ 158
1478
+ 159
1479
+ 160</pre>
1480
+ </td>
1481
+ <td>
1482
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 158</span>
1483
+
1484
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_draw_triangle_fill'>draw_triangle_fill</span><span class='lparen'>(</span><span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_x3'>x3</span><span class='comma'>,</span> <span class='id identifier rubyid_y3'>y3</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='comma'>,</span> <span class='id identifier rubyid_z'>z</span><span class='op'>=</span><span class='int'>0</span><span class='rparen'>)</span>
1485
+ <span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='symbol'>:triangle_fill</span><span class='comma'>,</span> <span class='id identifier rubyid_x1'>x1</span><span class='comma'>,</span> <span class='id identifier rubyid_y1'>y1</span><span class='comma'>,</span> <span class='id identifier rubyid_x2'>x2</span><span class='comma'>,</span> <span class='id identifier rubyid_y2'>y2</span><span class='comma'>,</span> <span class='id identifier rubyid_x3'>x3</span><span class='comma'>,</span> <span class='id identifier rubyid_y3'>y3</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1486
+ <span class='kw'>end</span></pre>
1487
+ </td>
1488
+ </tr>
1489
+ </table>
1490
+ </div>
1491
+
1492
+ <div class="method_details ">
1493
+ <h3 class="signature " id="enqueue_draw-class_method">
1494
+
1495
+ .<strong>enqueue_draw</strong>(z, *args) &#x21d2; <tt>Object</tt>
1496
+
1497
+
1498
+
1499
+
1500
+
1501
+ </h3><table class="source_code">
1502
+ <tr>
1503
+ <td>
1504
+ <pre class="lines">
1505
+
1506
+
1507
+ 162
1508
+ 163
1509
+ 164</pre>
1510
+ </td>
1511
+ <td>
1512
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 162</span>
1513
+
1514
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_enqueue_draw'>enqueue_draw</span><span class='lparen'>(</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
1515
+ <span class='cvar'>@@draw_queue</span><span class='period'>.</span><span class='id identifier rubyid_push'>push</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='id identifier rubyid_z'>z</span><span class='comma'>,</span> <span class='cvar'>@@draw_queue</span><span class='period'>.</span><span class='id identifier rubyid_length'>length</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1516
+ <span class='kw'>end</span></pre>
1517
+ </td>
1518
+ </tr>
1519
+ </table>
1520
+ </div>
1521
+
1522
+ <div class="method_details ">
1523
+ <h3 class="signature " id="fps-class_method">
1524
+
1525
+ .<strong>fps</strong> &#x21d2; <tt>Object</tt>
1526
+
1527
+
1528
+
1529
+
1530
+
1531
+ </h3><table class="source_code">
1532
+ <tr>
1533
+ <td>
1534
+ <pre class="lines">
1535
+
1536
+
1537
+ 101</pre>
1538
+ </td>
1539
+ <td>
1540
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 101</span>
1541
+
1542
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_fps'>fps</span><span class='semicolon'>;</span> <span class='cvar'>@@fps</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1543
+ </td>
1544
+ </tr>
1545
+ </table>
1546
+ </div>
1547
+
1548
+ <div class="method_details ">
1549
+ <h3 class="signature " id="fps=-class_method">
1550
+
1551
+ .<strong>fps=</strong>(w) &#x21d2; <tt>Object</tt>
1552
+
1553
+
1554
+
1555
+
1556
+
1557
+ </h3><table class="source_code">
1558
+ <tr>
1559
+ <td>
1560
+ <pre class="lines">
1561
+
1562
+
1563
+ 102</pre>
1564
+ </td>
1565
+ <td>
1566
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 102</span>
1567
+
1568
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_fps='>fps=</span><span class='lparen'>(</span><span class='id identifier rubyid_w'>w</span><span class='rparen'>)</span><span class='semicolon'>;</span> <span class='cvar'>@@fps</span> <span class='op'>=</span> <span class='id identifier rubyid_w'>w</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1569
+ </td>
1570
+ </tr>
1571
+ </table>
1572
+ </div>
1573
+
1574
+ <div class="method_details ">
1575
+ <h3 class="signature " id="height-class_method">
1576
+
1577
+ .<strong>height</strong> &#x21d2; <tt>Object</tt>
1578
+
1579
+
1580
+
1581
+
1582
+
1583
+ </h3><table class="source_code">
1584
+ <tr>
1585
+ <td>
1586
+ <pre class="lines">
1587
+
1588
+
1589
+ 106</pre>
1590
+ </td>
1591
+ <td>
1592
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 106</span>
1593
+
1594
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_height'>height</span><span class='semicolon'>;</span> <span class='cvar'>@@height</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1595
+ </td>
1596
+ </tr>
1597
+ </table>
1598
+ </div>
1599
+
1600
+ <div class="method_details ">
1601
+ <h3 class="signature " id="height=-class_method">
1602
+
1603
+ .<strong>height=</strong>(h) &#x21d2; <tt>Object</tt>
1604
+
1605
+
1606
+
1607
+
1608
+
1609
+ </h3><table class="source_code">
1610
+ <tr>
1611
+ <td>
1612
+ <pre class="lines">
1613
+
1614
+
1615
+ 107</pre>
1616
+ </td>
1617
+ <td>
1618
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 107</span>
1619
+
1620
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_height='>height=</span><span class='lparen'>(</span><span class='id identifier rubyid_h'>h</span><span class='rparen'>)</span><span class='semicolon'>;</span> <span class='cvar'>@@height</span> <span class='op'>=</span> <span class='id identifier rubyid_h'>h</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1621
+ </td>
1622
+ </tr>
1623
+ </table>
1624
+ </div>
1625
+
1626
+ <div class="method_details ">
1627
+ <h3 class="signature " id="load_resources-class_method">
1628
+
1629
+ .<strong>load_resources</strong>(&amp;block) &#x21d2; <tt>Object</tt>
1630
+
1631
+
1632
+
1633
+
1634
+
1635
+ </h3><div class="docstring">
1636
+ <div class="discussion">
1637
+
1638
+ <p>Load resources specified with Image.register or Sound.register Call block
1639
+ when loaded</p>
1640
+
1641
+
1642
+ </div>
1643
+ </div>
1644
+ <div class="tags">
1645
+
1646
+
1647
+ </div><table class="source_code">
1648
+ <tr>
1649
+ <td>
1650
+ <pre class="lines">
1651
+
1652
+
1653
+ 16
1654
+ 17
1655
+ 18</pre>
1656
+ </td>
1657
+ <td>
1658
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 16</span>
1659
+
1660
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_load_resources'>load_resources</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1661
+ <span class='const'><span class='object_link'><a href="RemoteResource.html" title="DXOpal::RemoteResource (class)">RemoteResource</a></span></span><span class='period'>.</span><span class='id identifier rubyid__load_resources'><span class='object_link'><a href="RemoteResource.html#_load_resources-class_method" title="DXOpal::RemoteResource._load_resources (method)">_load_resources</a></span></span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1662
+ <span class='kw'>end</span></pre>
1663
+ </td>
1664
+ </tr>
1665
+ </table>
1666
+ </div>
1667
+
1668
+ <div class="method_details ">
1669
+ <h3 class="signature " id="loop-class_method">
1670
+
1671
+ .<strong>loop</strong>(&amp;block) &#x21d2; <tt>Object</tt>
1672
+
1673
+
1674
+
1675
+
1676
+
1677
+ </h3><table class="source_code">
1678
+ <tr>
1679
+ <td>
1680
+ <pre class="lines">
1681
+
1682
+
1683
+ 20
1684
+ 21
1685
+ 22
1686
+ 23</pre>
1687
+ </td>
1688
+ <td>
1689
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 20</span>
1690
+
1691
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_loop'>loop</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
1692
+ <span class='cvar'>@@block</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
1693
+ <span class='backtick'>`</span><span class='tstring_content'>window</span><span class='tstring_end'>`</span></span><span class='period'>.</span><span class='const'>JS</span><span class='period'>.</span><span class='id identifier rubyid_requestAnimationFrame'>requestAnimationFrame</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_time'>time</span><span class='op'>|</span> <span class='id identifier rubyid__loop'>_loop</span><span class='lparen'>(</span><span class='id identifier rubyid_time'>time</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
1694
+ <span class='kw'>end</span></pre>
1695
+ </td>
1696
+ </tr>
1697
+ </table>
1698
+ </div>
1699
+
1700
+ <div class="method_details ">
1701
+ <h3 class="signature " id="pause-class_method">
1702
+
1703
+ .<strong>pause</strong> &#x21d2; <tt>Object</tt>
1704
+
1705
+
1706
+
1707
+
1708
+
1709
+ </h3><div class="docstring">
1710
+ <div class="discussion">
1711
+
1712
+ <p>(DXOpal original) Pause &amp; resume</p>
1713
+
1714
+
1715
+ </div>
1716
+ </div>
1717
+ <div class="tags">
1718
+
1719
+
1720
+ </div><table class="source_code">
1721
+ <tr>
1722
+ <td>
1723
+ <pre class="lines">
1724
+
1725
+
1726
+ 26
1727
+ 27
1728
+ 28
1729
+ 29
1730
+ 30</pre>
1731
+ </td>
1732
+ <td>
1733
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 26</span>
1734
+
1735
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_pause'>pause</span>
1736
+ <span class='cvar'>@@paused</span> <span class='op'>=</span> <span class='kw'>true</span>
1737
+ <span class='cvar'>@@draw_queue</span><span class='period'>.</span><span class='id identifier rubyid_clear'>clear</span>
1738
+ <span class='id identifier rubyid_draw_pause_screen'>draw_pause_screen</span>
1739
+ <span class='kw'>end</span></pre>
1740
+ </td>
1741
+ </tr>
1742
+ </table>
1743
+ </div>
1744
+
1745
+ <div class="method_details ">
1746
+ <h3 class="signature " id="paused?-class_method">
1747
+
1748
+ .<strong>paused?</strong> &#x21d2; <tt>Boolean</tt>
1749
+
1750
+
1751
+
1752
+
1753
+
1754
+ </h3><div class="docstring">
1755
+ <div class="discussion">
1756
+
1757
+
1758
+ </div>
1759
+ </div>
1760
+ <div class="tags">
1761
+
1762
+ <p class="tag_title">Returns:</p>
1763
+ <ul class="return">
1764
+
1765
+ <li>
1766
+
1767
+
1768
+ <span class='type'>(<tt>Boolean</tt>)</span>
1769
+
1770
+
1771
+
1772
+ </li>
1773
+
1774
+ </ul>
1775
+
1776
+ </div><table class="source_code">
1777
+ <tr>
1778
+ <td>
1779
+ <pre class="lines">
1780
+
1781
+
1782
+ 31</pre>
1783
+ </td>
1784
+ <td>
1785
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 31</span>
1786
+
1787
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_paused?'>paused?</span><span class='semicolon'>;</span> <span class='cvar'>@@paused</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1788
+ </td>
1789
+ </tr>
1790
+ </table>
1791
+ </div>
1792
+
1793
+ <div class="method_details ">
1794
+ <h3 class="signature " id="real_fps-class_method">
1795
+
1796
+ .<strong>real_fps</strong> &#x21d2; <tt>Object</tt>
1797
+
1798
+
1799
+
1800
+
1801
+
1802
+ </h3><table class="source_code">
1803
+ <tr>
1804
+ <td>
1805
+ <pre class="lines">
1806
+
1807
+
1808
+ 103</pre>
1809
+ </td>
1810
+ <td>
1811
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 103</span>
1812
+
1813
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_real_fps'>real_fps</span><span class='semicolon'>;</span> <span class='cvar'>@@real_fps</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1814
+ </td>
1815
+ </tr>
1816
+ </table>
1817
+ </div>
1818
+
1819
+ <div class="method_details ">
1820
+ <h3 class="signature " id="resume-class_method">
1821
+
1822
+ .<strong>resume</strong> &#x21d2; <tt>Object</tt>
1823
+
1824
+
1825
+
1826
+
1827
+
1828
+ </h3><table class="source_code">
1829
+ <tr>
1830
+ <td>
1831
+ <pre class="lines">
1832
+
1833
+
1834
+ 32
1835
+ 33
1836
+ 34
1837
+ 35</pre>
1838
+ </td>
1839
+ <td>
1840
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 32</span>
1841
+
1842
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_resume'>resume</span>
1843
+ <span class='id identifier rubyid_raise'>raise</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>Window.resume is called before Window.loop</span><span class='tstring_end'>&quot;</span></span> <span class='kw'>if</span> <span class='cvar'>@@block</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
1844
+ <span class='cvar'>@@paused</span> <span class='op'>=</span> <span class='kw'>false</span><span class='semicolon'>;</span> <span class='const'><span class='object_link'><a href="" title="DXOpal::Window (module)">Window</a></span></span><span class='period'>.</span><span class='id identifier rubyid_loop'><span class='object_link'><a href="#loop-class_method" title="DXOpal::Window.loop (method)">loop</a></span></span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='cvar'>@@block</span><span class='rparen'>)</span>
1845
+ <span class='kw'>end</span></pre>
1846
+ </td>
1847
+ </tr>
1848
+ </table>
1849
+ </div>
1850
+
1851
+ <div class="method_details ">
1852
+ <h3 class="signature " id="width-class_method">
1853
+
1854
+ .<strong>width</strong> &#x21d2; <tt>Object</tt>
1855
+
1856
+
1857
+
1858
+
1859
+
1860
+ </h3><table class="source_code">
1861
+ <tr>
1862
+ <td>
1863
+ <pre class="lines">
1864
+
1865
+
1866
+ 104</pre>
1867
+ </td>
1868
+ <td>
1869
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 104</span>
1870
+
1871
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_width'>width</span><span class='semicolon'>;</span> <span class='cvar'>@@width</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1872
+ </td>
1873
+ </tr>
1874
+ </table>
1875
+ </div>
1876
+
1877
+ <div class="method_details ">
1878
+ <h3 class="signature " id="width=-class_method">
1879
+
1880
+ .<strong>width=</strong>(w) &#x21d2; <tt>Object</tt>
1881
+
1882
+
1883
+
1884
+
1885
+
1886
+ </h3><table class="source_code">
1887
+ <tr>
1888
+ <td>
1889
+ <pre class="lines">
1890
+
1891
+
1892
+ 105</pre>
1893
+ </td>
1894
+ <td>
1895
+ <pre class="code"><span class="info file"># File 'opal/dxopal/window.rb', line 105</span>
1896
+
1897
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_width='>width=</span><span class='lparen'>(</span><span class='id identifier rubyid_w'>w</span><span class='rparen'>)</span><span class='semicolon'>;</span> <span class='cvar'>@@width</span> <span class='op'>=</span> <span class='id identifier rubyid_w'>w</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1898
+ </td>
1899
+ </tr>
1900
+ </table>
1901
+ </div>
1902
+
1903
+ </div>
1904
+
1905
+ </div>
1906
+
1907
+ <div id="footer">
1908
+ Generated on Tue Oct 17 13:56:27 2017 by
1909
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1910
+ 0.9.9 (ruby-2.4.2).
1911
+ </div>
1912
+
1913
+ </div>
1914
+ </body>
1915
+ </html>