From d61a1a5ec3966b6a555242d062163e0ea31c56b1 Mon Sep 17 00:00:00 2001 From: Jaden Date: Tue, 4 Oct 2022 14:33:45 -0700 Subject: [PATCH] doc: add theme inheritance example (#4096) --- book/src/themes.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/book/src/themes.md b/book/src/themes.md index b92b6d7b1da35..4cded68fe4ed2 100644 --- a/book/src/themes.md +++ b/book/src/themes.md @@ -89,6 +89,21 @@ Less common modifiers might not be supported by your terminal emulator. | `hidden` | | `crossed_out` | +### Inheritance + +Extend upon other themes by setting the `inherits` property to an existing theme. + +```toml +inherits = "boo_berry" + +# Override the theming for "keyword"s: +"keyword" = { fg = "gold" } + +# Override colors in the palette: +[palette] +berry = "#2A2A4D" +``` + ### Scopes The following is a list of scopes available to use for styling.