From b59b8bfb352f57d50acd67a048baa8390d37e374 Mon Sep 17 00:00:00 2001 From: bluebear94 Date: Wed, 23 Aug 2023 07:39:22 -0400 Subject: linebreak_optimized: Handle breakpoints separated only by spaces (#1821) --- tests/ref/layout/par-justify.png | Bin 19571 -> 27297 bytes tests/typ/layout/par-justify.typ | 10 ++++++++++ 2 files changed, 10 insertions(+) (limited to 'tests') diff --git a/tests/ref/layout/par-justify.png b/tests/ref/layout/par-justify.png index fd25c5b7..5745f081 100644 Binary files a/tests/ref/layout/par-justify.png and b/tests/ref/layout/par-justify.png differ diff --git a/tests/typ/layout/par-justify.typ b/tests/typ/layout/par-justify.typ index 2e5b4806..e72a2a07 100644 --- a/tests/typ/layout/par-justify.typ +++ b/tests/typ/layout/par-justify.typ @@ -40,3 +40,13 @@ This text can be fitted in one line. "a b c " } #"d" + +--- +// Test that justification cannot lead to a leading space +#set par(justify: true) +#set text(size: 12pt) +#set page(width: 45mm, height: auto) + +lorem ipsum 1234, lorem ipsum dolor sit amet + +#" leading whitespace should still be displayed" -- cgit v1.2.3