diff --git a/cvpr/README.md b/cvpr/README.md index 014084a..f1218a2 100644 --- a/cvpr/README.md +++ b/cvpr/README.md @@ -112,6 +112,9 @@ template, you can add a show rule at the top of your file. its guidelines closely. Since writing CSL-style files is tedious task, we adopt close enough bibliography style from Zotero. +- With Typst 0.12.0, multi-column page layout is set in different way. Thus, + footnotes use full page width at the moment. + ## References + CVPR 2022 conference [web site][4]. diff --git a/cvpr/cvpr2022.typ b/cvpr/cvpr2022.typ index 7d1e608..389902b 100644 --- a/cvpr/cvpr2022.typ +++ b/cvpr/cvpr2022.typ @@ -29,13 +29,13 @@ #let etal = emph[et~al] #let font-family = ("Times New Roman", "CMU Serif", "Latin Modern Roman", - "New Computer Modern", "Times", "Serif") + "New Computer Modern", "Libertinus Serif") #let font-family-sans = ("Arial", "TeX Gyre Heros", "New Computer Modern Sans", - "CMU Sans Serif", "Sans") + "CMU Sans Serif", "DejaVu Sans") #let font-family-mono = ("CMU Typewriter Text", "Latin Modern Mono", - "New Computer Modern Mono", "Mono") + "New Computer Modern Mono", "DejaVu Sans Mono") #let font-family-link = ("Courier New", "Nimbus Mono PS") + font-family-mono @@ -106,7 +106,7 @@ width: auto, height: 8.875in, gap: 30pt, -) = locate(loc => { +) = context { let margin = if margin == auto { (top: 1in - 0.5pt, left: 0.8125in, right: 0.929in) // CVPR 2022 defaults. } else { @@ -129,7 +129,7 @@ dx = 7.571in + gap offset += num-lines xruler(right, dx, dy, width.right, height, offset, num-lines) -}) +} #let ruler = make-ruler() // Default CVPR 2022 ruler. @@ -315,16 +315,17 @@ }, footer-descent: 23.4pt, // Visually perfect. footer: if accepted != none and not accepted { - locate(loc=>{ - let ix=counter(page).at(loc).first() + context { + let ix = counter(page).get().first() return align(center, text(size: font-size.normal, [#ix])) - }) + } }, ) set text(font: font-family, size: font-size.normal) - set par(justify: true, first-line-indent: 0.166666in, leading: 0.532em) - show par: set block(spacing: 0.54em) + set par( + first-line-indent: 0.166666in, leading: 0.532em, spacing: 0.54em, + justify: true) show raw: set text(font: font-family-mono, size: font-size.normal) // Configure heading appearence and numbering. @@ -340,8 +341,7 @@ show quote.where(block: true): it => { set block(spacing: 14pt) set pad(left: 20pt, right: 20pt) - set par(first-line-indent: 0em) - show par: set block(spacing: 9.8pt) + set par(first-line-indent: 0em, spacing: 9.8pt) it } @@ -415,6 +415,9 @@ // NOTE It seems that there is a typo in formatting instructions and actual // gutter is 3/8 in not 5/16 in. + // + // TODO(@daskol): Set number of columns in page settings. Otherwise, + // footnotes use all page width. columns(2, gutter: 0.3125in, { // Render abstract. block(width: 100%, { diff --git a/cvpr/example-paper.typst.pdf b/cvpr/example-paper.typst.pdf index b972b38..ee07893 100644 Binary files a/cvpr/example-paper.typst.pdf and b/cvpr/example-paper.typst.pdf differ diff --git a/cvpr/logo.typ b/cvpr/logo.typ index 31c6bfc..448eb4d 100644 --- a/cvpr/logo.typ +++ b/cvpr/logo.typ @@ -1,18 +1,18 @@ #let kern(length) = h(length, weak: true) -#let TeX = style(styles => { - let e = measure(text("E"), styles) +#let TeX = context { + let e = measure(text("E")) let T = "T" let E = text(baseline: e.height / 2, "E") let X = "X" box(T + kern(-0.1667em) + E + kern(-0.125em) + X) -}) -#let LaTeX = style(styles => { - let l = measure(text(10pt, "L"), styles) - let a = measure(text(7pt, "A"), styles) +} +#let LaTeX = context { + let l = measure(text(10pt, "L")) + let a = measure(text(7pt, "A")) let L = "L" let A = text(7pt, baseline: a.height - l.height, "A") box(L + kern(-0.36em) + A + kern(-0.15em) + TeX) -}) -#let LaTeXe = style(styles => { +} +#let LaTeXe = context { box(LaTeX + sym.space.sixth + [2#text(baseline: 0.3em, $epsilon$)]) -}) +} diff --git a/cvpr/main.typ b/cvpr/main.typ index 0d9bf9b..684d0c6 100644 --- a/cvpr/main.typ +++ b/cvpr/main.typ @@ -276,7 +276,7 @@ because reference~@Alpher03 has just two authors. it.caption } #show figure.caption.where(kind: "subfigure"): it => { - let ix = counter(figure.where(kind: "subfigure")).display("(a)") + let ix = context counter(figure.where(kind: "subfigure")).display("(a)") [#ix~#it.body] }