make sure empty text returns 0 lines

pull/35051/head
Cameron Clough 4 months ago
parent 3c15e842d3
commit 618803fcc4
  1. 1
      system/ui/text.py

@ -21,6 +21,7 @@ def wrap_text(text, font_size, max_width):
for paragraph in text.split("\n"):
if not paragraph.strip():
if lines:
lines.append("")
continue
indent = re.match(r"^\s*", paragraph).group()

Loading…
Cancel
Save