blob: 501e517ed0b0afdbfb35d455f6d2f746a62106e9 (
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
|
// Test that passing infinite lengths to drawing primitives does not crash Typst.
---
#set page(width: auto, height: auto)
// Error: cannot expand into infinite width
#layout(size => grid(columns: (size.width, size.height))[a][b][c][d])
---
#set page(width: auto, height: auto)
// Error: 17-66 cannot create grid with infinite height
#layout(size => grid(rows: (size.width, size.height))[a][b][c][d])
---
#set page(width: auto, height: auto)
// Error: 17-41 cannot create line with infinite length
#layout(size => line(length: size.width))
---
#set page(width: auto, height: auto)
// Error: 17-54 cannot create polygon with infinite size
#layout(size => polygon((0pt,0pt), (0pt, size.width)))
|