docs/src/features/themes/introduction.md
presenterm tries to be as configurable as possible, allowing users to create presentations that look exactly how they want them to look like. The tool ships with a set of built-in themes but users can be created by users in their local setup and imported in their presentations.
There's various ways of setting the theme you want in your presentation:
Passing in the --theme parameter when running presenterm to select one of the built-in themes.
The presentation's markdown file can contain a front matter that specifies the theme to use. This comes in 3 flavors:
Using a built-in theme name makes your presentation use that one regardless of what the default or what the --theme
option specifies:
---
theme:
name: dark
---
Built-in light/dark theme detection allows you to define a different theme for each variant:
---
theme:
# The theme used if your terminal is using light colors.
light: light
# The theme used if your terminal is using dark colors.
dark: dark
---
You can define a theme file in yaml format somewhere in your filesystem and reference it within the presentation:
---
theme:
path: /home/me/Documents/epic-theme.yaml
---
You can partially/completely override the theme in use from within the presentation:
---
theme:
override:
default:
colors:
foreground: "beeeff"
---
This lets you:
A few built-in themes are bundled with the application binary, meaning you don't need to have any external files available to use them. These are packed as part of the build process as a binary blob and are decoded on demand only when used.
Currently, the following themes are supported:
catppuccin-lattecatppuccin-frappecatppuccin-macchiatocatppuccin-mochadark: A dark theme.gruvbox-dark: A theme inspired by the colors used in gruvbox.light: A light theme.terminal-dark: A theme that uses your terminals color and looks best if your terminal uses a dark color scheme. This
means if your terminal background is e.g. transparent, or uses an image, the presentation will inherit that.terminal-light: The same as terminal-dark but works best if your terminal uses a light color scheme.tokyonight-moontokyonight-daytokyonight-nighttokyonight-stormAll built-in themes can be tested by using the --list-themes parameter:
presenterm --list-themes
This will run a presentation where the same content is rendered using a different theme in each slide:
On startup, presenterm will look into the themes directory under the configuration
directory (e.g. ~/.config/presenterm/themes in Linux) and will load any .yaml
file as a theme and make it available as if it was a built-in theme. This means you can use it as an argument to the
--theme parameter, use it in the theme.name property in a presentation's front matter, etc.