diff --git a/weasyprint/layout/inlines.py b/weasyprint/layout/inlines.py index 29487c9f..52a7b034 100644 --- a/weasyprint/layout/inlines.py +++ b/weasyprint/layout/inlines.py @@ -733,7 +733,7 @@ def split_text_box(context, box, available_width, line_width, skip): 'Expected nothing or a preserved line break' % (between,)) resume_at += skip - if box and not preserved_line_break and not new_text.strip(): + if box and not preserved_line_break and not new_text.strip(' '): box.width = 0 return box, resume_at, preserved_line_break