glimmer-dsl-libui 0.2.9 → 0.2.13

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,6 @@
1
- # frozen_string_literal: true
2
-
3
1
  require 'glimmer-dsl-libui'
4
2
  require 'facets'
3
+ require 'fileutils'
5
4
 
6
5
  class MetaExample
7
6
  include Glimmer
@@ -42,6 +41,19 @@ class MetaExample
42
41
  examples[@selected_example_index]
43
42
  end
44
43
 
44
+ def run_example(example)
45
+ command = "ruby -r #{glimmer_dsl_libui_file} #{example} 2>&1"
46
+ result = ''
47
+ IO.popen(command) do |f|
48
+ f.each_line do |line|
49
+ result << line
50
+ puts line
51
+ $stdout.flush # for Windows
52
+ end
53
+ end
54
+ msg_box('Error Running Example', result) if result.downcase.include?('error')
55
+ end
56
+
45
57
  def launch
46
58
  window('Meta-Example', 700, 500) {
47
59
  margined true
@@ -50,16 +62,16 @@ class MetaExample
50
62
  vertical_box {
51
63
  stretchy false
52
64
 
53
- @rbs = radio_buttons {
65
+ @example_radio_buttons = radio_buttons {
54
66
  stretchy false
55
67
  items examples_with_versions
56
68
  selected @selected_example_index
57
69
 
58
70
  on_selected do
59
- @selected_example_index = @rbs.selected
71
+ @selected_example_index = @example_radio_buttons.selected
60
72
  example = selected_example
61
- @nwme.text = File.read(file_path_for(example))
62
- @sb.value = 1
73
+ @code_entry.text = File.read(file_path_for(example))
74
+ @version_spinbox.value = 1
63
75
  end
64
76
  }
65
77
 
@@ -68,17 +80,17 @@ class MetaExample
68
80
  stretchy false
69
81
  }
70
82
 
71
- @sb = spinbox(1, 100) {
83
+ @version_spinbox = spinbox(1, 100) {
72
84
  value 1
73
85
 
74
86
  on_changed do
75
87
  example = selected_example
76
- if @sb.value > version_count_for(example)
77
- @sb.value -= 1
88
+ if @version_spinbox.value > version_count_for(example)
89
+ @version_spinbox.value -= 1
78
90
  else
79
- version_number = @sb.value == 1 ? '' : @sb.value
91
+ version_number = @version_spinbox.value == 1 ? '' : @version_spinbox.value
80
92
  example = "#{selected_example}#{version_number}"
81
- @nwme.text = File.read(file_path_for(example))
93
+ @code_entry.text = File.read(file_path_for(example))
82
94
  end
83
95
  end
84
96
  }
@@ -90,25 +102,29 @@ class MetaExample
90
102
  button('Launch') {
91
103
  on_clicked do
92
104
  begin
93
- meta_example_file = File.join(Dir.home, '.meta_example.rb')
94
- File.write(meta_example_file, @nwme.text)
95
- result = `ruby -r #{glimmer_dsl_libui_file} #{meta_example_file} 2>&1`
96
- msg_box('Error Running Example', result) if result.include?('error')
105
+ parent_dir = File.join(Dir.home, '.glimmer-dsl-libui', 'examples')
106
+ FileUtils.mkdir_p(parent_dir)
107
+ example_file = File.join(parent_dir, "#{selected_example.underscore}.rb")
108
+ File.write(example_file, @code_entry.text)
109
+ FileUtils.cp_r(File.expand_path('../icons', __dir__), File.dirname(parent_dir))
110
+ FileUtils.cp_r(File.expand_path('../sounds', __dir__), File.dirname(parent_dir))
111
+ run_example(example_file)
97
112
  rescue => e
113
+ puts e.full_message
98
114
  puts 'Unable to write code changes! Running original example...'
99
- system "ruby -r #{glimmer_dsl_libui_file} #{file_path_for(selected_example)}"
115
+ run_example(file_path_for(selected_example))
100
116
  end
101
117
  end
102
118
  }
103
119
  button('Reset') {
104
120
  on_clicked do
105
- @nwme.text = File.read(file_path_for(selected_example))
121
+ @code_entry.text = File.read(file_path_for(selected_example))
106
122
  end
107
123
  }
108
124
  }
109
125
  }
110
126
 
111
- @nwme = non_wrapping_multiline_entry {
127
+ @code_entry = non_wrapping_multiline_entry {
112
128
  text File.read(file_path_for(selected_example))
113
129
  }
114
130
  }
@@ -0,0 +1,97 @@
1
+ require 'glimmer-dsl-libui'
2
+ require 'facets'
3
+
4
+ include Glimmer
5
+
6
+ Address = Struct.new(:street, :p_o_box, :city, :state, :zip_code)
7
+
8
+ def form_field(model, property)
9
+ property = property.to_s
10
+ entry { |e|
11
+ label property.underscore.split('_').map(&:capitalize).join(' ')
12
+ text model.send(property).to_s
13
+
14
+ on_changed do
15
+ model.send("#{property}=", e.text)
16
+ end
17
+ }
18
+ end
19
+
20
+ def address_form(address)
21
+ form {
22
+ form_field(address, :street)
23
+ form_field(address, :p_o_box)
24
+ form_field(address, :city)
25
+ form_field(address, :state)
26
+ form_field(address, :zip_code)
27
+ }
28
+ end
29
+
30
+ def label_pair(model, attribute, value)
31
+ name_label = nil
32
+ value_label = nil
33
+ horizontal_box {
34
+ name_label = label(attribute.to_s.underscore.split('_').map(&:capitalize).join(' '))
35
+ value_label = label(value.to_s)
36
+ }
37
+ Glimmer::DataBinding::Observer.proc do
38
+ value_label.text = model.send(attribute)
39
+ end.observe(model, attribute)
40
+ end
41
+
42
+ def address(address)
43
+ vertical_box {
44
+ address.each_pair do |attribute, value|
45
+ label_pair(address, attribute, value)
46
+ end
47
+ }
48
+ end
49
+
50
+ address1 = Address.new('123 Main St', '23923', 'Denver', 'Colorado', '80014')
51
+ address2 = Address.new('2038 Park Ave', '83272', 'Boston', 'Massachusetts', '02101')
52
+
53
+ window('Method-Based Custom Keyword') {
54
+ margined true
55
+
56
+ horizontal_box {
57
+ vertical_box {
58
+ label('Address 1') {
59
+ stretchy false
60
+ }
61
+
62
+ address_form(address1)
63
+
64
+ horizontal_separator {
65
+ stretchy false
66
+ }
67
+
68
+ label('Address 1 (Saved)') {
69
+ stretchy false
70
+ }
71
+
72
+ address(address1)
73
+ }
74
+
75
+ vertical_separator {
76
+ stretchy false
77
+ }
78
+
79
+ vertical_box {
80
+ label('Address 2') {
81
+ stretchy false
82
+ }
83
+
84
+ address_form(address2)
85
+
86
+ horizontal_separator {
87
+ stretchy false
88
+ }
89
+
90
+ label('Address 2 (Saved)') {
91
+ stretchy false
92
+ }
93
+
94
+ address(address2)
95
+ }
96
+ }
97
+ }.show
Binary file
@@ -32,11 +32,18 @@ module Glimmer
32
32
 
33
33
  def can_interpret?(parent, keyword, *args, &block)
34
34
  super and
35
- parent.is_a?(Glimmer::LibUI::ControlProxy::TextProxy)
35
+ (
36
+ parent.is_a?(Glimmer::LibUI::ControlProxy::TextProxy) or
37
+ parent.is_a?(Glimmer::LibUI::AttributedString)
38
+ )
36
39
  end
37
40
 
38
41
  def interpret(parent, keyword, *args, &block)
39
- Glimmer::LibUI::AttributedString.new(keyword, parent, args, &block)
42
+ if parent.is_a?(Glimmer::LibUI::ControlProxy::TextProxy)
43
+ Glimmer::LibUI::AttributedString.new(keyword, parent, args, &block)
44
+ else
45
+ parent.string = args.join
46
+ end
40
47
  end
41
48
 
42
49
  def add_content(parent, keyword, *args, &block)
@@ -27,7 +27,6 @@ require 'glimmer/libui/control_proxy/transformable'
27
27
  module Glimmer
28
28
  module LibUI
29
29
  class AttributedString
30
- attr_accessor :string
31
30
  attr_reader :block, :keyword, :parent_proxy, :args
32
31
 
33
32
  def initialize(keyword, parent_proxy, args, &block)
@@ -39,6 +38,17 @@ module Glimmer
39
38
  post_add_content if @block.nil?
40
39
  end
41
40
 
41
+ def string(value = nil)
42
+ if value.nil?
43
+ @string
44
+ else
45
+ @string = value
46
+ redraw
47
+ end
48
+ end
49
+ alias string= string
50
+ alias set_string string
51
+
42
52
  def font(value = nil)
43
53
  if value.nil?
44
54
  @font
@@ -106,7 +116,7 @@ module Glimmer
106
116
  alias set_open_type_features open_type_features
107
117
 
108
118
  def post_add_content
109
- block_result = block&.call
119
+ block_result = @block&.call
110
120
  @string = block_result if block_result.is_a?(String)
111
121
  @parent_proxy&.post_initialize_child(self)
112
122
  end
@@ -141,16 +151,26 @@ module Glimmer
141
151
  end
142
152
  end
143
153
  unless font.nil?
144
- family_attribute = ::LibUI.new_family_attribute(font[:family])
145
- ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, family_attribute, @start, @start + @string.size)
146
- size_attribute = ::LibUI.new_size_attribute(font[:size])
147
- ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, size_attribute, @start, @start + @string.size)
148
- weight_attribute = ::LibUI.new_weight_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_weight, font[:weight]))
149
- ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, weight_attribute, @start, @start + @string.size)
150
- italic_attribute = ::LibUI.new_italic_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_italic, font[:italic]))
151
- ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, italic_attribute, @start, @start + @string.size)
152
- stretch_attribute = ::LibUI.new_stretch_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_stretch, font[:stretch]))
153
- ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, stretch_attribute, @start, @start + @string.size)
154
+ if font[:family]
155
+ family_attribute = ::LibUI.new_family_attribute(font[:family])
156
+ ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, family_attribute, @start, @start + @string.size)
157
+ end
158
+ if font[:size]
159
+ size_attribute = ::LibUI.new_size_attribute(font[:size])
160
+ ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, size_attribute, @start, @start + @string.size)
161
+ end
162
+ if font[:weight]
163
+ weight_attribute = ::LibUI.new_weight_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_weight, font[:weight]))
164
+ ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, weight_attribute, @start, @start + @string.size)
165
+ end
166
+ if font[:italic]
167
+ italic_attribute = ::LibUI.new_italic_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_italic, font[:italic]))
168
+ ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, italic_attribute, @start, @start + @string.size)
169
+ end
170
+ if font[:stretch]
171
+ stretch_attribute = ::LibUI.new_stretch_attribute(Glimmer::LibUI.enum_symbol_to_value(:text_stretch, font[:stretch]))
172
+ ::LibUI.attributed_string_set_attribute(@parent_proxy.attributed_string, stretch_attribute, @start, @start + @string.size)
173
+ end
154
174
  end
155
175
  unless open_type_features.nil?
156
176
  open_type_features_attribute = ::LibUI.new_features_attribute(open_type_features.libui)
@@ -69,7 +69,6 @@ module Glimmer
69
69
  @fill ||= {}
70
70
  else
71
71
  @fill = Glimmer::LibUI.interpret_color(args)
72
- @fill[:a] = 1.0 if @fill.is_a?(Hash) && @fill[:a].nil?
73
72
  @parent_proxy&.queue_redraw_all
74
73
  end
75
74
  @fill.tap do
@@ -94,7 +93,6 @@ module Glimmer
94
93
  @stroke ||= {}
95
94
  else
96
95
  @stroke = Glimmer::LibUI.interpret_color(args)
97
- @stroke[:a] = 1.0 if @stroke.is_a?(Hash) && @stroke[:a].nil?
98
96
  @parent_proxy&.queue_redraw_all
99
97
  end
100
98
  @stroke.tap do
@@ -149,11 +147,38 @@ module Glimmer
149
147
  end
150
148
 
151
149
  def init_draw_brush(draw_brush, draw_brush_args)
150
+ if draw_brush_args[:r] || draw_brush_args[:g] || draw_brush_args[:b] || draw_brush_args[:a]
151
+ draw_brush_args[:type] ||= :solid
152
+ elsif draw_brush_args[:outer_radius]
153
+ draw_brush_args[:type] ||= :radial_gradient
154
+ else
155
+ draw_brush_args[:type] ||= :linear_gradient
156
+ end
152
157
  draw_brush.Type = Glimmer::LibUI.enum_symbol_to_value(:draw_brush_type, draw_brush_args[:type])
153
- draw_brush.R = (draw_brush_args[:r] || draw_brush_args[:red]).to_f / 255.0
154
- draw_brush.G = (draw_brush_args[:g] || draw_brush_args[:green]).to_f / 255.0
155
- draw_brush.B = (draw_brush_args[:b] || draw_brush_args[:blue]).to_f / 255.0
156
- draw_brush.A = (draw_brush_args[:a] || draw_brush_args[:alpha])
158
+ if draw_brush.Type == 0
159
+ draw_brush.R = (draw_brush_args[:r] || draw_brush_args[:red]).to_f / 255.0
160
+ draw_brush.G = (draw_brush_args[:g] || draw_brush_args[:green]).to_f / 255.0
161
+ draw_brush.B = (draw_brush_args[:b] || draw_brush_args[:blue]).to_f / 255.0
162
+ draw_brush.A = (draw_brush_args[:a] || draw_brush_args[:alpha] || 1.0)
163
+ else
164
+ draw_brush.X0 = draw_brush_args[:x0].to_f
165
+ draw_brush.Y0 = draw_brush_args[:y0].to_f
166
+ draw_brush.X1 = draw_brush_args[:x1].to_f
167
+ draw_brush.Y1 = draw_brush_args[:y1].to_f
168
+ draw_brush.OuterRadius = draw_brush_args[:outer_radius].to_f if draw_brush.Type == 2
169
+ stop_structs = draw_brush_args[:stops].to_a.map do |stop|
170
+ ::LibUI::FFI::DrawBrushGradientStop.malloc.tap do |stop_struct|
171
+ stop_struct.Pos = stop[:pos].to_f
172
+ stop_color = Glimmer::LibUI.interpret_color(stop)
173
+ stop_struct.R = stop_color[:r].to_f / 255.0
174
+ stop_struct.G = stop_color[:g].to_f / 255.0
175
+ stop_struct.B = stop_color[:b].to_f / 255.0
176
+ stop_struct.A = stop_color[:a] || 1.0
177
+ end
178
+ end
179
+ draw_brush.NumStops = stop_structs.count
180
+ draw_brush.Stops = stop_structs.map(&:to_ptr).map(&:to_s).reduce(:+)
181
+ end
157
182
  end
158
183
  end
159
184
  end
@@ -84,7 +84,7 @@ module Glimmer
84
84
  @cell_rows = rows
85
85
  @cell_rows.tap do
86
86
  @last_cell_rows = array_deep_clone(@cell_rows)
87
- Glimmer::DataBinding::Observer.proc do
87
+ Glimmer::DataBinding::Observer.proc do |new_cell_rows|
88
88
  if @cell_rows.size < @last_cell_rows.size && @last_cell_rows.include_all?(*@cell_rows)
89
89
  @last_cell_rows.array_diff_indexes(@cell_rows).reverse.each do |row|
90
90
  ::LibUI.table_model_row_deleted(model, row)
@@ -103,8 +103,9 @@ module Glimmer
103
103
  end
104
104
  end
105
105
  end
106
+ @last_last_cell_rows = array_deep_clone(@last_cell_rows)
106
107
  @last_cell_rows = array_deep_clone(@cell_rows)
107
- end.observe(self, :cell_rows)
108
+ end.observe(self, :cell_rows, recursive: true)
108
109
  end
109
110
  end
110
111
  end
@@ -112,7 +113,11 @@ module Glimmer
112
113
  alias set_cell_rows cell_rows
113
114
 
114
115
  def expanded_cell_rows
115
- cell_rows.map do |row|
116
+ expand(cell_rows)
117
+ end
118
+
119
+ def expand(cell_rows)
120
+ cell_rows.to_a.map do |row|
116
121
  row.flatten(1)
117
122
  end
118
123
  end
@@ -146,23 +151,39 @@ module Glimmer
146
151
  3
147
152
  end
148
153
  end
149
- @model_handler.NumRows = fiddle_closure_block_caller(4) { cell_rows.count }
154
+ @model_handler.NumRows = fiddle_closure_block_caller(4) do
155
+ # Note: there is a double-delete bug in Windows when performing table_model_row_deleted, which requires pre-adding and extra empty row
156
+ cell_rows.count + (OS.windows? ? 1 : 0)
157
+ end
150
158
  @model_handler.CellValue = fiddle_closure_block_caller(1, [1, 1, 4, 4]) do |_, _, row, column|
151
159
  the_cell_rows = expanded_cell_rows
152
160
  case @columns[column]
153
161
  when Column::TextColumnProxy, Column::ButtonColumnProxy, Column::TextColorColumnProxy, :text
154
162
  ::LibUI.new_table_value_string((expanded_cell_rows[row] && expanded_cell_rows[row][column]).to_s)
155
163
  when Column::ImageColumnProxy, Column::ImageTextColumnProxy, Column::ImageTextColorColumnProxy
156
- ::LibUI.new_table_value_image((expanded_cell_rows[row] && (expanded_cell_rows[row][column].respond_to?(:libui) ? expanded_cell_rows[row][column].libui : expanded_cell_rows[row][column])))
164
+ if OS.windows? && row == cell_rows.count
165
+ ::LibUI.new_table_value_image((expanded_cell_rows[row - 1] && (expanded_cell_rows[row - 1][column].respond_to?(:libui) ? expanded_cell_rows[row - 1][column].libui : expanded_cell_rows[row - 1][column])))
166
+ else
167
+ ::LibUI.new_table_value_image((expanded_cell_rows[row] && (expanded_cell_rows[row][column].respond_to?(:libui) ? expanded_cell_rows[row][column].libui : expanded_cell_rows[row][column])))
168
+ end
157
169
  when Column::CheckboxColumnProxy, Column::CheckboxTextColumnProxy, Column::CheckboxTextColorColumnProxy
158
- ::LibUI.new_table_value_int((expanded_cell_rows[row] && (expanded_cell_rows[row][column] == 1 || expanded_cell_rows[row][column].to_s.strip.downcase == 'true' ? 1 : 0)))
170
+ ::LibUI.new_table_value_int(((expanded_cell_rows[row] && (expanded_cell_rows[row][column] == 1 || expanded_cell_rows[row][column].to_s.strip.downcase == 'true' ? 1 : 0))) || 0)
159
171
  when Column::ProgressBarColumnProxy
160
- ::LibUI.new_table_value_int((expanded_cell_rows[row] && (expanded_cell_rows[row][column].to_i)))
172
+ value = (expanded_cell_rows[row] && expanded_cell_rows[row][column]).to_i
173
+ expanded_last_last_cell_rows = expand(@last_last_cell_rows)
174
+ old_value = (expanded_last_last_cell_rows[row] && expanded_last_last_cell_rows[row][column]).to_i
175
+ if OS.windows? && old_value == -1 && value >= 0
176
+ Glimmer::Config.logger.error('Switching a progress bar value from -1 to a positive value is not supported on Windows')
177
+ cell_rows[row][column] = -1
178
+ ::LibUI.new_table_value_int(old_value)
179
+ else
180
+ ::LibUI.new_table_value_int((expanded_cell_rows[row] && expanded_cell_rows[row][column]).to_i)
181
+ end
161
182
  when Column::BackgroundColorColumnProxy
162
- background_color = Glimmer::LibUI.interpret_color(expanded_cell_rows[row] && expanded_cell_rows[row][column])
183
+ background_color = Glimmer::LibUI.interpret_color(expanded_cell_rows[row] && expanded_cell_rows[row][column]) || {r: 255, g: 255, b: 255}
163
184
  ::LibUI.new_table_value_color(background_color[:r] / 255.0, background_color[:g] / 255.0, background_color[:b] / 255.0, background_color[:a] || 1.0)
164
185
  when :color
165
- color = Glimmer::LibUI.interpret_color(expanded_cell_rows[row] && expanded_cell_rows[row][column])
186
+ color = Glimmer::LibUI.interpret_color(expanded_cell_rows[row] && expanded_cell_rows[row][column]) || {r: 0, g: 0, b: 0}
166
187
  ::LibUI.new_table_value_color(color[:r] / 255.0, color[:g] / 255.0, color[:b] / 255.0, color[:a] || 1.0)
167
188
  end
168
189
  end
@@ -182,7 +203,6 @@ module Glimmer
182
203
  @cell_rows[row] ||= []
183
204
  @cell_rows[row][column] = ::LibUI.table_value_int(val).to_i == 1
184
205
  end
185
- on_changed.each {|listener| listener.call(row, :changed, @cell_rows[row])}
186
206
  on_edited.each {|listener| listener.call(row, @cell_rows[row])}
187
207
  end
188
208
 
data/lib/glimmer/libui.rb CHANGED
@@ -44,8 +44,8 @@ module Glimmer
44
44
  value = value[0...-1]
45
45
  end
46
46
  value = value.first if value.is_a?(Array) && value.size == 1
47
- value = value.to_s if value.is_a?(Symbol)
48
47
  value = value[:color] if value.is_a?(Hash) && value[:color]
48
+ value = value.to_s if value.is_a?(Symbol)
49
49
  result = if value.is_a?(Array)
50
50
  old_value = value
51
51
  value = {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glimmer-dsl-libui
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.9
4
+ version: 0.2.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andy Maleh
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-10-07 00:00:00.000000000 Z
11
+ date: 2021-10-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: glimmer
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 2.3.0
19
+ version: 2.4.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 2.3.0
26
+ version: 2.4.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: os
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -64,14 +64,14 @@ dependencies:
64
64
  requirements:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: 0.0.11
67
+ version: 0.0.12
68
68
  type: :runtime
69
69
  prerelease: false
70
70
  version_requirements: !ruby/object:Gem::Requirement
71
71
  requirements:
72
72
  - - "~>"
73
73
  - !ruby/object:Gem::Version
74
- version: 0.0.11
74
+ version: 0.0.12
75
75
  - !ruby/object:Gem::Dependency
76
76
  name: juwelier
77
77
  requirement: !ruby/object:Gem::Requirement
@@ -192,7 +192,10 @@ dependencies:
192
192
  version: 1.4.0
193
193
  description: Glimmer DSL for LibUI - Prerequisite-Free Ruby Desktop Development GUI
194
194
  Library (No need to pre-install any prerequisites. Just install the gem and have
195
- platform-independent native GUI that just works!)
195
+ platform-independent native GUI that just works! Glimmer DSL for LibUI aims to provide
196
+ declarative DSL syntax that visually maps to GUI control hierarchy, convention over
197
+ configuration via smart defaults, automation of low-level details, requiring the
198
+ least amount of syntax possible to build GUI, and custom control support.
196
199
  email: andy.am@gmail.com
197
200
  executables:
198
201
  - girb
@@ -230,7 +233,7 @@ files:
230
233
  - examples/basic_window.rb
231
234
  - examples/basic_window2.rb
232
235
  - examples/color_button.rb
233
- - examples/color_the_circles.rb
236
+ - examples/color_the_shapes.rb
234
237
  - examples/control_gallery.rb
235
238
  - examples/custom_draw_text.rb
236
239
  - examples/custom_draw_text2.rb
@@ -246,6 +249,7 @@ files:
246
249
  - examples/histogram.rb
247
250
  - examples/login.rb
248
251
  - examples/meta_example.rb
252
+ - examples/method_based_custom_keyword.rb
249
253
  - examples/midi_player.rb
250
254
  - examples/simple_notepad.rb
251
255
  - examples/timer.rb
@@ -363,7 +367,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
363
367
  - !ruby/object:Gem::Version
364
368
  version: '0'
365
369
  requirements: []
366
- rubygems_version: 3.2.28
370
+ rubygems_version: 3.2.22
367
371
  signing_key:
368
372
  specification_version: 4
369
373
  summary: Glimmer DSL for LibUI