From 71c3fb6eb0767923335662aa33a06f983c2fbeae Mon Sep 17 00:00:00 2001 From: Heitor Augusto Date: Fri, 5 Jul 2024 05:27:55 -0300 Subject: [PATCH] Standardize Enums Options for widget-specific options (#246) --- modules/widgets/application-title-bar.nix | 46 +++++++++++------------ 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/modules/widgets/application-title-bar.nix b/modules/widgets/application-title-bar.nix index 5999bf7..d1113c2 100644 --- a/modules/widgets/application-title-bar.nix +++ b/modules/widgets/application-title-bar.nix @@ -26,8 +26,8 @@ let fontType = types.submodule { options = { bold = mkBoolOption "Enable bold text."; - fit = mkEnumOption [ "FixedSize" "HorizontalFit" "VerticalFit" "Fit" ] // { - example = "FixedSize"; + fit = mkEnumOption [ "fixedSize" "horizontalFit" "verticalFit" "fit" ] // { + example = "fixedSize"; description = "The mode of the size of the font."; }; size = mkOption { @@ -98,8 +98,8 @@ in description = "The vertical alignment of the widget."; apply = convertVerticalAlignment; }; - showDisabledElements = mkEnumOption [ "Deactivated" "HideKeepSpace" "Hide" ] // { - example = "Deactivated"; + showDisabledElements = mkEnumOption [ "deactivated" "hideKeepSpace" "hide" ] // { + example = "deactivated"; description = "How to show the elements when the widget is disabled."; }; fillFreeSpace = mkBoolOption "Whether the widget should fill the free space on the panel."; @@ -123,8 +123,8 @@ in }; }; windowControlButtons = { - iconSource = mkEnumOption [ "Plasma" "Breeze" "Aurorae" "Oxygen" ] // { - example = "Plasma"; + iconSource = mkEnumOption [ "plasma" "breeze" "aurorae" "oxygen" ] // { + example = "plasma"; description = '' The icon source for the control buttons. @@ -192,15 +192,15 @@ in default = null; description = "The text to show when the window title is undefined."; }; - source = mkEnumOption [ "AppName" "Decoration" "GenericAppName" "AlwaysUndefined" ] // { - example = "AppName"; + source = mkEnumOption [ "appName" "decoration" "genericAppName" "alwaysUndefined" ] // { + example = "appName"; description = '' The source of the window title. - - AppName: The name of the application - - Decoration: The title of the window decoration - - GenericAppName: The generic name of the application - - AlwaysUndefined: Always show the undefined title + - appName: The name of the application + - decoration: The title of the window decoration + - genericAppName: The generic name of the application + - alwaysUndefined: Always show the undefined title ''; }; margins = mkOption { @@ -241,27 +241,27 @@ in The elements to show in the widget for maximized windows. ''; }; - source = mkEnumOption [ "AppName" "Decoration" "GenericAppName" "AlwaysUndefined" ] // { - example = "AppName"; + source = mkEnumOption [ "appName" "decoration" "genericAppName" "alwaysUndefined" ] // { + example = "appName"; description = '' The source of the window title for maximized windows. - - AppName: The name of the application - - Decoration: The title of the window decoration - - GenericAppName: The generic name of the application - - AlwaysUndefined: Always show the undefined title + - appName: The name of the application + - decoration: The title of the window decoration + - genericAppName: The generic name of the application + - alwaysUndefined: Always show the undefined title ''; }; }; behavior = { - activeTaskSource = mkEnumOption [ "ActiveTask" "LastActiveTask" "LastActiveMaximized" ] // { - example = "ActiveTask"; + activeTaskSource = mkEnumOption [ "activeTask" "lastActiveTask" "lastActiveMaximized" ] // { + example = "activeTask"; description = '' The source of the active task. - - ActiveTask: The active task - - LastActiveTask: The last active task - - LastActiveMaximized: The last active maximized task + - activeTask: The active task + - lastActiveTask: The last active task + - lastActiveMaximized: The last active maximized task ''; }; filterByActivity = mkBoolOption "Whether to filter the tasks by activity.";