summaryrefslogtreecommitdiff
path: root/tests/typ/layout/page-margin.typ
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-02-07 20:00:21 +0100
committerLaurenz <laurmaedje@gmail.com>2022-02-07 20:00:21 +0100
commit68503b9a07b00bce3f4d377bcfe945452de815ea (patch)
tree3719ef491b993c59b619ca215963000f4847e78f /tests/typ/layout/page-margin.typ
parent9730e785a885a4ab5fcc52ce705298654f82f9c2 (diff)
Redesigned template layout
Diffstat (limited to 'tests/typ/layout/page-margin.typ')
-rw-r--r--tests/typ/layout/page-margin.typ20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/typ/layout/page-margin.typ b/tests/typ/layout/page-margin.typ
new file mode 100644
index 00000000..44126d2d
--- /dev/null
+++ b/tests/typ/layout/page-margin.typ
@@ -0,0 +1,20 @@
+// Test page margins.
+
+---
+// Set all margins at once.
+[
+ #set page(height: 20pt, margins: 5pt)
+ #place(top + left)[TL]
+ #place(bottom + right)[BR]
+]
+
+---
+// Set individual margins.
+#set page(height: 40pt)
+[#set page(left: 0pt); #align(left)[Left]]
+[#set page(right: 0pt); #align(right)[Right]]
+[#set page(top: 0pt); #align(top)[Top]]
+[#set page(bottom: 0pt); #align(bottom)[Bottom]]
+
+// Ensure that specific margins override general margins.
+[#set page(margins: 0pt, left: 20pt); Overriden]