blob: 649d31c0317bd6e47311986fa180a0eec7968f81 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
// Test the `square` function.
---
Auto-sized square. \
#square(fill: eastern)[
#align(center)
#pad(5pt)[
#font(color: #fff, weight: bold)
Typst
]
]
---
// Length wins over width and height.
// Error: 2:9-2:20 unexpected argument
// Error: 1:22-1:34 unexpected argument
#square(width: 10cm, height: 20cm, length: 1cm, fill: #eb5278)
---
// Test height overflow.
#page(width: 75pt, height: 100pt)
#square(fill: conifer)[
But, soft! what light through yonder window breaks?
]
---
// Test width overflow.
#page(width: 100pt, height: 75pt)
#square(fill: conifer)[
But, soft! what light through yonder window breaks?
]
|