summaryrefslogtreecommitdiff
path: root/tests/typ/layout
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2021-06-29 13:45:59 +0200
committerLaurenz <laurmaedje@gmail.com>2021-06-29 13:49:50 +0200
commit32a6b673bc4b73ade5863b0166c0779597cede5c (patch)
tree7d32aa06c63052a759f7fc4d89bb551faeb258d0 /tests/typ/layout
parentb89cd128ae118571efe8a5a5b40b9365e3007746 (diff)
Make use of wide calls
Diffstat (limited to 'tests/typ/layout')
-rw-r--r--tests/typ/layout/containers.typ2
-rw-r--r--tests/typ/layout/grid-1.typ8
-rw-r--r--tests/typ/layout/grid-2.typ2
-rw-r--r--tests/typ/layout/grid-3.typ10
-rw-r--r--tests/typ/layout/pad.typ2
-rw-r--r--tests/typ/layout/page.typ14
-rw-r--r--tests/typ/layout/pagebreak.typ6
7 files changed, 22 insertions, 22 deletions
diff --git a/tests/typ/layout/containers.typ b/tests/typ/layout/containers.typ
index b2835b5e..75e2617b 100644
--- a/tests/typ/layout/containers.typ
+++ b/tests/typ/layout/containers.typ
@@ -12,7 +12,7 @@ Apart
---
// Test block over multiple pages.
-#page(height: 60pt)
+#page!(height: 60pt)
First!
#block[
diff --git a/tests/typ/layout/grid-1.typ b/tests/typ/layout/grid-1.typ
index 827a98a7..2938a7f2 100644
--- a/tests/typ/layout/grid-1.typ
+++ b/tests/typ/layout/grid-1.typ
@@ -3,7 +3,7 @@
---
#let rect(width, color) = rect(width: width, height: 2cm, fill: color)
-#page(width: 100pt, height: 140pt)
+#page!(width: 100pt, height: 140pt)
#grid(
columns: (auto, 1fr, 3fr, 0.25cm, 3%, 2mm + 10%),
rect(0.5cm, #2a631a),
@@ -33,7 +33,7 @@
)
---
-#page(height: 3cm, width: 2cm)
+#page!(height: 3cm, width: 2cm)
#grid(
columns: (1fr, 1cm, 1fr, 1fr),
column-dir: ttb,
@@ -46,8 +46,8 @@
)
---
-#page(height: 3cm, margins: 0pt)
-#align(center)
+#page!(height: 3cm, margins: 0pt)
+#align!(center)
#grid(
columns: (1fr,),
rows: (1fr, auto, 2fr),
diff --git a/tests/typ/layout/grid-2.typ b/tests/typ/layout/grid-2.typ
index 277e695c..e28cfaf2 100644
--- a/tests/typ/layout/grid-2.typ
+++ b/tests/typ/layout/grid-2.typ
@@ -1,7 +1,7 @@
// Test using the `grid` function to create a finance table.
---
-#page(width: 12cm, height: 2.5cm)
+#page!(width: 12cm, height: 2.5cm)
#grid(
columns: 5,
gutter-columns: (2fr, 1fr, 1fr),
diff --git a/tests/typ/layout/grid-3.typ b/tests/typ/layout/grid-3.typ
index 6ef0ab83..62af4072 100644
--- a/tests/typ/layout/grid-3.typ
+++ b/tests/typ/layout/grid-3.typ
@@ -1,7 +1,7 @@
// Test grid cells that overflow to the next region.
---
-#page(width: 5cm, height: 3cm)
+#page!(width: 5cm, height: 3cm)
#grid(
columns: 2,
gutter-rows: 3 * (8pt,),
@@ -18,7 +18,7 @@
---
// Test a column that starts overflowing right after another row/column did
// that.
-#page(width: 5cm, height: 2cm)
+#page!(width: 5cm, height: 2cm)
#grid(
columns: 4 * (1fr,),
gutter-rows: (10pt,),
@@ -32,7 +32,7 @@
---
// Test two columns in the same row overflowing by a different amount.
-#page(width: 5cm, height: 2cm)
+#page!(width: 5cm, height: 2cm)
#grid(
columns: 3 * (1fr,),
gutter-rows: (8pt,),
@@ -48,7 +48,7 @@
---
// Test grid within a grid, overflowing.
-#page(width: 5cm, height: 2.25cm)
+#page!(width: 5cm, height: 2.25cm)
#grid(
columns: 4 * (1fr,),
gutter-rows: (10pt,),
@@ -62,7 +62,7 @@
---
// Test partition of `fr` units before and after multi-region layout.
-#page(width: 5cm, height: 4cm)
+#page!(width: 5cm, height: 4cm)
#grid(
columns: 2 * (1fr,),
rows: (1fr, 2fr, auto, 1fr, 1cm),
diff --git a/tests/typ/layout/pad.typ b/tests/typ/layout/pad.typ
index 142ae4a9..17e5cb0b 100644
--- a/tests/typ/layout/pad.typ
+++ b/tests/typ/layout/pad.typ
@@ -29,7 +29,7 @@ Hi #box(pad(left: 10pt)) there
---
// Test that the pad node doesn't consume the whole region.
-#page(height: 6cm)
+#page!(height: 6cm)
#align(left)[Before]
#pad(10pt, image("../../res/tiger.jpg"))
diff --git a/tests/typ/layout/page.typ b/tests/typ/layout/page.typ
index cf787e5d..d154d5f4 100644
--- a/tests/typ/layout/page.typ
+++ b/tests/typ/layout/page.typ
@@ -2,7 +2,7 @@
---
// Set width and height.
-#page(width: 120pt, height: 120pt)
+#page!(width: 120pt, height: 120pt)
#page(width: 40pt)[High]
#page(height: 40pt)[Wide]
@@ -13,7 +13,7 @@
]
// Set individual margins.
-#page(height: 40pt)
+#page!(height: 40pt)
#page(left: 0pt, align(left)[Left])
#page(right: 0pt, align(right)[Right])
#page(top: 0pt, align(top)[Top])
@@ -22,21 +22,21 @@
// Ensure that specific margins override general margins.
#page(margins: 0pt, left: 20pt)[Overriden]
-// Error: 7-18 unknown variable
-#page(nonexistant)
+// Error: 8-19 unknown variable
+#page!(nonexistant)
// Flipped predefined paper.
#page("a11", flip: true)[Flipped A11]
// Flipped custom page size.
-#page(width: 40pt, height: 120pt)
-#page(flip: true)
+#page!(width: 40pt, height: 120pt)
+#page!(flip: true)
Wide
---
// Test a combination of pages with bodies and normal content.
-#page(height: 50pt)
+#page!(height: 50pt)
#page[First]
#page[Second]
diff --git a/tests/typ/layout/pagebreak.typ b/tests/typ/layout/pagebreak.typ
index dedf1ce6..ac0a3833 100644
--- a/tests/typ/layout/pagebreak.typ
+++ b/tests/typ/layout/pagebreak.typ
@@ -3,7 +3,7 @@
---
First of two
#pagebreak()
-#page(height: 40pt)
+#page!(height: 40pt)
---
// Make sure that you can't do page related stuff in a container.
@@ -13,8 +13,8 @@ A
// Error: 16 cannot modify page from here
#pagebreak()
- // Error: 11-15 cannot modify page from here
- #page("a4")
+ // Error: 12-16 cannot modify page from here
+ #page!("a4")
]
C