diff options
author | Sebastian Geerken <devnull@localhost> | 2014-07-21 23:42:12 +0200 |
---|---|---|
committer | Sebastian Geerken <devnull@localhost> | 2014-07-21 23:42:12 +0200 |
commit | 394187dd1c45a876677dc5717674ae5eebf8d7af (patch) | |
tree | 413ccfdf220f4272b84ad9e95a7c837865892365 | |
parent | dcb63ae4f9f4bfd3d8c64ccbbb20d64c45f33863 (diff) |
Fixed underfull tables.
-rw-r--r-- | dw/table.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/dw/table.cc b/dw/table.cc index c6fce4e1..b19db790 100644 --- a/dw/table.cc +++ b/dw/table.cc @@ -882,11 +882,14 @@ void Table::forceCalcCellSizes (bool calcHeights) // When column widths are specified (numColWidthSpecified > 0, // as calculated in forceCalcColumnExtremes()), they are treated // specially and excluded from the apportioning, so that the - // specified column widths are enforced. + // specified column widths are enforced. An exception is when + // all columns are specified: in this case they must be + // enlargened to fill the whole table width. - if (numColWidthSpecified == 0) { + if (numColWidthSpecified == 0 || + numColWidthSpecified == colExtremes->size()) { DBG_OBJ_MSG ("resize", 1, - "subcase 2a: no columns with specified width"); + "subcase 2a: no or all columns with specified width"); apportion2 (totalWidth, 0, colExtremes->size() - 1, MAX, MAX, NULL, colWidths, 0); } else { |