Commit 5fdd5d97 by liyijie

adjust line height of export xlsx

parent bc77df7b
...@@ -80,10 +80,10 @@ module TalltyImportExport ...@@ -80,10 +80,10 @@ module TalltyImportExport
if respond_to?(:first_header) if respond_to?(:first_header)
row_index = Axlsx.col_ref(headers.size - 1) row_index = Axlsx.col_ref(headers.size - 1)
sheet.merge_cells("A1:#{row_index}1") sheet.merge_cells("A1:#{row_index}1")
sheet.add_row [first_header], style: title1, height: 40 sheet.add_row [first_header], style: title1, height: 30
end end
sheet.add_row headers.map{|header| header[:name]}, style: title2, height: 39 sheet.add_row headers.map{|header| header[:name]}, style: title2, height: 25
last_row = nil last_row = nil
merge_column_hash = {} merge_column_hash = {}
...@@ -126,7 +126,7 @@ module TalltyImportExport ...@@ -126,7 +126,7 @@ module TalltyImportExport
def process_options options = {} def process_options options = {}
options = options.with_indifferent_access options = options.with_indifferent_access
@row_height ||= options.delete(:row_height) || 35 @row_height ||= options.delete(:row_height) || 25
@width ||= (options.delete(:width) || 20).to_f @width ||= (options.delete(:width) || 20).to_f
@filename ||= options.delete(:filename) @filename ||= options.delete(:filename)
@group_by ||= options.delete(:group_by) @group_by ||= options.delete(:group_by)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment