Software /
code /
prosody
Changeset
13068:7a75cbc4d87c
util.human.io: Fix column width miscalculation
Fixes that the more fixed width columns there are, the narrower the
resulting table becomes. A right-aligned variable-width column at the
last position should always be flush to the right side of the terminal.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 09 Apr 2023 22:31:12 +0200 |
parents | 13067:386ca97bec5b |
children | 13069:45caa4e43775 |
files | util/human/io.lua |
diffstat | 1 files changed, 0 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/util/human/io.lua Sun Apr 09 01:34:08 2023 +0200 +++ b/util/human/io.lua Sun Apr 09 22:31:12 2023 +0200 @@ -142,9 +142,6 @@ width = math.max(tonumber(width), title and (#title+1) or 0); widths[i] = width; free_width = free_width - width; - if i > 1 then - free_width = free_width - #separator; - end end end