mirror of
https://github.com/typst/typst
synced 2025-05-16 18:15:29 +08:00
Having a table span multiple pages can cause an alignment bug in the table itself. If the first region in a cell in a grid row is empty, all other cells in this row will skip the first region. A misalignment bug can occur, since the calculation of all region sizes happen before the skip. The overall size allocated for the content of a cell with multiple regions and content in the first region thus is too little. Fixes #963
21 lines
494 B
Typst
21 lines
494 B
Typst
// Grid now skips a remaining region when one of the cells
|
|
// doesn't fit into it at all.
|
|
|
|
---
|
|
#set page(height: 100pt)
|
|
#grid(
|
|
columns: (2cm, auto),
|
|
rows: (auto, auto),
|
|
rect(width: 100%, fill: red),
|
|
rect(width: 100%, fill: blue),
|
|
rect(width: 100%, height: 80%, fill: green),
|
|
[hello \ darkness #parbreak my \ old \ friend \ I],
|
|
rect(width: 100%, height: 20%, fill: blue),
|
|
polygon(fill: red, (0%, 0%), (100%, 0%), (100%, 20%))
|
|
)
|
|
|
|
---
|
|
#set page(height: 60pt)
|
|
#lorem(5)
|
|
- #lorem(5)
|