Universe

Create project in app

[!WARNING] This theme is NOT affiliated with the University of Strasbourg. The logo, fonts and icons are the property of the University of Strasbourg.

touying-unistra-pristine is a Touying theme for creating presentation slides in Typst, adhering to the core principles of the style guide of the University of Strasbourg, France (French). It is an unofficial theme and it is NOT affiliated with the University of Strasbourg.

[!NOTE] Even though this theme was originally intended for members of the University of Strasbourg, it is perfectly acceptable (and even encouraged!) to use this theme for your own (academic) presentations. You can easily customize and extend the theme to your liking, either by configuring the theme and using Typst’s basic functions, or by forking the project and editing the source code directly. If you have ideas for improvements, feel free to open an issue.

This theme was partly created using components from tud-slides.

The example folder contains two examples:

These steps assume that you already have Typst installed and/or running.

Import from Typst Universe

#import "@preview/touying:0.6.1": *
#import "@preview/touying-unistra-pristine:1.4.1": *

#show: unistra-theme.with(
  aspect-ratio: "16-9",
  config-info(
    title: [Title],
    subtitle: [_Subtitle_],
    author: [Author],
    date: datetime.today().display("[month repr:long] [day], [year repr:full]"),
  ),
)

#title-slide[]

= Example Section Title

== Example Slide

A slide with *important information*.

#lorem(50)

Local installation

1. Clone the project

git clone https://github.com/spidersouris/touying-unistra-pristine

2. Import Touying and touying-unistra-pristine

See examples/basic.typ for a basic example with configuration.

#import "@preview/touying:0.6.1": *
#import "src/unistra.typ": *
#import "src/colors.typ": *
#import "src/icons.typ": *

#show: unistra-theme.with(
  aspect-ratio: "16-9",
  config-info(
    title: [Title],
    subtitle: [_Subtitle_],
    author: [Author],
    date: datetime.today().display("[month repr:long] [day], [year repr:full]"),
  ),
)

#title-slide[]

= Example Section Title

== Example Slide

A slide with *important information*.

#lorem(50)

[!NOTE] The default font used by touying-unistra-pristine is “Unistra A”, a font that can only be downloaded by students and staff from the University of Strasbourg from here. If the font is not installed on your computer, Segoe UI or Roboto will be used as a fallback, in that specific order. You can change that behavior in the settings.

touying-unistra-pristine supports icons from the University of Strasbourg (Unistra Symbol). These icons can only be downloaded by students and staff from the University of Strasbourg from here.

As an alternative, or in addition to these icons, you can also use Nova Icons, based on Font Awesome 4.7, which can be downloaded freely from here (.ttf format).

The full list of Unistra Symbol and Nova Icons is available here.

Once these fonts are installed in your environment, they can be used with the us-icon() (Unistra Symbol) and the nv-icon() (Nova Icons) functions. Both functions take the icon string ID (which can be found in the list linked above) without the prefix as an argument. For example:

#nv-icon("coins") // original name is "nv-coins", but no need for the prefix
#us-icon("plant") // original name is "us-plant", but no need for the prefix

Icons are also supported for focus slides. An icon can be defined using the icon parameter to be shown above the title:

#focus-slide(theme: "berry", icon: us-icon("edit-done"))[Focus Slide Title]

Icon function definitions and character-to-string mapping in src/icons.typ are generated automatically using scripts/get_icons.py.

touying-unistra-pristine improves on the handling of citations specifically for academic/research-focused slides. This is achieved by making prose citation the default for label reference, and providing language-specific (French and English/other) CSL files for the formatting of citations and bibliographies.

Language Specificities

If you’re using a bibliography for your slides, it is recommended to change the value of the style argument when invoking #bibliography() to one of the two provided CSL files: apa.csl (French) or apa_en.csl (English/other languages):

#bibliography(
  "my_bib.bib",
  style: "apa.csl",
  title: none,
) // https://typst.app/docs/reference/model/bibliography/

When doing so, make sure to properly set the language of your document:

#set text(lang: "fr") // https://typst.app/docs/reference/text/text/#parameters-lang

Specifically, for French users using apa.csl, this will:

  • separate multiple citations with a non-breaking space and a semicolon,
  • replace the ampersand (&) with “et” for two-author papers.

Syntax

When using any of the provided CSL files described above:

  • @label acts as a prose citation (e.g., “Astley & Morris (2020)”). Supplements are accepted as @label[supplement] and will show as "Astley & Morris (2020:[supplement]).
  • #pcite(label, ..args) acts as a parenthesis citation for a single label. E.g., “(Astley & Morris, 2020)”. Supplement can be specified as an additional argument to the function. Example: #pcite(<a>, 5).
  • #mcite(..args) acts as a parenthesis citation for multiple labels. E.g., “(Astley & Morris, 2020 ; Morris & Astley, 2021)”. Supplement for the corresponding label can be specified as an additional argument within the citation array. Example: #mcite((<a>, 5), (<b>, "24-25"), (<c>,)).

The theme can be configured to your liking by adding the config-store() object when initializing unistra-theme. An example with the quotes setting can be found in examples/basic.typ.

A complete list of settings can be found below.

Name Description Value Type Default
show-header Whether to show the header. bool false
show-footer Whether to show the footer. bool true
footer-first-sep First separator in the footer. str " | "
footer-second-sep Second separator in the footer. str " | "
footer-appendix-label Label to be shown before slide number in the Appendix. str "A-"
font Font to be used. str | array[str] ("Unistra A", "Segoe UI", "Roboto")
quotes Settings to be used for the custom #quote() element. Dict with parameters left, right, outset, margin-top. dict[str | length] (left: "« ", right: " »", outset: 0.5em, margin-top: 0em)
footer-hide Elements from the footer to hide (can include “author” or “date”). array[str] ()