Class: Interphase::Fixed
- Defined in:
- lib/interphase/widgets/fixed.rb
Overview
A container in which items can be placed in a specific x/y location.
Instance Attribute Summary
Attributes inherited from Container
Attributes inherited from Widget
Instance Method Summary collapse
-
#add(child, x_pos, y_pos, &block) ⇒ Object
Add a child widget to this
Fixed
at a location. -
#initialize(**options, &block) ⇒ Fixed
constructor
Construct a new fixed container.
Methods inherited from Container
#method_missing, #respond_to_missing?, #show_all
Methods inherited from Widget
#destroy, #method_missing, #on, #respond_to_missing?, #show, #size
Constructor Details
#initialize(**options, &block) ⇒ Fixed
Construct a new fixed container.
9 10 11 |
# File 'lib/interphase/widgets/fixed.rb', line 9 def initialize(**, &block) super(Gtk::Fixed.new, **, &block) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Interphase::Container
Instance Method Details
#add(child, x_pos, y_pos, &block) ⇒ Object
Add a child widget to this Fixed
at a location.
child
-
The new child widget.
x_pos
-
The x position.
y_pos
-
The y position.
17 18 19 20 21 |
# File 'lib/interphase/widgets/fixed.rb', line 17 def add(child, x_pos, y_pos, &block) gtk_instance.put(child.gtk_instance, x_pos, y_pos) super(child, false, &block) end |