Module: Iup::DynamicFillMethods
Overview
Methods for containers where the child elements can be added after construction.
Instance Method Summary collapse
-
#append(child) ⇒ Object
Inserts an interface element at the end of the container, after the last element of the container.
-
#insert(ref_child, new_child) ⇒ Object
Inserts an interface element before another child of the container.
Instance Method Details
#append(child) ⇒ Object
Inserts an interface element at the end of the container, after the last element of the container. Valid for any element that contains other elements like dialog, frame, hbox, vbox, zbox or menu.
11 12 13 |
# File 'lib/wrapped/dynamic-fill-methods.rb', line 11 def append child IupLib.IupAppend @handle, child.handle end |
#insert(ref_child, new_child) ⇒ Object
Inserts an interface element before another child of the container. Valid for any element that contains other elements like dialog, frame, hbox, vbox, zbox, menu, etc.
18 19 20 21 22 23 24 |
# File 'lib/wrapped/dynamic-fill-methods.rb', line 18 def insert ref_child, new_child if ref_child.nil? IupLib.IupInsert @handle, nil, new_child.handle else IupLib.IupInsert @handle, ref_child.handle, new_child.handle end end |