Sha256: e78743f414b29d3cd49a13c71bc53627da8ced035be1ebcf5ce6b7fc8db64944
Contents?: true
Size: 808 Bytes
Versions: 1
Compression:
Stored size: 808 Bytes
Contents
require 'whirled_peas' class TemplateFactory def build(*) WhirledPeas.template do |composer| composer.add_grid do |composer, settings| settings.num_cols = 2 [nil, :left, :center, :right].each do |align| composer.add_box("Alignment-#{align || :default}") do |composer, settings| settings.flow = :t2b settings.full_border settings.align = align # Keep the title long so grids below will be wide enough to use the # alignment attribute. Don't rely on the `width` attribute to keep # `align` isolated in this test. composer.add_text('Title') { 'This is an aligned box' } composer.add_text('Content') { align || :default } end end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
whirled_peas-0.6.0 | screen_test/rendered/settings/align/box.rb |