glimmer-dsl-opal 0.28.0 → 0.29.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (171) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +27 -0
  3. data/LICENSE.txt +1 -1
  4. data/README.md +175 -28
  5. data/VERSION +1 -1
  6. data/app/assets/images/glimmer/images/ui-icons_444444_256x240.png +0 -0
  7. data/app/assets/images/glimmer/images/ui-icons_555555_256x240.png +0 -0
  8. data/app/assets/images/glimmer/images/ui-icons_777620_256x240.png +0 -0
  9. data/app/assets/images/glimmer/images/ui-icons_777777_256x240.png +0 -0
  10. data/app/assets/images/glimmer/images/ui-icons_cc0000_256x240.png +0 -0
  11. data/app/assets/images/glimmer/images/ui-icons_ffffff_256x240.png +0 -0
  12. data/app/assets/stylesheets/glimmer/jquery-ui.css +109 -106
  13. data/app/assets/stylesheets/glimmer/jquery-ui.structure.css +91 -91
  14. data/app/assets/stylesheets/glimmer/jquery-ui.theme.css +18 -15
  15. data/app/controllers/glimmer/image_paths_controller.rb +0 -1
  16. data/config/routes.rb +1 -1
  17. data/lib/display.rb +1 -1
  18. data/lib/glimmer/data_binding/table_items_binding.rb +1 -1
  19. data/lib/glimmer/dsl/opal/async_exec_expression.rb +1 -1
  20. data/lib/glimmer/dsl/opal/bind_expression.rb +1 -1
  21. data/lib/glimmer/dsl/opal/block_property_expression.rb +1 -1
  22. data/lib/glimmer/dsl/opal/checkbox_group_selection_data_binding_expression.rb +1 -1
  23. data/lib/glimmer/dsl/opal/color_expression.rb +1 -1
  24. data/lib/glimmer/dsl/opal/custom_widget_expression.rb +3 -3
  25. data/lib/glimmer/dsl/opal/data_binding_expression.rb +1 -1
  26. data/lib/glimmer/dsl/opal/dialog_expression.rb +1 -1
  27. data/lib/glimmer/dsl/opal/display_expression.rb +1 -1
  28. data/lib/glimmer/dsl/opal/dsl.rb +2 -0
  29. data/lib/glimmer/dsl/opal/exec_expression.rb +1 -1
  30. data/lib/glimmer/dsl/opal/font_expression.rb +1 -1
  31. data/lib/glimmer/dsl/opal/image_expression.rb +64 -0
  32. data/lib/glimmer/dsl/opal/menu_bar_expression.rb +1 -1
  33. data/lib/glimmer/dsl/opal/menu_expression.rb +2 -2
  34. data/lib/glimmer/dsl/opal/message_box_expression.rb +1 -1
  35. data/lib/glimmer/dsl/opal/property_expression.rb +2 -3
  36. data/lib/glimmer/dsl/opal/radio_group_selection_data_binding_expression.rb +1 -1
  37. data/lib/glimmer/dsl/opal/rgb_expression.rb +1 -1
  38. data/lib/glimmer/dsl/opal/rgba_expression.rb +1 -1
  39. data/lib/glimmer/dsl/opal/shape_expression.rb +6 -4
  40. data/lib/glimmer/dsl/opal/shell_expression.rb +2 -2
  41. data/lib/glimmer/dsl/opal/shine_data_binding_expression.rb +1 -1
  42. data/lib/glimmer/dsl/opal/swt_expression.rb +1 -1
  43. data/lib/glimmer/dsl/opal/sync_exec_expression.rb +1 -1
  44. data/lib/glimmer/dsl/opal/widget_expression.rb +1 -1
  45. data/lib/glimmer/engine.rb +1 -1
  46. data/lib/glimmer/swt/arrow_proxy.rb +7 -1
  47. data/lib/glimmer/swt/button_proxy.rb +4 -3
  48. data/lib/glimmer/swt/c_combo_proxy.rb +1 -1
  49. data/lib/glimmer/swt/c_tab_folder_proxy.rb +1 -1
  50. data/lib/glimmer/swt/c_tab_item_proxy.rb +1 -1
  51. data/lib/glimmer/swt/checkbox_proxy.rb +3 -2
  52. data/lib/glimmer/swt/color_proxy.rb +1 -1
  53. data/lib/glimmer/swt/composite_proxy.rb +1 -1
  54. data/lib/glimmer/swt/control_editor.rb +1 -1
  55. data/lib/glimmer/swt/custom/checkbox_group.rb +1 -1
  56. data/lib/glimmer/swt/custom/radio_group.rb +1 -1
  57. data/lib/glimmer/swt/custom/shape/arc.rb +75 -0
  58. data/lib/glimmer/swt/custom/shape/image.rb +98 -0
  59. data/lib/glimmer/swt/custom/shape/line.rb +4 -1
  60. data/lib/glimmer/swt/custom/shape/oval.rb +1 -1
  61. data/lib/glimmer/swt/custom/shape/point.rb +4 -1
  62. data/lib/glimmer/swt/custom/shape/polygon.rb +4 -1
  63. data/lib/glimmer/swt/custom/shape/polyline.rb +4 -1
  64. data/lib/glimmer/swt/custom/shape/rectangle.rb +53 -2
  65. data/lib/glimmer/swt/custom/shape/text.rb +52 -2
  66. data/lib/glimmer/swt/custom/shape.rb +101 -5
  67. data/lib/glimmer/swt/date_time_proxy.rb +2 -2
  68. data/lib/glimmer/swt/dialog_proxy.rb +1 -1
  69. data/lib/glimmer/swt/font_proxy.rb +1 -1
  70. data/lib/glimmer/swt/image_proxy.rb +29 -0
  71. data/lib/glimmer/swt/label_proxy.rb +1 -1
  72. data/lib/glimmer/swt/latest_dialog_proxy.rb +1 -1
  73. data/lib/glimmer/swt/latest_message_box_proxy.rb +1 -1
  74. data/lib/glimmer/swt/latest_shell_proxy.rb +4 -4
  75. data/lib/glimmer/swt/layout_proxy.rb +1 -1
  76. data/lib/glimmer/swt/make_shift_shell_proxy.rb +1 -1
  77. data/lib/glimmer/swt/menu_item_proxy.rb +3 -3
  78. data/lib/glimmer/swt/menu_proxy.rb +22 -16
  79. data/lib/glimmer/swt/message_box_proxy.rb +1 -1
  80. data/lib/glimmer/swt/progress_bar_proxy.rb +1 -1
  81. data/lib/glimmer/swt/scale_proxy.rb +7 -1
  82. data/lib/glimmer/swt/shell_proxy.rb +1 -1
  83. data/lib/glimmer/swt/slider_proxy.rb +6 -0
  84. data/lib/glimmer/swt/spinner_proxy.rb +4 -3
  85. data/lib/glimmer/swt/style_constantizable.rb +1 -1
  86. data/lib/glimmer/swt/swt_proxy.rb +1 -1
  87. data/lib/glimmer/swt/tab_folder_proxy.rb +1 -1
  88. data/lib/glimmer/swt/tab_item_proxy.rb +1 -1
  89. data/lib/glimmer/swt/table_editor.rb +1 -1
  90. data/lib/glimmer/swt/table_item_proxy.rb +3 -3
  91. data/lib/glimmer/swt/table_proxy.rb +1 -1
  92. data/lib/glimmer/swt/widget_proxy.rb +29 -28
  93. data/lib/glimmer/swt.rb +1 -1
  94. data/lib/glimmer/ui/custom_shell.rb +1 -5
  95. data/lib/glimmer/ui/custom_widget.rb +5 -5
  96. data/lib/glimmer/util/proc_tracker.rb +3 -3
  97. data/lib/glimmer-dsl-opal/ext/date.rb +8 -8
  98. data/lib/glimmer-dsl-opal/ext/file.rb +1 -1
  99. data/lib/glimmer-dsl-opal/ext/glimmer/dsl/engine.rb +1 -1
  100. data/lib/glimmer-dsl-opal/samples/elaborate/contact_manager/contact_repository.rb +1 -1
  101. data/lib/glimmer-dsl-opal/samples/elaborate/login.rb +1 -1
  102. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/model/block.rb +1 -1
  103. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/model/game.rb +1 -1
  104. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/model/past_game.rb +1 -1
  105. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/model/tetromino.rb +1 -1
  106. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/view/block.rb +45 -1
  107. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/view/high_score_dialog.rb +1 -1
  108. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/view/playfield.rb +1 -1
  109. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/view/score_lane.rb +1 -1
  110. data/lib/glimmer-dsl-opal/samples/elaborate/tetris/view/tetris_menu_bar.rb +1 -1
  111. data/lib/glimmer-dsl-opal/samples/elaborate/tetris.rb +3 -3
  112. data/lib/glimmer-dsl-opal/samples/elaborate/tic_tac_toe.rb +1 -1
  113. data/lib/glimmer-dsl-opal/samples/elaborate/user_profile.rb +1 -1
  114. data/lib/glimmer-dsl-opal/samples/elaborate/weather.rb +5 -4
  115. data/lib/glimmer-dsl-opal/samples/hello/hello_arrow.rb +1 -1
  116. data/lib/glimmer-dsl-opal/samples/hello/hello_browser.rb +1 -1
  117. data/lib/glimmer-dsl-opal/samples/hello/hello_button.rb +1 -1
  118. data/lib/glimmer-dsl-opal/samples/hello/hello_c_combo.rb +1 -1
  119. data/lib/glimmer-dsl-opal/samples/hello/hello_c_tab.rb +1 -1
  120. data/lib/glimmer-dsl-opal/samples/hello/hello_canvas.rb +25 -2
  121. data/lib/glimmer-dsl-opal/samples/hello/hello_checkbox.rb +1 -1
  122. data/lib/glimmer-dsl-opal/samples/hello/hello_checkbox_group.rb +1 -1
  123. data/lib/glimmer-dsl-opal/samples/hello/hello_combo.rb +1 -1
  124. data/lib/glimmer-dsl-opal/samples/hello/hello_composite.rb +1 -1
  125. data/lib/glimmer-dsl-opal/samples/hello/hello_computed.rb +1 -1
  126. data/lib/glimmer-dsl-opal/samples/hello/hello_cursor.rb +1 -1
  127. data/lib/glimmer-dsl-opal/samples/hello/hello_custom_shell.rb +1 -1
  128. data/lib/glimmer-dsl-opal/samples/hello/hello_custom_widget.rb +1 -1
  129. data/lib/glimmer-dsl-opal/samples/hello/hello_date_time.rb +1 -1
  130. data/lib/glimmer-dsl-opal/samples/hello/hello_dialog.rb +1 -1
  131. data/lib/glimmer-dsl-opal/samples/hello/hello_group.rb +1 -1
  132. data/lib/glimmer-dsl-opal/samples/hello/hello_label.rb +1 -1
  133. data/lib/glimmer-dsl-opal/samples/hello/hello_layout.rb +1 -1
  134. data/lib/glimmer-dsl-opal/samples/hello/hello_list_multi_selection.rb +1 -1
  135. data/lib/glimmer-dsl-opal/samples/hello/hello_list_single_selection.rb +1 -1
  136. data/lib/glimmer-dsl-opal/samples/hello/hello_menu_bar.rb +1 -1
  137. data/lib/glimmer-dsl-opal/samples/hello/hello_message_box.rb +1 -1
  138. data/lib/glimmer-dsl-opal/samples/hello/hello_pop_up_context_menu.rb +1 -1
  139. data/lib/glimmer-dsl-opal/samples/hello/hello_print.rb +1 -1
  140. data/lib/glimmer-dsl-opal/samples/hello/hello_progress_bar.rb +1 -1
  141. data/lib/glimmer-dsl-opal/samples/hello/hello_radio.rb +1 -1
  142. data/lib/glimmer-dsl-opal/samples/hello/hello_radio_group.rb +1 -1
  143. data/lib/glimmer-dsl-opal/samples/hello/hello_scale.rb +1 -1
  144. data/lib/glimmer-dsl-opal/samples/hello/hello_slider.rb +1 -1
  145. data/lib/glimmer-dsl-opal/samples/hello/hello_spinner.rb +1 -1
  146. data/lib/glimmer-dsl-opal/samples/hello/hello_tab.rb +1 -1
  147. data/lib/glimmer-dsl-opal/samples/hello/hello_table.rb +1 -1
  148. data/lib/glimmer-dsl-opal/samples/hello/hello_text.rb +1 -1
  149. data/lib/glimmer-dsl-opal/samples/hello/hello_world.rb +1 -1
  150. data/lib/glimmer-dsl-opal/samples/hello/images/scaffold_app.png +0 -0
  151. data/lib/glimmer-dsl-opal/vendor/jquery-ui/AUTHORS.txt +35 -1
  152. data/lib/glimmer-dsl-opal/vendor/jquery-ui/index.html +503 -0
  153. data/lib/glimmer-dsl-opal/vendor/jquery-ui/jquery-ui.min.css +4 -4
  154. data/lib/glimmer-dsl-opal/vendor/jquery-ui/jquery-ui.min.js +3 -10
  155. data/lib/glimmer-dsl-opal/vendor/jquery-ui/jquery-ui.structure.min.css +2 -2
  156. data/lib/glimmer-dsl-opal/vendor/jquery-ui/jquery-ui.theme.min.css +2 -2
  157. data/lib/glimmer-dsl-opal/vendor/jquery-ui/package.json +26 -26
  158. data/lib/glimmer-dsl-opal/vendor/jquery.js +10881 -2
  159. data/lib/glimmer-dsl-opal/vendor/two.min.js +24 -0
  160. data/lib/glimmer-dsl-opal.rb +2 -1
  161. data/lib/glimmer-dsl-swt.rb +1 -1
  162. data/lib/net/http.rb +1 -1
  163. data/lib/os.rb +1 -1
  164. metadata +16 -16
  165. data/app/assets/images/glimmer/images/ui-icons_222222_256x240.png +0 -0
  166. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_444444_256x240.png +0 -0
  167. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_555555_256x240.png +0 -0
  168. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_777620_256x240.png +0 -0
  169. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_777777_256x240.png +0 -0
  170. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_cc0000_256x240.png +0 -0
  171. data/lib/glimmer-dsl-opal/vendor/jquery-ui/images/ui-icons_ffffff_256x240.png +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0f9cfe8a0d719c4ae80348ac72fd00f41190c31f405a2e38916f271ca35fab26
4
- data.tar.gz: 0e44d82d8e35f15b35861195ec782cce25d0f2265b960cc65866212908a3a477
3
+ metadata.gz: 74430682335a43e8c15f65ea995ccedee45acf85aad90e223e277b4077123067
4
+ data.tar.gz: 59b69a644fd137e9dfb11752e54e8de7724f90f1650cc5b852affaba99c6eb6a
5
5
  SHA512:
6
- metadata.gz: 9f6321b66a2fbb55fb53f5d5d32031ef62afb8db46b0595161c6feaa41a0af01f12e44483c137c4ee06cced7633c0a6898f924f1ab46fc230d3d5c263762c8b8
7
- data.tar.gz: 44add1a5d248c51c8876aefa4a48c26dba0fbe0a9acae9ad22eb22e0dd3785f3a5feeac2102dad98c0057bf030785bec97ef49b15a9a6b838ddc3d7016ae3646
6
+ metadata.gz: 38367a8a42eb26f53765f61b2bd4ee3cec0bc5a70e1b0252fc52c12244aa350d00cf161be3025982760a05dea63e4517b6ccd1864fbe9893149b1a5bbd22e019
7
+ data.tar.gz: 976cdf2d3626d84aa94088c29981f7a283a908fddc8f83729e05298d30c71f411576b0e3e0fdf9a3491ce44e0cb1bd5fd24e81a4831a51b6a58443f94832df57
data/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # Change Log
2
2
 
3
+ ## 0.29.0
4
+
5
+ - Support Rails 7
6
+ - Upgrade to Opal 1.4.1
7
+ - Upgrade jQuery to 3.6.0
8
+ - Upgrade jQuery-UI to 1.13.1
9
+ - Fix Hello, Arrow! (menu is showing up outside of widget on the top left of the screen)
10
+ - Upgrade to Glimmer DSL for XML 1.3.1
11
+ - Upgrade to Glimmer DSL for CSS 1.2.1
12
+
13
+ ## 0.28.3
14
+
15
+ - Support Canvas Shape DSL data-binding
16
+ - Use Canvas Shape DSL data-binding with Hello, Canvas! text string attribute
17
+ - Add bevel 3D look to Tetris elaborate sample via Canvas Shape DSL
18
+ - Ensure shell height compensates for providing extra top space to menu_bar when rendered
19
+
20
+ ## 0.28.2
21
+
22
+ - Support `image` Canvas Shape DSL keyword
23
+ - Use `image` in Hello, Canvas! sample
24
+
25
+ ## 0.28.1
26
+
27
+ - Support `arc` Canvas Shape DSL keyword (partial support whereby width is assumed to be equal to height to start from a circle basis)
28
+ - Use `arc` in Hello, Canvas! sample
29
+
3
30
  ## 0.28.0
4
31
 
5
32
  - Initial support for Canvas Shape DSL keywords (no-databinding, nesting, or gradients yet):
data/LICENSE.txt CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2020-2021 Andy Maleh
1
+ Copyright (c) 2020-2022 Andy Maleh
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -143,15 +143,23 @@ Hello, Table! Game Booked
143
143
 
144
144
  ![Glimmer DSL for Opal Hello Table](images/glimmer-dsl-opal-hello-table-game-booked.png)
145
145
 
146
- NOTE: Glimmer DSL for Opal is an alpha project. Please help make better by contributing, adopting for small or low risk projects, and providing feedback. It is still an early alpha, so the more feedback and issues you report the better.
147
-
148
- **Alpha Version** 0.28.0 only supports bare-minimum capabilities for the included [samples](https://github.com/AndyObtiva/glimmer-dsl-opal#samples) (originally written for [glimmer-dsl-swt](https://github.com/AndyObtiva/glimmer-dsl-swt))
149
-
150
- Other [Glimmer](https://github.com/AndyObtiva/glimmer) DSL gems:
151
- - [glimmer-dsl-swt](https://github.com/AndyObtiva/glimmer-dsl-swt): Glimmer DSL for SWT (JRuby Desktop Development GUI Framework)
152
- - [glimmer-dsl-xml](https://github.com/AndyObtiva/glimmer-dsl-xml): Glimmer DSL for XML (& HTML)
153
- - [glimmer-dsl-css](https://github.com/AndyObtiva/glimmer-dsl-css): Glimmer DSL for CSS (Cascading Style Sheets)
154
- - [glimmer-dsl-tk](https://github.com/AndyObtiva/glimmer-dsl-tk): Glimmer DSL for Tk (MRI Ruby Desktop Development GUI Library)
146
+ NOTE: Glimmer DSL for Opal is an alpha project (only about 76% complete). If you want it developed faster, then [open an issue report](https://github.com/AndyObtiva/glimmer-dsl-opal/issues/new). I have completed some GitHub project features much faster before due to [issue reports](https://github.com/AndyObtiva/glimmer-dsl-opal/issues) and [pull requests](https://github.com/AndyObtiva/glimmer-dsl-opal/pulls). Please help make better by contributing, adopting for small or low risk projects, and providing feedback. It is still an early alpha, so the more feedback and issues you report the better.
147
+
148
+ **Alpha Version** 0.29.0 only supports bare-minimum capabilities for the included [samples](https://github.com/AndyObtiva/glimmer-dsl-opal#samples) (originally written for [glimmer-dsl-swt](https://github.com/AndyObtiva/glimmer-dsl-swt)).
149
+
150
+ **[Glimmer](https://github.com/AndyObtiva/glimmer) DSL Comparison Table:**
151
+ DSL | Platforms | Native? | Vector Graphics? | Pros | Cons | Prereqs
152
+ ----|-----------|---------|------------------|------|------|--------
153
+ [Glimmer DSL for SWT (JRuby Desktop Development GUI Framework)](https://github.com/AndyObtiva/glimmer-dsl-swt) | Mac / Windows / Linux | Yes | Yes (Canvas Shape DSL) | Very Mature / Scaffolding / Native Executable Packaging / Custom Widgets | Slow JRuby Startup Time / Heavy Memory Footprint | Java / JRuby
154
+ [Glimmer DSL for Opal (Pure Ruby Web GUI and Auto-Webifier of Desktop Apps)](https://github.com/AndyObtiva/glimmer-dsl-opal) | All Web Browsers | No | Yes (Canvas Shape DSL) | Simpler than All JavaScript Technologies / Auto-Webify Desktop Apps | Setup Process / Incomplete Alpha | Rails
155
+ [Glimmer DSL for LibUI (Prerequisite-Free Ruby Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-libui) | Mac / Windows / Linux | Yes | Yes (Area API) | Very Simple Setup / Fast Startup Time / Light Memory Footprint | LibUI is an Incomplete Mid-Alpha Only | None Other Than MRI Ruby
156
+ [Glimmer DSL for Tk (MRI Ruby Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-tk) | Mac / Windows / Linux | Some Native-Themed Widgets (Not Truly Native) | Yes (Canvas) | Fast Startup Time / Light Memory Footprint | Widgets Do Not Look Truly Native, Espcially on Linux | ActiveTcl / MRI Ruby
157
+ [Glimmer DSL for GTK (Ruby-GNOME Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-gtk) | Mac / Windows / Linux | Only on Linux | Yes (Cairo) | Complete Access to GNOME Features on Linux | Not Native on Mac and Windows | None Other Than MRI Ruby on Linux / Brew Packages on Mac / MSYS & MING Toolchains on Windows / MRI Ruby
158
+ [Glimmer DSL for FX (FOX Toolkit Ruby Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-fx) | Mac (requires XQuartz) / Windows / Linux | No | Yes (Canvas) | No Prerequisites on Windows | Widgets Do Not Look Native / Mac Usage Obtrusively Starts XQuartz | None Other Than MRI Ruby on Windows / XQuarts on Mac / MRI Ruby
159
+ [Glimmer DSL for JFX (JRuby JavaFX Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-jfx) | Mac / Windows / Linux | No | Yes (javafx.scene.shape and javafx.scene.canvas) | Rich in Custom Widgets | Slow JRuby Startup Time / Heavy Memory Footprint / Widgets Do Not Look Native | Java / JRuby / JavaFX SDK
160
+ [Glimmer DSL for Swing (JRuby Swing Desktop Development GUI Library)](https://github.com/AndyObtiva/glimmer-dsl-swing) | Mac / Windows / Linux | No | Yes (Java2D) | Very Mature | Slow JRuby Startup Time / Heavy Memory Footprint / Widgets Do Not Look Native | Java / JRuby
161
+ [Glimmer DSL for XML (& HTML)](https://github.com/AndyObtiva/glimmer-dsl-xml) | All Web Browsers | No | Yes (SVG) | Programmable / Lighter-weight Than Actual XML | XML Elements Are Sometimes Not Well-Named (Many Types of Input) | None
162
+ [Glimmer DSL for CSS](https://github.com/AndyObtiva/glimmer-dsl-css) | All Web Browsers | No | Yes | Programmable | CSS Is Over-Engineered / Too Many Features To Learn | None
155
163
 
156
164
  ## Table of Contents
157
165
 
@@ -221,9 +229,10 @@ Please keep in mind this is a live list of innovative ideas, some of which have
221
229
 
222
230
  - **Live purely in Rubyland via the Glimmer GUI DSL**, completely oblivious to web browser technologies, thanks to [Opal](https://opalrb.com/).
223
231
  - **HTML is for creating documents not interactive applications**. As such, software engineers can avoid it and focus on creating web applications more productively with Glimmer DSL for Opal in pure Ruby instead (just like they do in desktop development) while content creators and web designers can be the ones responsible for creating HTML documents for web content purposes only as HTML was originally intended. That way, Glimmer web GUI is used and embedded in web pages when providing users with applications while the rest of the web pages are maintained by non-engineers as pure HTML. This achieves a correct separation of responsibilities and better productivity and maintainability.
224
- - **Approximate styles by developers via the Glimmer GUI DSL. Perfect styles by designers via pure CSS**. Developers can simply build GUI with approximate styling similar to desktop GUI and mockups without worrying about pixel-perfect aesthetics. Web designers can take styling further with pure CSS since every HTML element auto-generated by Glimmer DSL for Opal has a predictable ID and CSS class. This achieves a proper separation of responsibilities between developers and designers.
232
+ - **Approximate styles by developers via the Glimmer GUI DSL. Perfect styles by designers via pure CSS**. Developers can simply build GUI with approximate styling similar to desktop GUI and mockups without worrying about pixel-perfect aesthetics. Web designers can take styling further with pure CSS since every HTML element auto-generated by [Glimmer DSL for Opal](https://rubygems.org/gems/glimmer-dsl-opal) (using [Glimmer DSL for XML & HTML](https://rubygems.org/gems/glimmer-dsl-xml)) has a predictable ID and CSS class. This achieves a proper separation of responsibilities between developers and designers.
225
233
  - **Web servers are used just like servers in traditional client/server architecture**, meaning they simply provide RMI services to enable centralizing some of the application logic and data in the cloud to make available everywhere and enable data-sharing with others.
226
- - **Forget Routers!** Glimmer DSL for Opal supports auto-routing of custom shells (windows), which are opened as separate tabs in a web browser with automatically generated routes and bookmarkable URLs.
234
+ - **Forget Routers!** [Glimmer DSL for Opal](https://rubygems.org/gems/glimmer-dsl-opal) supports auto-routing of custom shells (windows), which are opened as separate tabs in a web browser with automatically generated routes and bookmarkable URLs.
235
+ - **Images Are Local** Desktop apps typically display local images included in app files. When running a desktop app on the web, Glimmer DSL for Opal automatically copies application images to the assets directory and exposes them as download links. Desktop image Ruby code that uses `File.expand_path` or `File.join` automatically detects available image web URLs and matches them to corresponding desktop image paths behind the scenes, so desktop app images show up on the web without any extra effort! ([Hello, Table!](#hello-table-sample) and [Hello, Label!](#hello-label-sample) are good examples of that)
227
236
 
228
237
  ## Background
229
238
 
@@ -237,18 +246,130 @@ Alternatively, web developers may directly use [Glimmer DSL for Opal](https://ru
237
246
 
238
247
  ## Pre-requisites
239
248
 
240
- - Rails 5.2: [https://github.com/rails/rails/tree/5-2-stable](https://github.com/rails/rails/tree/5-2-stable)
241
- - Opal 1.0.5: [https://github.com/opal/opal](https://github.com/opal/opal)
242
- - Opal-Rails 1.1.2: [https://github.com/opal/opal-rails](https://github.com/opal/opal-rails)
243
- - jQuery 3: [https://code.jquery.com/](https://code.jquery.com/) (jQuery 3.5.1 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
244
- - jQuery-UI 1.12: [https://code.jquery.com/](https://jqueryui.com/) (jQuery-UI 1.12.1 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
245
- - jQuery-UI Timepicker 0.3: [https://code.jquery.com/](https://fgelinas.com/code/timepicker/) (jQuery-UI Timepicker 0.3.3 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
249
+ - Rails 5 or 7: [https://github.com/rails/rails/tree/5-2-stable](https://github.com/rails/rails/tree/5-2-stable)
250
+ - Opal 1.0.5 for Rails 5 or Opal 1.4.1 for Rails 7: [https://github.com/opal/opal](https://github.com/opal/opal)
251
+ - Opal-Rails 1.1.2 for Rails 5 or Opal-Rails 2.0.2 for Rails 7: [https://github.com/opal/opal-rails](https://github.com/opal/opal-rails)
252
+ - jQuery 3 (included): [https://code.jquery.com/](https://code.jquery.com/) (jQuery 3.5.1 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
253
+ - jQuery-UI 1.12 (included): [https://code.jquery.com/](https://jqueryui.com/) (jQuery-UI 1.12.1 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
254
+ - jQuery-UI Timepicker 0.3 (included): [https://code.jquery.com/](https://fgelinas.com/code/timepicker/) (jQuery-UI Timepicker 0.3.3 is included in the [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem)
246
255
 
247
256
  ## Setup
248
257
 
249
258
  (NOTE: Keep in mind this is a very early experimental and incomplete **alpha**. If you run into issues, try to go back to a [previous revision](https://rubygems.org/gems/glimmer-dsl-opal/versions). Also, there is a slight chance any issues you encounter are fixed in master or some other branch that you could check out instead)
250
259
 
251
- The [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem is a Rails Engine gem that includes assets.
260
+ The [glimmer-dsl-opal](https://rubygems.org/gems/glimmer-dsl-opal) gem is a [Rails Engine](https://guides.rubyonrails.org/engines.html) gem that includes assets.
261
+
262
+ ### Rails 7
263
+
264
+ Please follow the following steps to setup.
265
+
266
+ Install a Rails 7 gem:
267
+
268
+ ```
269
+ gem install rails -v7.0.1
270
+ ```
271
+
272
+ Start a new Rails 7 app:
273
+
274
+ ```
275
+ rails new glimmer_app_server
276
+ ```
277
+
278
+ Add the following to `Gemfile`:
279
+
280
+ ```
281
+ gem 'opal', '1.4.1'
282
+ gem 'opal-rails', '2.0.2'
283
+ gem 'opal-async', '~> 1.4.0'
284
+ gem 'opal-jquery', '~> 0.4.6'
285
+ gem 'glimmer-dsl-opal', '~> 0.28.4'
286
+ gem 'glimmer-dsl-xml', '~> 1.3.1', require: false
287
+ gem 'glimmer-dsl-css', '~> 1.2.1', require: false
288
+ ```
289
+
290
+ Follow [opal-rails](https://github.com/opal/opal-rails) instructions, basically running:
291
+
292
+ ```
293
+ bin/rails g opal:install
294
+ ```
295
+
296
+ Edit `config/initializers/assets.rb` and add the following at the bottom:
297
+ ```
298
+ Opal.use_gem 'glimmer-dsl-opal'
299
+ ```
300
+
301
+ Run:
302
+
303
+ ```
304
+ rails g scaffold welcome
305
+ ```
306
+
307
+ Run:
308
+
309
+ ```
310
+ rails db:migrate
311
+ ```
312
+
313
+ Add the following to `config/routes.rb` inside the `Rails.application.routes.draw` block:
314
+
315
+ ```ruby
316
+ mount Glimmer::Engine => "/glimmer" # add on top
317
+ root to: 'welcomes#index'
318
+ ```
319
+
320
+ Edit `app/views/layouts/application.html.erb` and add the following below other `stylesheet_link_tag` declarations:
321
+
322
+ ```erb
323
+ <%= stylesheet_link_tag 'glimmer/glimmer', media: 'all', 'data-turbolinks-track': 'reload' %>
324
+ ```
325
+
326
+ Clear the file `app/views/welcomes/index.html.erb` completely from all content.
327
+
328
+ Delete `app/javascript/application.js`
329
+
330
+ Edit and replace `app/assets/javascript/application.js.rb` content with code below (optionally including a require statement for one of the [samples](#samples) below):
331
+
332
+ ```ruby
333
+ require 'glimmer-dsl-opal' # brings opal and other dependencies automatically
334
+
335
+ # Add more require-statements or Glimmer GUI DSL code
336
+ ```
337
+
338
+ Example to confirm setup is working:
339
+
340
+ ```ruby
341
+ require 'glimmer-dsl-opal'
342
+
343
+ include Glimmer
344
+
345
+ shell {
346
+ fill_layout
347
+ text 'Example to confirm setup is working'
348
+
349
+ label {
350
+ text "Welcome to Glimmer DSL for Opal!"
351
+ foreground :red
352
+ font height: 24
353
+ }
354
+ }.open
355
+ ```
356
+
357
+ Start the Rails server:
358
+ ```
359
+ rails s
360
+ ```
361
+
362
+ Visit `http://localhost:3000`
363
+
364
+ You should see:
365
+
366
+ ![setup is working](/images/glimmer-dsl-opal-setup-example-working.png)
367
+
368
+ If you run into any issues in setup, refer to the [Sample Glimmer DSL for Opal Rails](https://github.com/AndyObtiva/sample-glimmer-dsl-opal-rails-app) project (in case I forgot to include some setup steps by mistake). It is also hosted online (proving that it works): https://sample-glimmer-dsl-opal-app.herokuapp.com/
369
+
370
+ Otherwise, if you still cannot setup successfully (even with the help of the sample project, or if the sample project stops working), please do not hesitate to report an [Issue request](https://github.com/AndyObtiva/glimmer-dsl-opal/issues) or fix and submit a [Pull Request](https://github.com/AndyObtiva/glimmer-dsl-opal/pulls).
371
+
372
+ ### Rails 5
252
373
 
253
374
  Please follow the following steps to setup.
254
375
 
@@ -271,13 +392,12 @@ gem 'opal', '1.0.5'
271
392
  gem 'opal-rails', '1.1.2'
272
393
  gem 'opal-async', '~> 1.4.0'
273
394
  gem 'opal-jquery', '~> 0.4.4'
274
- gem 'glimmer-dsl-opal', '~> 0.28.0'
395
+ gem 'glimmer-dsl-opal', '~> 0.29.0'
275
396
  gem 'glimmer-dsl-xml', '~> 1.2.0', require: false
276
397
  gem 'glimmer-dsl-css', '~> 1.2.0', require: false
277
-
278
398
  ```
279
399
 
280
- Follow (opal-rails)[https://github.com/opal/opal-rails] instructions, basically the configuration of: config/initializers/assets.rb
400
+ Follow [opal-rails](https://github.com/opal/opal-rails) instructions, basically the configuration of: `config/initializers/assets.rb`
281
401
 
282
402
  Edit `config/initializers/assets.rb` and add the following at the bottom:
283
403
  ```
@@ -290,9 +410,16 @@ Run:
290
410
  rails g scaffold welcome
291
411
  ```
292
412
 
293
- Modify `config/routes.rb`:
413
+ Run:
414
+
415
+ ```
416
+ rails db:migrate
417
+ ```
418
+
419
+ Add the following to `config/routes.rb` inside the `Rails.application.routes.draw` block:
294
420
 
295
421
  ```ruby
422
+ mount Glimmer::Engine => "/glimmer" # add on top
296
423
  root to: 'welcomes#index'
297
424
  ```
298
425
 
@@ -302,14 +429,16 @@ Edit `app/views/layouts/application.html.erb` and add the following below other
302
429
  <%= stylesheet_link_tag 'glimmer/glimmer', media: 'all', 'data-turbolinks-track': 'reload' %>
303
430
  ```
304
431
 
305
- Clear the file `app/views/welcomes/index.html.erb` from any content.
432
+ Clear the file `app/views/welcomes/index.html.erb` completely from all content.
433
+
434
+ Delete `app/assets/javascripts/application.js`
306
435
 
307
- Add the following line to the top of an empty `app/assets/javascripts/application.rb` (replacing `application.js`), and add Glimmer GUI DSL code or a require statement for one of the samples below.
436
+ Create an empty `app/assets/javascripts/application.rb`, and add Glimmer GUI DSL code or a require statement for one of the [samples](#samples) below.
308
437
 
309
438
  ```ruby
310
439
  require 'glimmer-dsl-opal' # brings opal and other dependencies automatically
311
440
 
312
- # require-statement/code goes here.
441
+ # Add more require-statements or Glimmer GUI DSL code
313
442
  ```
314
443
 
315
444
  Example to confirm setup is working:
@@ -322,6 +451,7 @@ include Glimmer
322
451
  shell {
323
452
  fill_layout
324
453
  text 'Example to confirm setup is working'
454
+
325
455
  label {
326
456
  text "Welcome to Glimmer DSL for Opal!"
327
457
  foreground :red
@@ -330,6 +460,21 @@ shell {
330
460
  }.open
331
461
  ```
332
462
 
463
+ Start the Rails server:
464
+ ```
465
+ rails s
466
+ ```
467
+
468
+ Visit `http://localhost:3000`
469
+
470
+ You should see:
471
+
472
+ ![setup is working](/images/glimmer-dsl-opal-setup-example-working.png)
473
+
474
+ If you run into any issues in setup, refer to the [Sample Glimmer DSL for Opal Rails](https://github.com/AndyObtiva/sample-glimmer-dsl-opal-rails7-app) project (in case I forgot to include some setup steps by mistake).
475
+
476
+ Otherwise, if you still cannot setup successfully (even with the help of the sample project, or if the sample project stops working), please do not hesitate to report an [Issue request](https://github.com/AndyObtiva/glimmer-dsl-opal/issues) or fix and submit a [Pull Request](https://github.com/AndyObtiva/glimmer-dsl-opal/pulls).
477
+
333
478
  ## Supported Glimmer DSL Keywords
334
479
 
335
480
  The following keywords from [glimmer-dsl-swt](https://github.com/AndyObtiva/glimmer-dsl-swt) have fully functional partial support in Opal:
@@ -1463,7 +1608,7 @@ You should see "Hello, Group!"
1463
1608
 
1464
1609
  This is a minimal initial version of the [Hello, Canvas! sample included in Glimmer DSL for SWT](https://github.com/AndyObtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md#hello-canvas).
1465
1610
 
1466
- It supports all shapes except `arc`, with no shape nesting, data-binding, or gradient support yet.
1611
+ It [supports](#supported-glimmer-dsl-keywords) all shapes and attribute data-binding, but no shape nesting or gradient support yet.
1467
1612
 
1468
1613
  Add the following require statement to `app/assets/javascripts/application.rb`
1469
1614
 
@@ -2653,7 +2798,7 @@ Glimmer DSL for Opal Contact Manager Edit Done
2653
2798
 
2654
2799
  #### Tetris
2655
2800
 
2656
- This is a minimal initial version of the [Tetris seen in Glimmer DSL for SWT](https://github.com/AndyObtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md#glimmer-tetris).
2801
+ This is a slightly minimal version of the [Tetris seen in Glimmer DSL for SWT](https://github.com/AndyObtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md#glimmer-tetris).
2657
2802
 
2658
2803
  Note that while the Glimmer GUI DSL code is mostly the same, some of the behavioral code around threads is changed
2659
2804
  into async Opal code via the [opal-async](https://github.com/AndyObtiva/opal-async) gem due to the async nature of transpiled JavaScript.
@@ -2743,6 +2888,8 @@ You should see "User Profile"
2743
2888
 
2744
2889
  #### Weather
2745
2890
 
2891
+ This sample does everything the desktop sample does except for the Canvas Shape DSL rectangle decoration (until supported).
2892
+
2746
2893
  Code: [lib/glimmer-dsl-opal/samples/elaborate/weather](lib/glimmer-dsl-opal/samples/elaborate/weather.rb)
2747
2894
 
2748
2895
  Add the following require statement to `app/assets/javascripts/application.rb`
@@ -2868,7 +3015,7 @@ These features have been suggested. You might see them in a future version of Gl
2868
3015
 
2869
3016
  [MIT](https://opensource.org/licenses/MIT)
2870
3017
 
2871
- Copyright (c) 2020-2021 - Andy Maleh.
3018
+ Copyright (c) 2020-2022 - Andy Maleh.
2872
3019
  See [LICENSE.txt](LICENSE.txt) for further details.
2873
3020
 
2874
3021
  --
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.28.0
1
+ 0.29.0