diff options
author | Carlos Goce <carlosgoce@gmail.com> | 2015-01-23 21:27:49 +0100 |
---|---|---|
committer | Carlos Goce <carlosgoce@gmail.com> | 2015-01-23 21:27:49 +0100 |
commit | 6ab00a2f4434d462a54e8169103e898646930e65 (patch) | |
tree | b1e3ac0557b7e4726763cd4925bd230ab6f9832b /lib/carlosgoce | |
parent | 34a92a99a6956dcd97dfe417f68c436fceffc676 (diff) | |
download | pdf-calendars-6ab00a2f4434d462a54e8169103e898646930e65.tar.gz pdf-calendars-6ab00a2f4434d462a54e8169103e898646930e65.tar.bz2 pdf-calendars-6ab00a2f4434d462a54e8169103e898646930e65.zip |
Add styles to table
Diffstat (limited to 'lib/carlosgoce')
-rw-r--r-- | lib/carlosgoce/layout/layouts.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/carlosgoce/layout/layouts.rb b/lib/carlosgoce/layout/layouts.rb index e9c1ce8..f9594ca 100644 --- a/lib/carlosgoce/layout/layouts.rb +++ b/lib/carlosgoce/layout/layouts.rb @@ -9,13 +9,14 @@ module CarlosGoce tables = [] Prawn::Document.generate(file) do + font_size = 16 + data.each do |k, month| days = data[k][:days] - - # text data[k][:name] cells = (days).to_a.each_slice(7).to_a + cells.unshift [data[k][:name]] - tables << make_table(cells, :cell_style => {:align => :center}) + tables << make_table(cells, cell_style: {align: :center, size: 7, border_width: 0}) end table( |