128
129
130
131
132
133
134
|
# File 'lib/crayfish/html.rb', line 128
def style cell,node,scope
cell[:colspan] = node.attributes['colspan'].value.to_i if node.attributes['colspan']
cell[:rowspan] = node.attributes['rowspan'].value.to_i if node.attributes['rowspan']
cell[:valign] = :center if cell[:rowspan]
cell[:align] = node.attributes['align'].value.to_sym if node.attributes['align']
scope[:table_styles] << { :row => scope[:table].size, :col => scope[:tr].size, :style => node.attributes['style'].value } if node.attributes['style']
end
|