Skip to content

Commit fed6e1d

Browse files
committed
prinzipien:0.1.1
1 parent f4b65c3 commit fed6e1d

18 files changed

Lines changed: 1245 additions & 0 deletions
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
Boost Software License - Version 1.0 - August 17th, 2003
2+
3+
Permission is hereby granted, free of charge, to any person or organization
4+
obtaining a copy of the software and accompanying documentation covered by
5+
this license (the "Software") to use, reproduce, display, distribute,
6+
execute, and transmit the Software, and to prepare derivative works of the
7+
Software, and to permit third-parties to whom the Software is furnished to
8+
do so, all subject to the following:
9+
10+
The copyright notices in the Software and this entire statement, including
11+
the above license grant, this restriction and the following disclaimer,
12+
must be included in all copies of the Software, in whole or in part, and
13+
all derivative works of the Software, unless such copies or derivative
14+
works are solely in the form of machine-executable object code generated by
15+
a source language processor.
16+
17+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
20+
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
21+
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
22+
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23+
DEALINGS IN THE SOFTWARE.
Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# prinzipien
2+
3+
[![Typst Universe](https://img.shields.io/badge/Typst_Universe-prinzipien-239dad?logo=typst&logoColor=white)](https://typst.app/universe/package/prinzipien)
4+
[![License: BSL-1.0](https://img.shields.io/badge/license-BSL--1.0-blue.svg)](LICENSE.txt)
5+
[![Built with Touying](https://img.shields.io/badge/built_with-touying-f9ab1a)](https://touying-typ.github.io/)
6+
7+
Prinzipien is a [Typst](https://typst.app) theme for
8+
[Touying](https://touying-typ.github.io/) presentations, built on the design
9+
principles of Jean-luc Doumont's _Trees, maps, and theorems_: **one message per
10+
slide**. Each slide states a single, full-sentence message as its title, set
11+
flush against a wide left margin, and a single accent colour — with tints
12+
derived from it — does all the visual work.
13+
14+
- **One message per slide** — the slide title is a full sentence stating the takeaway.
15+
- **A wide, Doumont-style left margin** that structures every slide.
16+
- **A single accent colour**, with tints derived automatically for emphasis and de-emphasis.
17+
- **Automatic overview slides**`preview`, section `transition`s, and `review` build a map of your points.
18+
- **Batteries included** — a title slide, appendix numbering, and logo support.
19+
- **Configured in one place** — aspect ratio, margin width, colours, and logo.
20+
21+
## Showcase
22+
23+
![Four slides from the demo deck: a title slide with a logo, an overview map in the accent colour, a content slide flush against the wide margin, and a slide with labels in the margin beside an image.](assets/showcase.png)
24+
25+
The slides above come from the `examples/demo.typ` deck, which relies on the
26+
theme's defaults; `examples/full-demo.typ` exercises every configuration option.
27+
Both live in the [source repository](https://github.com/Entze/prinzipien).
28+
29+
## Installation
30+
31+
Prinzipien is published on
32+
[Typst Universe](https://typst.app/universe/package/prinzipien), so no manual
33+
installation is required. To start a new presentation from the bundled template:
34+
35+
```sh
36+
typst init @preview/prinzipien
37+
```
38+
39+
Or import the theme into an existing document:
40+
41+
```typ
42+
#import "@preview/prinzipien:0.1.1": *
43+
```
44+
45+
### Requirements
46+
47+
- Typst 0.15.0 or newer.
48+
- The Noto Sans and Noto Sans Mono fonts (bundled with Typst). Override them
49+
with your own `set text(font: ..)` rules after the theme's show rule if you
50+
prefer different fonts.
51+
52+
## Usage
53+
54+
Apply the theme with a show rule, then write one message per slide as a
55+
level-2 heading:
56+
57+
```typ
58+
#import "@preview/prinzipien:0.1.1": *
59+
60+
#show: prinzipien-theme.with(
61+
config-info(
62+
title: [One sentence to remember],
63+
author: [Ada Lovelace],
64+
date: datetime.today(),
65+
),
66+
)
67+
68+
#title-slide()
69+
70+
== Give every slide a full-sentence message
71+
72+
The heading carries the takeaway; the body only supports it.
73+
```
74+
75+
Highlight the words that matter with `#alert[..]`, mark the main points of your
76+
talk with `#point[..]`, and let `#preview()` / `#review()` build the overview
77+
maps automatically. See [`template/main.typ`](template/main.typ) for a complete
78+
starting point, and the `examples/` directory in the
79+
[repository](https://github.com/Entze/prinzipien) for fuller decks.
80+
81+
### Configuration
82+
83+
`prinzipien-theme` takes a handful of options, all with sensible defaults:
84+
85+
| Option | Default | Description |
86+
| --- | --- | --- |
87+
| `aspect-ratio` | `"16-9"` | Slide aspect ratio (`"16-9"` or `"4-3"`). |
88+
| `margin` | `33%` | Width of the reserved left margin (a ratio of the slide width, or a length). |
89+
| `background` | `#ffffff` | Background colour. |
90+
| `foreground` | `#221f21` | Text (foreground) colour. |
91+
| `accent` | `#f9ab1a` | The one accent colour. |
92+
| `suppressed` | `#7a7d80` | Colour for muted / de-emphasised content. |
93+
| `accent-tint` | `auto` | Tint of the accent, used behind `#alert`; derived from `accent` by default. |
94+
| `logo-square` | `auto` | Square logo shown beside the slide title; derived from `config-info`'s `logo` by default. |
95+
96+
## Contributing
97+
98+
Contributions are welcome. This repository uses
99+
[mise](https://mise.jdx.dev) to pin tool versions and
100+
[hk](https://hk.jdx.dev) to run formatters and checks:
101+
102+
```sh
103+
mise install # install the pinned tools (Typst, hk, typstyle, ..)
104+
mise exec -- hk run fix # format and auto-fix
105+
mise exec -- hk run check # run checks that cannot be auto-fixed
106+
mise exec -- hk run lint # verify package-submission compliance
107+
```
108+
109+
Please run the formatters before opening a pull request, and open an issue for
110+
larger changes first. Bug reports and feature requests go to the
111+
[issue tracker](https://github.com/Entze/prinzipien/issues).
112+
113+
## Authors and Acknowledgment
114+
115+
- **Lukas Grassauer** — author and maintainer (<lukas@grassauer.eu>).
116+
117+
Prinzipien builds on [Touying](https://touying-typ.github.io/) and follows the
118+
design principles of Jean-luc Doumont's _Trees, maps, and theorems_ (2009).
119+
120+
Parts of this project — code, examples, and documentation — were written with
121+
the assistance of an AI coding agent (Anthropic's Claude Code) under the
122+
author's direction and review. If you would like to audit the prompts see
123+
[`plans`](plans/).
124+
125+
## License
126+
127+
Distributed under the Boost Software License 1.0 (BSL-1.0).
128+
See [`LICENSE.txt`](LICENSE.txt) for the full text.
151 KB
Loading
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
@book{doumont2009,
2+
author = {Doumont, Jean-luc},
3+
title = {Trees, Maps, and Theorems: Effective Communication for
4+
Rational Minds},
5+
publisher = {Principiae},
6+
address = {Kraainem, Belgium},
7+
year = {2009},
8+
}
Lines changed: 141 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
// A small but complete deck following Doumont's canonical structure:
2+
// attention getter -> need -> task -> main message -> preview ->
3+
// points with transitions -> review -> conclusion -> close,
4+
// plus backmatter (Q&A, references).
5+
6+
#import "../lib.typ": *
7+
8+
// Placeholder wordmark standing in for a real logo image.
9+
#let acme-logo = box({
10+
box(
11+
width: .8em,
12+
height: .8em,
13+
baseline: 12.5%,
14+
fill: rgb("#f9ab1a"),
15+
radius: .15em,
16+
)
17+
h(.35em)
18+
text(weight: "bold")[ACME]
19+
})
20+
21+
#show: prinzipien-theme.with(
22+
config-info(
23+
title: [Effective slides carry one message each],
24+
author: [John Doe],
25+
date: datetime.today(),
26+
logo: acme-logo,
27+
),
28+
)
29+
30+
#title-slide()
31+
32+
// Attention getter.
33+
== A slide everyone has seen: six bullets, none remembered
34+
35+
Think of the last talk you attended — which slide can you still recall?
36+
37+
// Need: the gap between actual and desired situation.
38+
== Audiences forget slides that compete with their own titles
39+
40+
Listeners keep one sentence per slide at most; \
41+
decks offer them ten.
42+
43+
// Task.
44+
== This deck walks through a design that fixes the mismatch
45+
46+
Every device shown here is from Doumont's
47+
_Trees, maps, and theorems_ @doumont2009.
48+
49+
// Main message: the one sentence to remember.
50+
== State one message per slide, and design everything around it
51+
52+
The rest of this deck develops three points that make it work.
53+
54+
// Preview: the map of the body.
55+
#preview()
56+
57+
#point(substatement: [Everything is set flush against it])[
58+
A wide left margin structures the slide
59+
]
60+
61+
== The content sits flush against the margin edge
62+
63+
All sizes derive from a small set of shared dimensions.
64+
65+
== The margin holds labels \ for the image on the right
66+
67+
#slide(margin-content: [
68+
#set text(size: .7em)
69+
#v(2em)
70+
A label in the margin
71+
72+
#v(4em)
73+
Another label, further down
74+
])[
75+
// Placeholder for an image, drawn in tints of the accent colour.
76+
#rect(
77+
width: 100%,
78+
height: 80%,
79+
fill: tint(rgb("#f9ab1a"), saturation: 15%),
80+
stroke: none,
81+
align(center + horizon, circle(radius: 3em, fill: tint(rgb("#f9ab1a")))),
82+
)
83+
]
84+
85+
== The margin and the content areas share one horizon
86+
87+
#slide(margin-content: block(
88+
width: 100%,
89+
height: 40%,
90+
fill: tint(rgb("#f9ab1a")),
91+
stroke: rgb("#221f21") + 1pt,
92+
align(center + horizon)[margin \ (accent tint)],
93+
))[
94+
#block(
95+
width: 100%,
96+
height: 80%,
97+
fill: rgb("#f9ab1a"),
98+
stroke: rgb("#221f21") + 1pt,
99+
align(center + horizon)[content \ (accent)],
100+
)
101+
]
102+
103+
#point(substatement: [Tints of it are enough for everything else])[
104+
One accent colour marks what matters
105+
]
106+
107+
== The accent colour carries the emphasis
108+
109+
Use #alert[one accent colour] only, plus tints derived from it.
110+
111+
#point(substatement: [One full sentence, optimally broken])[
112+
The message is the slide title
113+
]
114+
115+
== A full sentence makes the takeaway explicit
116+
117+
The audience reads the title and knows what to remember.
118+
119+
// Review: the map again, leading to the conclusion.
120+
#review()
121+
122+
// Conclusion: what it means to the audience.
123+
== One message per slide is a design decision, not a writing tip
124+
125+
Margin, colour, and title only work because they serve the message.
126+
127+
// Close.
128+
== Your next deck can start from this template
129+
130+
Take the structure, keep your message, drop the bullets.
131+
132+
// Backmatter: numbered with roman numerals, excluded from the total.
133+
#show: appendix
134+
135+
== Questions are welcome
136+
137+
Ask away — or write to john\@example.org.
138+
139+
== References
140+
141+
#bibliography("demo.bib", title: none)
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
@book{doumont2009,
2+
author = {Doumont, Jean-luc},
3+
title = {Trees, Maps, and Theorems: Effective Communication for
4+
Rational Minds},
5+
publisher = {Principiae},
6+
address = {Kraainem, Belgium},
7+
year = {2009},
8+
}
9+
10+
@article{miller1956,
11+
author = {Miller, George A.},
12+
title = {The Magical Number Seven, Plus or Minus Two: Some Limits on
13+
Our Capacity for Processing Information},
14+
journal = {Psychological Review},
15+
volume = {63},
16+
number = {2},
17+
pages = {81--97},
18+
year = {1956},
19+
}
20+
21+
@online{touying,
22+
author = {{Touying contributors}},
23+
title = {Touying: A Powerful Package for Creating Presentation Slides
24+
in Typst},
25+
url = {https://github.com/touying-typ/touying},
26+
year = {2024},
27+
}

0 commit comments

Comments
 (0)