diff options
| author | Laurenz <laurmaedje@gmail.com> | 2021-10-26 14:51:48 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2021-10-26 14:56:10 +0200 |
| commit | fb0cd3df6e1e1077c6f19c319726c9aa9678325b (patch) | |
| tree | bde325cdcb0efa59324781bf2af8c4303e5a25de /tests | |
| parent | 1ca4ff69e235ca6dde9ef498a8377d0586f2519c (diff) | |
Fr in stack and par
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ref/layout/spacing.png | bin | 1744 -> 1827 bytes | |||
| -rw-r--r-- | tests/ref/layout/stack-1.png (renamed from tests/ref/layout/stack.png) | bin | 319 -> 319 bytes | |||
| -rw-r--r-- | tests/ref/layout/stack-2.png | bin | 0 -> 3298 bytes | |||
| -rw-r--r-- | tests/typ/layout/spacing.typ | 3 | ||||
| -rw-r--r-- | tests/typ/layout/stack-1.typ (renamed from tests/typ/layout/stack.typ) | 0 | ||||
| -rw-r--r-- | tests/typ/layout/stack-2.typ | 24 |
6 files changed, 27 insertions, 0 deletions
diff --git a/tests/ref/layout/spacing.png b/tests/ref/layout/spacing.png Binary files differindex bffa9507..c653df6d 100644 --- a/tests/ref/layout/spacing.png +++ b/tests/ref/layout/spacing.png diff --git a/tests/ref/layout/stack.png b/tests/ref/layout/stack-1.png Binary files differindex 78f7ed77..78f7ed77 100644 --- a/tests/ref/layout/stack.png +++ b/tests/ref/layout/stack-1.png diff --git a/tests/ref/layout/stack-2.png b/tests/ref/layout/stack-2.png Binary files differnew file mode 100644 index 00000000..3e503e65 --- /dev/null +++ b/tests/ref/layout/stack-2.png diff --git a/tests/typ/layout/spacing.typ b/tests/typ/layout/spacing.typ index 3794612c..7cf6760f 100644 --- a/tests/typ/layout/spacing.typ +++ b/tests/typ/layout/spacing.typ @@ -14,6 +14,9 @@ Add #h(10pt) #h(10pt) up #let x = 25% - 4pt | #h(x) | #h(x) | #h(x) | #h(x) | +// Fractional. +| #h(1fr) | #h(2fr) | #h(1fr) | + --- // Missing spacing. // Error: 11-13 missing argument: spacing diff --git a/tests/typ/layout/stack.typ b/tests/typ/layout/stack-1.typ index b8d8a09d..b8d8a09d 100644 --- a/tests/typ/layout/stack.typ +++ b/tests/typ/layout/stack-1.typ diff --git a/tests/typ/layout/stack-2.typ b/tests/typ/layout/stack-2.typ new file mode 100644 index 00000000..afc9de39 --- /dev/null +++ b/tests/typ/layout/stack-2.typ @@ -0,0 +1,24 @@ +// Test fr units in stacks. + +--- +#page(height: 3.5cm) +#stack( + dir: ltr, + spacing: 1fr, + ..for c in "ABCDEFGHI" {([#c],)} +) + +Hello +#v(2fr) +from #h(1fr) the #h(1fr) wonderful +#v(1fr) +World! 🌍 + +--- +#page(height: 2cm) +#font(white) +#box(fill: forest)[ + #v(1fr) + #h(1fr) Hi you! #h(5pt) + #v(5pt) +] |
