Sha256: 3e9d73d986fe4da8afd823b3602187fbc32040f57674ee2d50df3b7bbeb49222

Contents?: true

Size: 1.08 KB

Versions: 1

Compression:

Stored size: 1.08 KB

Contents

require 'beryl/widget'

class Something < Beryl::Widget
  def render(state)
    column :fill_width, :fill_height do
      row :fill_width do
        column proportional_width: 2 do
          text 'ROW 1 COL 1'
        end
        column :fill_width do
          text 'ROW 1 COL 2'
        end
        column proportional_width: 2 do
          text 'ROW 1 COL 3'
        end
      end
      row :fill_width do
        column width: 200 do
          text 'ROW 2 COL 1'
        end
        column :fill_width, height: 50 do
          text 'ROW 2 COL 2'
        end
        column width: 300 do
          text 'ROW 2 COL 3'
        end
      end
      row :fill_width do
        column :fill_width do
          text 'ROW 3 COL 1'
        end
        column width: 400 do
          text 'ROW 3 COL 2'
        end
        column :fill_width do
          text 'ROW 3 COL 3'
        end
      end
    end
  end
end


# column :fill_width, :fill_height do
#   text 'Bart', height: 100, width: 300
#   text 'Abc', proportional_height: 2
#   text 'Karol', :fill_height
#   text 'Xyz', proportional_height: 3
# end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
beryl-0.2.5 app/something.rb