Class: VRHorizLayoutFrame

Inherits:
VRLayoutFrame show all
Defined in:
lib/vr/vrlayout2.rb

Instance Method Summary collapse

Methods inherited from VRLayoutFrame

#initialize, #move, #register

Constructor Details

This class inherits a constructor from VRLayoutFrame

Instance Method Details

#_vr_relayoutObject

VRHorizLayoutFrame

This is a frame that lays out its controls horizontally.
Use ((|register|)) and ((|move|)) method of VRLayoutFrame


69
70
71
72
73
74
75
# File 'lib/vr/vrlayout2.rb', line 69

def _vr_relayout
  return if @_vr_layoutclients.size==0
  width = @_vr_lw.to_f / @_vr_layoutclients.size
  @_vr_layoutclients.each_index do |i|
    @_vr_layoutclients[i].move @_vr_lx+width*i, @_vr_ly,width,@_vr_lh
  end
end