aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/out.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2011-01-10 14:40:30 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2011-01-10 14:40:30 +0000
commitb3ea03504ba905470ba5c486ba69062c89034488 (patch)
treedf4cbcc9f5102817e214499b8ce04b165972afbf /out.c
parent8b2891b502ff415c363420b6f4238ec3561efd97 (diff)
downloadmandoc-b3ea03504ba905470ba5c486ba69062c89034488.tar.gz
mandoc-b3ea03504ba905470ba5c486ba69062c89034488.tar.zst
mandoc-b3ea03504ba905470ba5c486ba69062c89034488.zip
First, make extra data cells be thrown away. This makes "dp->layout"
always hold, which cleans up the table stuff a bit. Second, set a "spans" value per data cell consisting of the number of skipped TBL_CELL_SPAN layout cells. Third, make tbl_term.c understand how to skip over spanned sections when iterating over the header queue. What remains is to calculate the widths of spanned cells.
Diffstat (limited to 'out.c')
-rw-r--r--out.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/out.c b/out.c
index 58fdf951..b13d783f 100644
--- a/out.c
+++ b/out.c
@@ -1,4 +1,4 @@
-/* $Id: out.c,v 1.32 2011/01/08 17:16:48 kristaps Exp $ */
+/* $Id: out.c,v 1.33 2011/01/10 14:40:30 kristaps Exp $ */
/*
* Copyright (c) 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -399,8 +399,7 @@ tblcalc(struct rofftbl *tbl, const struct tbl_span *sp)
* to data cells in the data section.
*/
for (dp = sp->first; dp; dp = dp->next) {
- if (NULL == dp->layout)
- continue;
+ assert(dp->layout);
col = &tbl->cols[dp->layout->head->ident];
tblcalc_data(tbl, col, sp->tbl, dp);
}