We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9bc4d2b commit c1db755Copy full SHA for c1db755
adafruit_display_text/__init__.py
@@ -53,6 +53,7 @@ def chunks(lst, n):
53
for part in chunks(w, max_chars - 1):
54
parts.append("{}-".format(part))
55
the_lines.extend(parts[:-1])
56
+ # Remove the last hyphen on the last chunk
57
the_line = parts[-1][:-1]
58
continue
59
@@ -63,6 +64,9 @@ def chunks(lst, n):
63
64
the_line = "" + w
65
if the_line: # Last line remaining
66
the_lines.append(the_line)
67
+ # Remove any blank lines
68
+ while not the_lines[0]:
69
+ del the_lines[0]
70
# Remove first space from first line:
71
if the_lines[0][0] == " ":
72
the_lines[0] = the_lines[0][1:]
0 commit comments