summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorPgBiel <9021226+PgBiel@users.noreply.github.com>2024-03-13 06:15:16 -0300
committerGitHub <noreply@github.com>2024-03-13 09:15:16 +0000
commit48820fe69b8061bd949847afc343bf160d05c924 (patch)
tree8b51ce9b682fb0ac3c79810f649b8c7b9a60c91f /tests
parentfd2eb0ceb25270e5ea738b76a2f5271e84234667 (diff)
Fix table cells and rowspans wrongly assuming full page height available (#3637)
Diffstat (limited to 'tests')
-rw-r--r--tests/ref/layout/grid-headers-4.pngbin41733 -> 42192 bytes
-rw-r--r--tests/ref/layout/grid-rowspan-basic.pngbin98653 -> 99968 bytes
-rw-r--r--tests/ref/layout/grid-rowspan-split-3.pngbin99690 -> 100103 bytes
-rw-r--r--tests/typ/layout/grid-headers-4.typ13
-rw-r--r--tests/typ/layout/grid-rowspan-basic.typ20
5 files changed, 33 insertions, 0 deletions
diff --git a/tests/ref/layout/grid-headers-4.png b/tests/ref/layout/grid-headers-4.png
index be6080f7..1f3e4b10 100644
--- a/tests/ref/layout/grid-headers-4.png
+++ b/tests/ref/layout/grid-headers-4.png
Binary files differ
diff --git a/tests/ref/layout/grid-rowspan-basic.png b/tests/ref/layout/grid-rowspan-basic.png
index 783991b3..b464d8b4 100644
--- a/tests/ref/layout/grid-rowspan-basic.png
+++ b/tests/ref/layout/grid-rowspan-basic.png
Binary files differ
diff --git a/tests/ref/layout/grid-rowspan-split-3.png b/tests/ref/layout/grid-rowspan-split-3.png
index 3d809123..c3ff4bd1 100644
--- a/tests/ref/layout/grid-rowspan-split-3.png
+++ b/tests/ref/layout/grid-rowspan-split-3.png
Binary files differ
diff --git a/tests/typ/layout/grid-headers-4.typ b/tests/typ/layout/grid-headers-4.typ
index 6ede601c..6ab0d612 100644
--- a/tests/typ/layout/grid-headers-4.typ
+++ b/tests/typ/layout/grid-headers-4.typ
@@ -97,3 +97,16 @@
[a],
table.cell(stroke: aqua)[b]
)
+
+---
+#set page(height: 7em)
+#set text(6pt)
+#let full-block = block(width: 2em, height: 100%, fill: red)
+#table(
+ columns: 3,
+ inset: 1.5pt,
+ table.header(
+ [a], full-block, table.cell(rowspan: 2, full-block),
+ [b]
+ )
+)
diff --git a/tests/typ/layout/grid-rowspan-basic.typ b/tests/typ/layout/grid-rowspan-basic.typ
index 1cc7289b..bbd1c047 100644
--- a/tests/typ/layout/grid-rowspan-basic.typ
+++ b/tests/typ/layout/grid-rowspan-basic.typ
@@ -230,3 +230,23 @@
[f],
[g]
)
+
+---
+// Block below shouldn't expand to the end of the page, but stay within its
+// rows' boundaries.
+#set page(height: 9em)
+#table(
+ rows: (1em, 1em, 1fr, 1fr, auto),
+ table.cell(rowspan: 2, block(width: 2em, height: 100%, fill: red)),
+ table.cell(rowspan: 2, block(width: 2em, height: 100%, fill: red)),
+ [a]
+)
+
+---
+#set page(height: 7em)
+#table(
+ columns: 3,
+ [], [], table.cell(breakable: true, rowspan: 2, block(width: 2em, height: 100%, fill: red)),
+ table.cell(breakable: false, block(width: 2em, height: 100%, fill: red)),
+ table.cell(breakable: false, rowspan: 2, block(width: 2em, height: 100%, fill: red)),
+)