class Iup::SplitBox
A container for two child widgets, with a moveable divider between them.
Note: named IupSplit in Tecgrafâs documentation.
Example
The following code creates a split box between two text areas, with a blue divider oriented horizontally - so the text areas are placed one above the other:
split = Iup::SplitBox.new(text1, text2) do |b| b.orientation = 'HORIZONTAL' b.color = '127 127 255' end
Also see: StretchBox
Attributes
If set, hides a child if the child client area is smaller than the bar size. Values âyesâ / ânoâ.
Controls the size of the bar handler, defaults to 5.
Color of the bar grip, as âr g bâ.
Allows container to fill available space in indicated direction. Values ânoâ / âhorizontalâ / âverticalâ / âyesâ.
Updates the childrenâs layout when bar moved automatically. Values âyesâ / ânoâ.
minimum/maximum values for value in form âmin:maxâ, where min and max are integers.
Bar handler can be either âhorizontalâ or âverticalâ.
returns position in pixels within client window as âx,yâ.
Size of the container, in pixels, value as âwidthxheightâ.
If set, shows the bar grip. Values âyesâ / ânoâ.
Proportion of the left/top area relative to whole, integer in range [0,1000].
Public Class Methods
Source
# File lib/wrapped/splitbox.rb, line 30 def initialize child1, child2 @handle = IupLib.IupSplit(child1.handle, child2.handle) # run any provided block on instance, to set up further attributes yield self if block_given? end
Creates an instance of the split box. If a block is given, the new instance is yielded to it.
-
child1- the left or top child widget -
child2- the right or bottom child widget
Callbacks
Attributes
Callback called after the value was interactively changed by the user. Callback must respond to call and take no arguments.