Class: Glimmer::SWT::GridLayoutProxy
- Inherits:
-
LayoutProxy
- Object
- LayoutProxy
- Glimmer::SWT::GridLayoutProxy
- Defined in:
- lib/glimmer/swt/grid_layout_proxy.rb
Constant Summary collapse
- STYLE =
<<~CSS .grid-layout { display: grid; grid-template-rows: min-content; place-content: start; align-items: stretch; } CSS
Instance Attribute Summary collapse
-
#horizontal_spacing ⇒ Object
Returns the value of attribute horizontal_spacing.
-
#make_columns_equal_width ⇒ Object
Returns the value of attribute make_columns_equal_width.
-
#margin_bottom ⇒ Object
Returns the value of attribute margin_bottom.
-
#margin_height ⇒ Object
Returns the value of attribute margin_height.
-
#margin_left ⇒ Object
Returns the value of attribute margin_left.
-
#margin_right ⇒ Object
Returns the value of attribute margin_right.
-
#margin_top ⇒ Object
Returns the value of attribute margin_top.
-
#margin_width ⇒ Object
Returns the value of attribute margin_width.
-
#num_columns ⇒ Object
Returns the value of attribute num_columns.
-
#vertical_spacing ⇒ Object
Returns the value of attribute vertical_spacing.
Attributes inherited from LayoutProxy
Instance Method Summary collapse
-
#initialize(parent, args) ⇒ GridLayoutProxy
constructor
A new instance of GridLayoutProxy.
Methods inherited from LayoutProxy
#css_class, #dom, for, layout_class, layout_exists?, #layout​
Methods included from PropertyOwner
#attribute_getter, #attribute_setter, #get_attribute, #set_attribute
Constructor Details
#initialize(parent, args) ⇒ GridLayoutProxy
Returns a new instance of GridLayoutProxy.
91 92 93 94 95 96 97 98 99 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 91 def initialize(parent, args) super(parent, args) self.horizontal_spacing = 10 self.vertical_spacing = 10 self.margin_width = 15 self.margin_height = 15 self.num_columns = @args[0] || 1 self.make_columns_equal_width = @args[1] || false end |
Instance Attribute Details
#horizontal_spacing ⇒ Object
Returns the value of attribute horizontal_spacing.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def horizontal_spacing @horizontal_spacing end |
#make_columns_equal_width ⇒ Object
Returns the value of attribute make_columns_equal_width.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def make_columns_equal_width @make_columns_equal_width end |
#margin_bottom ⇒ Object
Returns the value of attribute margin_bottom.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_bottom @margin_bottom end |
#margin_height ⇒ Object
Returns the value of attribute margin_height.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_height @margin_height end |
#margin_left ⇒ Object
Returns the value of attribute margin_left.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_left @margin_left end |
#margin_right ⇒ Object
Returns the value of attribute margin_right.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_right @margin_right end |
#margin_top ⇒ Object
Returns the value of attribute margin_top.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_top @margin_top end |
#margin_width ⇒ Object
Returns the value of attribute margin_width.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def margin_width @margin_width end |
#num_columns ⇒ Object
Returns the value of attribute num_columns.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def num_columns @num_columns end |
#vertical_spacing ⇒ Object
Returns the value of attribute vertical_spacing.
15 16 17 |
# File 'lib/glimmer/swt/grid_layout_proxy.rb', line 15 def vertical_spacing @vertical_spacing end |