Sha256: ff193924a0b39598f0e8c27357391b1651e6f3780b7950f06eebbd2677dd5abe
Contents?: true
Size: 588 Bytes
Versions: 5
Compression:
Stored size: 588 Bytes
Contents
require 'whirled_peas' class TemplateFactory def build(*) WhirledPeas.template do |composer| composer.add_grid('Alignment') do |composer, settings| settings.num_cols = 1 settings.full_border settings.align = :center # 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 grid' } composer.add_text('Content') { 'Center' } end end end end
Version data entries
5 entries across 5 versions & 1 rubygems