Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Themes

日本語 · Contents

You can pick one of twelve color themes for the screen (or auto, which follows the terminal background). Starting from a theme, you can also choose the accent and other colors yourself (Custom). Only the colors change; text and marks (* for a pending change, > for the selected row, and so on) stay the same.

How to choose

The quickest way is on screen. Press o to open the view settings, 8 to go to the Look section, and Enter on the Theme row to get the list. Pick one and press Apply: the screen changes right away.

“Save to” at the top of the section decides where the choice is kept. With the default, global, every table opens in that theme (it goes to ui.toml). Choose this workspace, this table or this view to change only that place. The note next to the theme, such as “(global)” or “(marker)”, tells where the current colors come from.

A theme written in a ledger’s marker (.mdgrid/workspace.toml) does not override yours. The marker’s theme is what the ledger’s author suggests, and you get it only until you pick something yourself.

Writing it in the config file (~/.config/mdgrid/config.toml) works the same way:

[look]
theme = "nord"

The rules for each place are in A look per workspace, table or view.

To try one before changing your config, pass a sample config with --config (from the repository root):

mdgrid --config examples/themes/nord.toml /tmp/mdgrid-sample/Tasks.base
NameLook
default (default)The current look: terminal colors, reverse video for the selection and bands
nordCalm blues
solarized-lightA light background
draculaPurple and pink accents
gruvboxWarm browns and orange
pink-monsterNeon pink and lime on dark magenta
dozy-pinkSoft pink and cream
sumiDark ink, soft grays and a teal accent
slateSlate with a violet accent
saasLight gray with an indigo accent
saas-darkThe dark version of saas
paperA light background with a blue accent
autosaas on a light terminal background, sumi on a dark one. Pick your own pair with theme = { light = "paper", dark = "saas-dark" }

Choose your own colors (Custom)

The last entry in the theme list, Custom, keeps the current theme as a base and lets you change its sixteen role colors one by one: background, text, accent, selected row and so on. Use it to keep a theme you like and give it your own accent.

Press Enter on a role row to see sample colors (fourteen, such as orange and teal). For any other color, pick “#rrggbb (type a color)” at the end of the list and type something like #e0a458. “Theme’s color” puts the role back to the base theme’s color.

Apply keeps the base theme and only the colors you changed. Saved globally, ui.toml looks like this:

[look]
theme = "sumi"

[look.colors]
accent = "#ea8c34"

A look with changed colors shows as “Custom (from sumi)” in the Theme row. Picking a named theme again drops the changed colors. Save as a template to keep the colors too.

default — The default look

The current look: terminal colors, reverse video for the selection and bands. This is also what you get with no setting.

nord — Nord

Calm blues. Config: theme = "nord".

solarized-light — Solarized Light

A light background. Config: theme = "solarized-light".

dracula — Dracula

Purple and pink accents. Config: theme = "dracula".

gruvbox — Gruvbox

Warm browns and orange. Config: theme = "gruvbox".

pink-monster — Pink Monster

Neon pink and lime on dark magenta. Config: theme = "pink-monster".

dozy-pink — Dozy Pink

Soft pink and cream. Config: theme = "dozy-pink".

sumi — Sumi

Dark ink, soft grays and a teal accent. Setting: theme = "sumi".

slate — Slate

Slate with a violet accent. Setting: theme = "slate".

saas — SaaS

Light gray with an indigo accent. Setting: theme = "saas".

saas-dark — SaaS Dark

The dark version of saas. Setting: theme = "saas-dark".

paper — Paper

A light background with a blue accent. Setting: theme = "paper".

Notes

  • With NO_COLOR, --no-color, color = false or TERM=dumb, no colors are used even if a theme is set.
  • On terminals without true color (COLORTERM is not truecolor), the nearest 256 colors are used.
  • An unknown name gives a warning at startup and opens with default.
  • The bottom-right cell is never painted, to avoid the terminal’s automatic wrap. On light themes the terminal’s own background shows there.
  • Zebra stripes ([display] zebra = true) use the theme’s colors too; the samples other than default are taken with them on.
  • Every setting is listed in Configuration.