diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2017-06-13 16:12:01 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2017-06-13 16:12:01 +0000 |
commit | a03895d16836ec105b7b21d6333f6b137f1d349e (patch) | |
tree | 0f75d2ee06a118b3d2a126d54dc58fe873c6d831 /tbl_layout.c | |
parent | de607760299bad01e72dd0d624a4e7d2b7537fca (diff) | |
download | mandoc-a03895d16836ec105b7b21d6333f6b137f1d349e.tar.gz mandoc-a03895d16836ec105b7b21d6333f6b137f1d349e.tar.zst mandoc-a03895d16836ec105b7b21d6333f6b137f1d349e.zip |
If the layout is empty except for requesting a left vertical frame,
record that detail in struct tbl_opts, such that term_tbl() can do
correct column calculations and doesn't prematurely break lines.
Fixes the tbl/layout/empty regression test that got broken when
line breaking in text block cells was implemented.
Diffstat (limited to 'tbl_layout.c')
-rw-r--r-- | tbl_layout.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tbl_layout.c b/tbl_layout.c index d27ac3cd..5357d808 100644 --- a/tbl_layout.c +++ b/tbl_layout.c @@ -1,4 +1,4 @@ -/* $Id: tbl_layout.c,v 1.42 2017/06/08 18:11:22 schwarze Exp $ */ +/* $Id: tbl_layout.c,v 1.43 2017/06/13 16:12:01 schwarze Exp $ */ /* * Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2012, 2014, 2015, 2017 Ingo Schwarze <schwarze@openbsd.org> @@ -298,6 +298,8 @@ tbl_layout(struct tbl_node *tbl, int ln, const char *p, int pos) tbl->parse, ln, pos, NULL); cell_alloc(tbl, tbl->first_row, TBL_CELL_LEFT); + if (tbl->opts.lvert < tbl->first_row->vert) + tbl->opts.lvert = tbl->first_row->vert; return; } |