[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #61854] [tbl] tables lacking 'x' column modifier don't get table wi
From: |
G. Branden Robinson |
Subject: |
[bug #61854] [tbl] tables lacking 'x' column modifier don't get table width warnings |
Date: |
Wed, 19 Jan 2022 08:40:00 -0500 (EST) |
User-agent: |
Lynx/2.8.9rel.1 libwww-FM/2.14 SSL-MM/1.4.1 GNUTLS/3.6.7 |
Update of bug #61854 (project groff):
Status: Confirmed => In Progress
_______________________________________________________
Follow-up Comment #4:
diff --git a/ChangeLog b/ChangeLog
index 9ef1c2d84..754c70bf4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2022-01-20 G. Branden Robinson <g.branden.robinson@gmail.com>
+
+ [tbl]: Fix Savannah #61854.
+
+ * src/preproc/tbl/table.cpp (compute_expand_width): Include
+ width of expanded ('x'-modified) columns in expression used to
+ decide whether the table with has exceeded the line length.
+ Omitting them from the calculation incorrectly surpressed
+ warning diagnostics of too-wide tables. (In other words, you
+ only got warnings of too-wide tables where one or more columns
+ used the 'x' modifier.)
+
+ Fixes <https://savannah.gnu.org/bugs/?61854>.
+
2022-01-19 G. Branden Robinson <g.branden.robinson@gmail.com>
[ms]: Don't add leaders that don't lead anywhere.
diff --git a/src/preproc/tbl/table.cpp b/src/preproc/tbl/table.cpp
index 435ac6bf7..4508965c2 100644
--- a/src/preproc/tbl/table.cpp
+++ b/src/preproc/tbl/table.cpp
@@ -2162,8 +2162,7 @@ void table::compute_expand_width()
int colcount = count_expand_columns();
prints(".nr " EXPAND_REG " \\n[.l]-\\n[.i]");
for (i = 0; i < ncolumns; i++)
- if (!expand[i])
- printfs("-\\n[%1]", span_width_reg(i, i));
+ printfs("-\\n[%1]", span_width_reg(i, i));
if (total_separation)
printfs("-%1n", as_string(total_separation));
prints("\n");
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?61854>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/