Fix "console" width on non real terminals (pipe)

Signed-off-by: Jacek Szafarkiewicz <szafar@linux.pl>
This commit is contained in:
Jacek Szafarkiewicz 2023-02-01 09:53:17 +01:00 committed by Marek Blaha
parent dee3952a8c
commit 2beb3ef518
1 changed files with 1 additions and 1 deletions

View File

@ -205,7 +205,7 @@ class Output(object):
full_columns.append(col[-1][0])
else:
full_columns.append(columns[d] + 1)
full_columns[0] += len(indent)
full_columns[0] += len(indent) * 2
# if possible, try to keep default width (usually 80 columns)
default_width = self.term.columns
if sum(full_columns) > default_width: