142 |
my $span = 1; |
my $span = 1; |
143 |
my $col_span = $current_column->get_attribute_ns (undef, 'span'); |
my $col_span = $current_column->get_attribute_ns (undef, 'span'); |
144 |
## Parse non-negative integer |
## Parse non-negative integer |
145 |
if (defined $col_span and $col_span =~ /^[\x09-\x0D\x20]*([0-9]+)/) { |
if (defined $col_span and |
146 |
|
$col_span =~ /^[\x09\x0A\x0C\x0D\x20]*([0-9]+)/) { |
147 |
$span = $1 || 1; |
$span = $1 || 1; |
148 |
} |
} |
149 |
|
|
162 |
my $span = 1; |
my $span = 1; |
163 |
my $col_span = $current_element->get_attribute_ns (undef, 'span'); |
my $col_span = $current_element->get_attribute_ns (undef, 'span'); |
164 |
## Parse non-negative integer |
## Parse non-negative integer |
165 |
if (defined $col_span and $col_span =~ /^[\x09-\x0D\x20]*([0-9]+)/) { |
if (defined $col_span and |
166 |
|
$col_span =~ /^[\x09\x0A\x0C\x0D\x20]*([0-9]+)/) { |
167 |
$span = $1 || 1; |
$span = $1 || 1; |
168 |
} |
} |
169 |
|
|
257 |
## Step 8 |
## Step 8 |
258 |
my $colspan = 1; |
my $colspan = 1; |
259 |
my $attr_value = $current_cell->get_attribute_ns (undef, 'colspan'); |
my $attr_value = $current_cell->get_attribute_ns (undef, 'colspan'); |
260 |
if (defined $attr_value and $attr_value =~ /^[\x09-\x0D\x20]*([0-9]+)/) { |
if (defined $attr_value |
261 |
|
and $attr_value =~ /^[\x09\x0A\x0C\x0D\x20]*([0-9]+)/) { |
262 |
$colspan = $1 || 1; |
$colspan = $1 || 1; |
263 |
} |
} |
264 |
|
|
265 |
## Step 9 |
## Step 9 |
266 |
my $rowspan = 1; |
my $rowspan = 1; |
267 |
my $attr_value = $current_cell->get_attribute_ns (undef, 'rowspan'); |
my $attr_value = $current_cell->get_attribute_ns (undef, 'rowspan'); |
268 |
if (defined $attr_value and $attr_value =~ /^[\x09-\x0D\x20]*([0-9]+)/) { |
if (defined $attr_value and |
269 |
|
$attr_value =~ /^[\x09\x0A\x0C\x0D\x20]*([0-9]+)/) { |
270 |
$rowspan = $1; |
$rowspan = $1; |
271 |
} |
} |
272 |
|
|
628 |
} |
} |
629 |
|
|
630 |
for my $headers_cell (@headers_cell) { |
for my $headers_cell (@headers_cell) { |
631 |
my @headers = split /[\x09-\x0D\x20]+/, |
my @headers = split /[\x09\x0A\x0C\x0D\x20]+/, |
632 |
$headers_cell->{element}->get_attribute_ns (undef, 'headers'); |
$headers_cell->{element}->get_attribute_ns (undef, 'headers'); |
633 |
my %headers; |
my %headers; |
634 |
for my $header_id (@headers) { |
for my $header_id (@headers) { |