From 64c5228c0828fff0c94c1d42f7225115c299ae08 Mon Sep 17 00:00:00 2001 From: Antoine Martin Date: Tue, 4 May 2021 16:31:37 +0200 Subject: [PATCH] i3, sway: description and example for font options (#1980) Adds an example to the root fonts submodule because the documentation doesn't know how to handle `type = with types; either (listOf str) fontOptions;` --- .../window-managers/i3-sway/lib/options.nix | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/modules/services/window-managers/i3-sway/lib/options.nix b/modules/services/window-managers/i3-sway/lib/options.nix index 252562073..c21ad1ac3 100644 --- a/modules/services/window-managers/i3-sway/lib/options.nix +++ b/modules/services/window-managers/i3-sway/lib/options.nix @@ -95,6 +95,14 @@ let fonts = mkOption { type = with types; either (listOf str) fontOptions; default = { }; + example = literalExample '' + { + names = [ "DejaVu Sans Mono" "FontAwesome5Free" ]; + style = "Bold Semi-Condensed"; + size = 11.0; + } + ''; + description = "Font configuration for this bar."; }; extraConfig = mkOption { @@ -339,6 +347,14 @@ in { fonts = mkOption { type = with types; either (listOf str) fontOptions; default = { }; + example = literalExample '' + { + names = [ "DejaVu Sans Mono" "FontAwesome5Free" ]; + style = "Bold Semi-Condensed"; + size = 11.0; + } + ''; + description = "Font configuration for window titles, nagbar..."; }; window = mkOption {