git.shiar.nl
/
sheet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
latin: single cell for identical i/j columns
[sheet.git]
/
latin.plp
diff --git
a/latin.plp
b/latin.plp
index 4326f550f8cb6d26f2224bb7e71000579f1acbe9..671d6d7603bc206186d79a7f8846034eff472d59 100644
(file)
--- a/
latin.plp
+++ b/
latin.plp
@@
-67,7
+67,20
@@
else {
my ($title, $cells) = @{$row};
printf '<tr id="%s">', (lc $title) =~ s/<[^>]+>//gr =~ s/\s+/-/gr;
say '<th>', $title;
my ($title, $cells) = @{$row};
printf '<tr id="%s">', (lc $title) =~ s/<[^>]+>//gr =~ s/\s+/-/gr;
say '<th>', $title;
- say "\t", '<td>' x !/^<td/, $_ for @{$cells};
+ my $colspan = 1;
+ for (@{$cells}) {
+ if ($_ eq '>') {
+ $colspan++;
+ next;
+ }
+ print "\t<td";
+ if ($colspan > 1) {
+ print " colspan=$colspan";
+ $colspan = 1;
+ }
+ print '>' unless s/^<td//;
+ say;
+ }
}
say "</table>\n";
}
}
say "</table>\n";
}