kumiki 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +256 -0
  4. data/lib/kumiki/animation/animated_state.rb +83 -0
  5. data/lib/kumiki/animation/easing.rb +62 -0
  6. data/lib/kumiki/animation/value_tween.rb +69 -0
  7. data/lib/kumiki/app.rb +381 -0
  8. data/lib/kumiki/box.rb +40 -0
  9. data/lib/kumiki/chart/area_chart.rb +308 -0
  10. data/lib/kumiki/chart/bar_chart.rb +291 -0
  11. data/lib/kumiki/chart/base_chart.rb +213 -0
  12. data/lib/kumiki/chart/chart_helpers.rb +74 -0
  13. data/lib/kumiki/chart/gauge_chart.rb +174 -0
  14. data/lib/kumiki/chart/heatmap_chart.rb +223 -0
  15. data/lib/kumiki/chart/line_chart.rb +292 -0
  16. data/lib/kumiki/chart/pie_chart.rb +222 -0
  17. data/lib/kumiki/chart/scales.rb +79 -0
  18. data/lib/kumiki/chart/scatter_chart.rb +306 -0
  19. data/lib/kumiki/chart/stacked_bar_chart.rb +279 -0
  20. data/lib/kumiki/column.rb +351 -0
  21. data/lib/kumiki/core.rb +2511 -0
  22. data/lib/kumiki/dsl.rb +408 -0
  23. data/lib/kumiki/frame_ranma.rb +570 -0
  24. data/lib/kumiki/markdown/ast.rb +127 -0
  25. data/lib/kumiki/markdown/mermaid/layout.rb +389 -0
  26. data/lib/kumiki/markdown/mermaid/models.rb +235 -0
  27. data/lib/kumiki/markdown/mermaid/parser.rb +522 -0
  28. data/lib/kumiki/markdown/mermaid/renderer.rb +339 -0
  29. data/lib/kumiki/markdown/parser.rb +808 -0
  30. data/lib/kumiki/markdown/renderer.rb +642 -0
  31. data/lib/kumiki/markdown/theme.rb +168 -0
  32. data/lib/kumiki/render_node.rb +262 -0
  33. data/lib/kumiki/row.rb +288 -0
  34. data/lib/kumiki/spacer.rb +20 -0
  35. data/lib/kumiki/style.rb +799 -0
  36. data/lib/kumiki/theme.rb +567 -0
  37. data/lib/kumiki/themes/material.rb +40 -0
  38. data/lib/kumiki/themes/tokyo_night.rb +11 -0
  39. data/lib/kumiki/version.rb +5 -0
  40. data/lib/kumiki/widgets/button.rb +105 -0
  41. data/lib/kumiki/widgets/calendar.rb +1028 -0
  42. data/lib/kumiki/widgets/checkbox.rb +119 -0
  43. data/lib/kumiki/widgets/container.rb +111 -0
  44. data/lib/kumiki/widgets/data_table.rb +670 -0
  45. data/lib/kumiki/widgets/divider.rb +31 -0
  46. data/lib/kumiki/widgets/image.rb +105 -0
  47. data/lib/kumiki/widgets/input.rb +485 -0
  48. data/lib/kumiki/widgets/markdown.rb +58 -0
  49. data/lib/kumiki/widgets/modal.rb +165 -0
  50. data/lib/kumiki/widgets/multiline_input.rb +970 -0
  51. data/lib/kumiki/widgets/multiline_text.rb +180 -0
  52. data/lib/kumiki/widgets/net_image.rb +100 -0
  53. data/lib/kumiki/widgets/progress_bar.rb +72 -0
  54. data/lib/kumiki/widgets/radio_buttons.rb +93 -0
  55. data/lib/kumiki/widgets/slider.rb +135 -0
  56. data/lib/kumiki/widgets/switch.rb +84 -0
  57. data/lib/kumiki/widgets/tabs.rb +175 -0
  58. data/lib/kumiki/widgets/text.rb +120 -0
  59. data/lib/kumiki/widgets/tree.rb +434 -0
  60. data/lib/kumiki/widgets/webview.rb +87 -0
  61. data/lib/kumiki.rb +130 -0
  62. metadata +113 -0
@@ -0,0 +1,799 @@
1
+ module Kumiki
2
+ # rbs_inline: enabled
3
+
4
+ # Style - composable widget style (CSS-inspired)
5
+ #
6
+ # Collects layout, visual, and typography properties and applies them to widgets.
7
+ # Each setter returns self for chaining.
8
+ # Compose via .then(other) or + to merge two Styles.
9
+ #
10
+ # Usage (with DSL s() helper):
11
+ # s.spacing(8).scrollable
12
+ # s.font_size(24).color(0xFFC0CAF5).bold
13
+ # style_a + style_b
14
+ #
15
+ class Style
16
+ def initialize
17
+ # Layout (Widget common)
18
+ @has_fixed_width = false
19
+ @fixed_width_val = 0
20
+ @has_fixed_height = false
21
+ @fixed_height_val = 0
22
+ @fit_content_val = false
23
+ @has_flex = false
24
+ @flex_val = 1
25
+ @has_padding = false
26
+ @pad_top = 0
27
+ @pad_right = 0
28
+ @pad_bottom = 0
29
+ @pad_left = 0
30
+ # Container (Column/Row)
31
+ @has_spacing = false
32
+ @spacing_val = 0
33
+ @scrollable_val = false
34
+ @pin_bottom_val = false
35
+ @pin_end_val = false
36
+ # Container wrapper (Container widget)
37
+ @has_bg_color = false
38
+ @bg_color_val = 0
39
+ @has_border_color = false
40
+ @border_color_val = 0
41
+ @has_border_radius = false
42
+ @border_radius_val = 0
43
+ # Text properties
44
+ @has_font_size = false
45
+ @font_size_val = 0
46
+ # Expanding policy
47
+ @has_expanding = false
48
+ @expanding_width_val = false
49
+ @expanding_height_val = false
50
+ # Typography (text visual)
51
+ @has_color = false
52
+ @color_val = 0
53
+ @has_text_color = false
54
+ @text_color_val = 0
55
+ @bold_val = false
56
+ @italic_val = false
57
+ @has_align = false
58
+ @align_val = 0
59
+ @has_font_family = false
60
+ @font_family_val = "default"
61
+ @has_kind = false
62
+ @kind_val = 0
63
+ end
64
+
65
+ # --- Class methods: create new Style with one property set ---
66
+
67
+ #: (Float w) -> Style
68
+ def self.fixed_width(w)
69
+ Style.new.fixed_width(w)
70
+ end
71
+
72
+ #: (Float w) -> Style
73
+ def self.width(w)
74
+ Style.new.fixed_width(w)
75
+ end
76
+
77
+ #: (Float h) -> Style
78
+ def self.fixed_height(h)
79
+ Style.new.fixed_height(h)
80
+ end
81
+
82
+ #: (Float h) -> Style
83
+ def self.height(h)
84
+ Style.new.fixed_height(h)
85
+ end
86
+
87
+ #: (Float w, Float h) -> Style
88
+ def self.size(w, h)
89
+ Style.new.size(w, h)
90
+ end
91
+
92
+ #: () -> Style
93
+ def self.fit_content
94
+ Style.new.fit_content
95
+ end
96
+
97
+ #: (Integer f) -> Style
98
+ def self.flex(f)
99
+ Style.new.flex(f)
100
+ end
101
+
102
+ #: (Float v) -> Style
103
+ def self.padding(v)
104
+ Style.new.padding(v)
105
+ end
106
+
107
+ #: (Float v) -> Style
108
+ def self.spacing(v)
109
+ Style.new.spacing(v)
110
+ end
111
+
112
+ #: () -> Style
113
+ def self.scrollable
114
+ Style.new.scrollable
115
+ end
116
+
117
+ #: () -> Style
118
+ def self.pin_to_bottom
119
+ Style.new.pin_to_bottom
120
+ end
121
+
122
+ #: () -> Style
123
+ def self.pin_to_end
124
+ Style.new.pin_to_end
125
+ end
126
+
127
+ #: (Integer c) -> Style
128
+ def self.bg_color(c)
129
+ Style.new.bg_color(c)
130
+ end
131
+
132
+ #: (Integer c) -> Style
133
+ def self.border_color(c)
134
+ Style.new.border_color(c)
135
+ end
136
+
137
+ #: (Float r) -> Style
138
+ def self.border_radius(r)
139
+ Style.new.border_radius(r)
140
+ end
141
+
142
+ #: (Float s) -> Style
143
+ def self.font_size(s)
144
+ Style.new.font_size(s)
145
+ end
146
+
147
+ #: () -> Style
148
+ def self.expanding
149
+ Style.new.expanding
150
+ end
151
+
152
+ #: () -> Style
153
+ def self.expanding_width
154
+ Style.new.expanding_width
155
+ end
156
+
157
+ #: () -> Style
158
+ def self.expanding_height
159
+ Style.new.expanding_height
160
+ end
161
+
162
+ #: (Integer c) -> Style
163
+ def self.color(c)
164
+ Style.new.color(c)
165
+ end
166
+
167
+ #: (Integer c) -> Style
168
+ def self.text_color(c)
169
+ Style.new.text_color(c)
170
+ end
171
+
172
+ #: () -> Style
173
+ def self.bold
174
+ Style.new.bold
175
+ end
176
+
177
+ #: () -> Style
178
+ def self.italic
179
+ Style.new.italic
180
+ end
181
+
182
+ #: (Integer a) -> Style
183
+ def self.align(a)
184
+ Style.new.align(a)
185
+ end
186
+
187
+ #: (String f) -> Style
188
+ def self.font_family(f)
189
+ Style.new.font_family(f)
190
+ end
191
+
192
+ #: (Integer k) -> Style
193
+ def self.kind(k)
194
+ Style.new.kind(k)
195
+ end
196
+
197
+ # --- Instance methods: chainable setters ---
198
+
199
+ #: (Float w) -> Style
200
+ def fixed_width(w)
201
+ @has_fixed_width = true
202
+ @fixed_width_val = w
203
+ self
204
+ end
205
+
206
+ #: (Float w) -> Style
207
+ def width(w)
208
+ @has_fixed_width = true
209
+ @fixed_width_val = w
210
+ self
211
+ end
212
+
213
+ #: (Float h) -> Style
214
+ def fixed_height(h)
215
+ @has_fixed_height = true
216
+ @fixed_height_val = h
217
+ self
218
+ end
219
+
220
+ #: (Float h) -> Style
221
+ def height(h)
222
+ @has_fixed_height = true
223
+ @fixed_height_val = h
224
+ self
225
+ end
226
+
227
+ #: (Float w, Float h) -> Style
228
+ def size(w, h)
229
+ @has_fixed_width = true
230
+ @fixed_width_val = w
231
+ @has_fixed_height = true
232
+ @fixed_height_val = h
233
+ self
234
+ end
235
+
236
+ #: () -> Style
237
+ def fit_content
238
+ @fit_content_val = true
239
+ self
240
+ end
241
+
242
+ #: (Integer f) -> Style
243
+ def flex(f)
244
+ @has_flex = true
245
+ @flex_val = f
246
+ self
247
+ end
248
+
249
+ #: (Float v) -> Style
250
+ def padding(v)
251
+ @has_padding = true
252
+ @pad_top = v
253
+ @pad_right = v
254
+ @pad_bottom = v
255
+ @pad_left = v
256
+ self
257
+ end
258
+
259
+ #: (Float v) -> Style
260
+ def spacing(v)
261
+ @has_spacing = true
262
+ @spacing_val = v
263
+ self
264
+ end
265
+
266
+ #: () -> Style
267
+ def scrollable
268
+ @scrollable_val = true
269
+ self
270
+ end
271
+
272
+ #: () -> Style
273
+ def pin_to_bottom
274
+ @pin_bottom_val = true
275
+ self
276
+ end
277
+
278
+ #: () -> Style
279
+ def pin_to_end
280
+ @pin_end_val = true
281
+ self
282
+ end
283
+
284
+ #: (Integer c) -> Style
285
+ def bg_color(c)
286
+ @has_bg_color = true
287
+ @bg_color_val = c
288
+ self
289
+ end
290
+
291
+ #: (Integer c) -> Style
292
+ def border_color(c)
293
+ @has_border_color = true
294
+ @border_color_val = c
295
+ self
296
+ end
297
+
298
+ #: (Float r) -> Style
299
+ def border_radius(r)
300
+ @has_border_radius = true
301
+ @border_radius_val = r
302
+ self
303
+ end
304
+
305
+ #: (Float s) -> Style
306
+ def font_size(s)
307
+ @has_font_size = true
308
+ @font_size_val = s
309
+ self
310
+ end
311
+
312
+ #: () -> Style
313
+ def expanding
314
+ @has_expanding = true
315
+ @expanding_width_val = true
316
+ @expanding_height_val = true
317
+ self
318
+ end
319
+
320
+ #: () -> Style
321
+ def expanding_width
322
+ @has_expanding = true
323
+ @expanding_width_val = true
324
+ self
325
+ end
326
+
327
+ #: () -> Style
328
+ def expanding_height
329
+ @has_expanding = true
330
+ @expanding_height_val = true
331
+ self
332
+ end
333
+
334
+ # --- Typography setters ---
335
+
336
+ #: (Integer c) -> Style
337
+ def color(c)
338
+ @has_color = true
339
+ @color_val = c
340
+ self
341
+ end
342
+
343
+ #: (Integer c) -> Style
344
+ def text_color(c)
345
+ @has_text_color = true
346
+ @text_color_val = c
347
+ self
348
+ end
349
+
350
+ #: () -> Style
351
+ def bold
352
+ @bold_val = true
353
+ self
354
+ end
355
+
356
+ #: () -> Style
357
+ def italic
358
+ @italic_val = true
359
+ self
360
+ end
361
+
362
+ #: (Integer a) -> Style
363
+ def align(a)
364
+ @has_align = true
365
+ @align_val = a
366
+ self
367
+ end
368
+
369
+ #: (String f) -> Style
370
+ def font_family(f)
371
+ @has_font_family = true
372
+ @font_family_val = f
373
+ self
374
+ end
375
+
376
+ #: (Integer k) -> Style
377
+ def kind(k)
378
+ @has_kind = true
379
+ @kind_val = k
380
+ self
381
+ end
382
+
383
+ # --- Composition ---
384
+
385
+ #: (Style other) -> Style
386
+ def then(other)
387
+ result = Style.new
388
+ result.merge_from(self)
389
+ result.merge_from(other)
390
+ result
391
+ end
392
+
393
+ #: (Style other) -> Style
394
+ def +(other)
395
+ result = Style.new
396
+ result.merge_from(self)
397
+ result.merge_from(other)
398
+ result
399
+ end
400
+
401
+ #: (Style src) -> void
402
+ def merge_from(src)
403
+ if src.get_has_fixed_width
404
+ @has_fixed_width = true
405
+ @fixed_width_val = src.get_fixed_width
406
+ end
407
+ if src.get_has_fixed_height
408
+ @has_fixed_height = true
409
+ @fixed_height_val = src.get_fixed_height
410
+ end
411
+ if src.get_fit_content
412
+ @fit_content_val = true
413
+ end
414
+ if src.get_has_flex
415
+ @has_flex = true
416
+ @flex_val = src.get_flex
417
+ end
418
+ if src.get_has_padding
419
+ @has_padding = true
420
+ @pad_top = src.get_pad_top
421
+ @pad_right = src.get_pad_right
422
+ @pad_bottom = src.get_pad_bottom
423
+ @pad_left = src.get_pad_left
424
+ end
425
+ if src.get_has_spacing
426
+ @has_spacing = true
427
+ @spacing_val = src.get_spacing
428
+ end
429
+ if src.get_scrollable
430
+ @scrollable_val = true
431
+ end
432
+ if src.get_pin_bottom
433
+ @pin_bottom_val = true
434
+ end
435
+ if src.get_pin_end
436
+ @pin_end_val = true
437
+ end
438
+ if src.get_has_bg_color
439
+ @has_bg_color = true
440
+ @bg_color_val = src.get_bg_color
441
+ end
442
+ if src.get_has_border_color
443
+ @has_border_color = true
444
+ @border_color_val = src.get_border_color
445
+ end
446
+ if src.get_has_border_radius
447
+ @has_border_radius = true
448
+ @border_radius_val = src.get_border_radius
449
+ end
450
+ if src.get_has_font_size
451
+ @has_font_size = true
452
+ @font_size_val = src.get_font_size
453
+ end
454
+ if src.get_has_expanding
455
+ @has_expanding = true
456
+ @expanding_width_val = src.get_expanding_width
457
+ @expanding_height_val = src.get_expanding_height
458
+ end
459
+ # Typography
460
+ if src.get_has_color
461
+ @has_color = true
462
+ @color_val = src.get_color
463
+ end
464
+ if src.get_has_text_color
465
+ @has_text_color = true
466
+ @text_color_val = src.get_text_color
467
+ end
468
+ if src.get_bold
469
+ @bold_val = true
470
+ end
471
+ if src.get_italic
472
+ @italic_val = true
473
+ end
474
+ if src.get_has_align
475
+ @has_align = true
476
+ @align_val = src.get_align
477
+ end
478
+ if src.get_has_font_family
479
+ @has_font_family = true
480
+ @font_family_val = src.get_font_family
481
+ end
482
+ if src.get_has_kind
483
+ @has_kind = true
484
+ @kind_val = src.get_kind
485
+ end
486
+ end
487
+
488
+ # --- Getters (for merge_from) ---
489
+
490
+ #: () -> bool
491
+ def get_has_fixed_width
492
+ @has_fixed_width
493
+ end
494
+
495
+ #: () -> Float
496
+ def get_fixed_width
497
+ @fixed_width_val
498
+ end
499
+
500
+ #: () -> bool
501
+ def get_has_fixed_height
502
+ @has_fixed_height
503
+ end
504
+
505
+ #: () -> Float
506
+ def get_fixed_height
507
+ @fixed_height_val
508
+ end
509
+
510
+ #: () -> bool
511
+ def get_fit_content
512
+ @fit_content_val
513
+ end
514
+
515
+ #: () -> bool
516
+ def get_has_flex
517
+ @has_flex
518
+ end
519
+
520
+ #: () -> Integer
521
+ def get_flex
522
+ @flex_val
523
+ end
524
+
525
+ #: () -> bool
526
+ def get_has_padding
527
+ @has_padding
528
+ end
529
+
530
+ #: () -> Float
531
+ def get_pad_top
532
+ @pad_top
533
+ end
534
+
535
+ #: () -> Float
536
+ def get_pad_right
537
+ @pad_right
538
+ end
539
+
540
+ #: () -> Float
541
+ def get_pad_bottom
542
+ @pad_bottom
543
+ end
544
+
545
+ #: () -> Float
546
+ def get_pad_left
547
+ @pad_left
548
+ end
549
+
550
+ #: () -> bool
551
+ def get_has_spacing
552
+ @has_spacing
553
+ end
554
+
555
+ #: () -> Float
556
+ def get_spacing
557
+ @spacing_val
558
+ end
559
+
560
+ #: () -> bool
561
+ def get_scrollable
562
+ @scrollable_val
563
+ end
564
+
565
+ #: () -> bool
566
+ def get_pin_bottom
567
+ @pin_bottom_val
568
+ end
569
+
570
+ #: () -> bool
571
+ def get_pin_end
572
+ @pin_end_val
573
+ end
574
+
575
+ #: () -> bool
576
+ def get_has_bg_color
577
+ @has_bg_color
578
+ end
579
+
580
+ #: () -> Integer
581
+ def get_bg_color
582
+ @bg_color_val
583
+ end
584
+
585
+ #: () -> bool
586
+ def get_has_border_color
587
+ @has_border_color
588
+ end
589
+
590
+ #: () -> Integer
591
+ def get_border_color
592
+ @border_color_val
593
+ end
594
+
595
+ #: () -> bool
596
+ def get_has_border_radius
597
+ @has_border_radius
598
+ end
599
+
600
+ #: () -> Float
601
+ def get_border_radius
602
+ @border_radius_val
603
+ end
604
+
605
+ #: () -> bool
606
+ def get_has_font_size
607
+ @has_font_size
608
+ end
609
+
610
+ #: () -> Float
611
+ def get_font_size
612
+ @font_size_val
613
+ end
614
+
615
+ #: () -> bool
616
+ def get_has_expanding
617
+ @has_expanding
618
+ end
619
+
620
+ #: () -> bool
621
+ def get_expanding_width
622
+ @expanding_width_val
623
+ end
624
+
625
+ #: () -> bool
626
+ def get_expanding_height
627
+ @expanding_height_val
628
+ end
629
+
630
+ # Typography getters
631
+
632
+ #: () -> bool
633
+ def get_has_color
634
+ @has_color
635
+ end
636
+
637
+ #: () -> Integer
638
+ def get_color
639
+ @color_val
640
+ end
641
+
642
+ #: () -> bool
643
+ def get_has_text_color
644
+ @has_text_color
645
+ end
646
+
647
+ #: () -> Integer
648
+ def get_text_color
649
+ @text_color_val
650
+ end
651
+
652
+ #: () -> bool
653
+ def get_bold
654
+ @bold_val
655
+ end
656
+
657
+ #: () -> bool
658
+ def get_italic
659
+ @italic_val
660
+ end
661
+
662
+ #: () -> bool
663
+ def get_has_align
664
+ @has_align
665
+ end
666
+
667
+ #: () -> Integer
668
+ def get_align
669
+ @align_val
670
+ end
671
+
672
+ #: () -> bool
673
+ def get_has_font_family
674
+ @has_font_family
675
+ end
676
+
677
+ #: () -> String
678
+ def get_font_family
679
+ @font_family_val
680
+ end
681
+
682
+ #: () -> bool
683
+ def get_has_kind
684
+ @has_kind
685
+ end
686
+
687
+ #: () -> Integer
688
+ def get_kind
689
+ @kind_val
690
+ end
691
+
692
+ # --- Apply to widget (explicit dispatch, no send/method_missing) ---
693
+
694
+ #: (untyped widget) -> untyped
695
+ def apply_layout(widget)
696
+ if @has_fixed_width
697
+ widget.fixed_width(@fixed_width_val)
698
+ end
699
+ if @has_fixed_height
700
+ widget.fixed_height(@fixed_height_val)
701
+ end
702
+ if @fit_content_val
703
+ widget.fit_content
704
+ end
705
+ if @has_flex
706
+ widget.flex(@flex_val)
707
+ end
708
+ if @has_padding
709
+ widget.padding(@pad_top, @pad_right, @pad_bottom, @pad_left)
710
+ end
711
+ if @has_expanding
712
+ if @expanding_width_val
713
+ widget.set_width_policy(EXPANDING)
714
+ end
715
+ if @expanding_height_val
716
+ widget.set_height_policy(EXPANDING)
717
+ end
718
+ end
719
+ widget
720
+ end
721
+
722
+ #: (untyped widget) -> untyped
723
+ def apply_container(widget)
724
+ if @has_spacing
725
+ widget.spacing(@spacing_val)
726
+ end
727
+ if @scrollable_val
728
+ widget.scrollable
729
+ end
730
+ if @pin_bottom_val
731
+ widget.pin_to_bottom
732
+ end
733
+ if @pin_end_val
734
+ widget.pin_to_end
735
+ end
736
+ widget
737
+ end
738
+
739
+ #: (untyped widget) -> untyped
740
+ def apply_visual(widget)
741
+ if @has_bg_color
742
+ widget.bg_color(@bg_color_val)
743
+ end
744
+ if @has_border_color
745
+ widget.border_color(@border_color_val)
746
+ end
747
+ if @has_border_radius
748
+ widget.border_radius(@border_radius_val)
749
+ end
750
+ widget
751
+ end
752
+
753
+ #: (untyped widget) -> untyped
754
+ def apply_text(widget)
755
+ if @has_font_size
756
+ widget.font_size(@font_size_val)
757
+ end
758
+ widget
759
+ end
760
+
761
+ #: (untyped widget) -> untyped
762
+ def apply_typography(widget)
763
+ if @has_font_size
764
+ widget.font_size(@font_size_val)
765
+ end
766
+ if @has_color
767
+ widget.color(@color_val)
768
+ end
769
+ if @has_text_color
770
+ widget.text_color(@text_color_val)
771
+ end
772
+ if @bold_val
773
+ widget.bold
774
+ end
775
+ if @italic_val
776
+ widget.italic
777
+ end
778
+ if @has_align
779
+ widget.align(@align_val)
780
+ end
781
+ if @has_font_family
782
+ widget.font_family(@font_family_val)
783
+ end
784
+ if @has_kind
785
+ widget.kind(@kind_val)
786
+ end
787
+ widget
788
+ end
789
+
790
+ #: (untyped widget) -> untyped
791
+ def apply(widget)
792
+ apply_layout(widget)
793
+ apply_container(widget)
794
+ apply_visual(widget)
795
+ widget
796
+ end
797
+ end
798
+
799
+ end