From b8c9b11f0ccd3d6577650b0b0cdfbbd4ddb3314e Mon Sep 17 00:00:00 2001 From: Brendan Howell Date: Sun, 22 Nov 2020 20:18:37 +0100 Subject: [PATCH] nicer linewrap algo for the small printer --- screenless/bureau/bureau.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/screenless/bureau/bureau.py b/screenless/bureau/bureau.py index 63bd14b..e550f94 100644 --- a/screenless/bureau/bureau.py +++ b/screenless/bureau/bureau.py @@ -446,7 +446,7 @@ class Bureau(object): """ prn = self._get_small_printer() - spliter_regex = r'.{1,' + str(self.printer["textwidth"]) + '}(?:\s+|$)' + spliter_regex = r'.{1,' + str(self.smprint["textwidth"]) + '}(?:\s+|$)' out_text = "\r\n".join(line.strip() for line in re.findall(splitter_regex, text))