Software /
code /
prosody
Diff
util/human/io.lua @ 10910:e890b83f08cf
util.human.io: Consider separator when calculating remaining width
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 04 Jun 2020 18:40:37 +0200 |
parent | 10909:3af3354366eb |
child | 10911:9dc34e1556d9 |
line wrap: on
line diff
--- a/util/human/io.lua Thu Jun 04 18:36:47 2020 +0200 +++ b/util/human/io.lua Thu Jun 04 18:40:37 2020 +0200 @@ -110,6 +110,9 @@ 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 -- Calculate width of %-based columns