Module: VER::TilingLayout::VerticalTiling
- Extended by:
- CommonTiling
- Defined in:
- lib/ver/layout/tiling/vertical.rb
Constant Summary
CommonTiling::DEFAULT
Class Method Summary
collapse
apply, apply_hidden, evolve, prepare
Class Method Details
.apply_masters(windows, center, step = 1.0 / windows.size) ⇒ Object
8
9
10
11
12
13
|
# File 'lib/ver/layout/tiling/vertical.rb', line 8
def apply_masters(windows, center, step = 1.0 / windows.size)
windows.each_with_index do |window, idx|
evolve(window, relx: 0.0, rely: (step * idx),
relheight: step, relwidth: center)
end
end
|
.apply_stacked(windows, center, step = 1.0 / windows.size) ⇒ Object
15
16
17
18
19
20
21
22
|
# File 'lib/ver/layout/tiling/vertical.rb', line 15
def apply_stacked(windows, center, step = 1.0 / windows.size)
relwidth = 1.0 - center
windows.each_with_index do |window, idx|
evolve(window, relx: center, rely: (step * idx),
relheight: step, relwidth: relwidth)
end
end
|