2016-12-14 13:05:23 +01:00
|
|
|
{ config, lib, ... }:
|
|
|
|
|
|
|
|
with lib;
|
|
|
|
|
2017-12-31 11:44:02 +09:00
|
|
|
let
|
2022-08-29 15:39:16 -07:00
|
|
|
# Should only be used with options that previously used floats defined as strings.
|
|
|
|
inherit (config.lib.defaults.types) floatWithDeprecationError;
|
2017-12-31 11:44:02 +09:00
|
|
|
in {
|
2024-11-21 21:40:11 -06:00
|
|
|
imports = [
|
|
|
|
(mkRenamedOptionModule [ "system" "defaults" "dock" "expose-group-by-app" ] [ "system" "defaults" "dock" "expose-group-apps" ])
|
|
|
|
];
|
|
|
|
|
2016-12-14 13:05:23 +01:00
|
|
|
options = {
|
|
|
|
|
2022-08-20 17:32:11 +02:00
|
|
|
system.defaults.dock.appswitcher-all-displays = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-08-20 17:32:11 +02:00
|
|
|
Whether to display the appswitcher on all displays or only the main one. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2016-12-14 13:05:23 +01:00
|
|
|
system.defaults.dock.autohide = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2024-09-04 23:07:41 +02:00
|
|
|
Whether to automatically hide and show the dock. The default is false.
|
2016-12-14 16:22:39 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.autohide-delay = mkOption {
|
2022-08-29 15:39:16 -07:00
|
|
|
type = types.nullOr floatWithDeprecationError;
|
2016-12-14 16:22:39 +01:00
|
|
|
default = null;
|
2022-08-29 15:39:16 -07:00
|
|
|
example = 0.24;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Sets the speed of the autohide delay. The default is given in the example.
|
2016-12-14 16:22:39 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.autohide-time-modifier = mkOption {
|
2022-08-29 15:39:16 -07:00
|
|
|
type = types.nullOr floatWithDeprecationError;
|
2017-12-28 09:55:31 +09:00
|
|
|
default = null;
|
2022-08-29 15:39:16 -07:00
|
|
|
example = 1.0;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Sets the speed of the animation when hiding/showing the Dock. The default is given in the example.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.dashboard-in-overlay = mkOption {
|
2016-12-14 16:22:39 +01:00
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2021-10-21 20:36:55 +11:00
|
|
|
Whether to hide Dashboard as a Space. The default is false.
|
2016-12-14 16:22:39 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.enable-spring-load-actions-on-all-items = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
2017-06-25 16:38:48 -04:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2021-10-21 20:36:55 +11:00
|
|
|
Enable spring loading for all Dock items. The default is false.
|
2017-12-28 09:55:31 +09:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.expose-animation-duration = mkOption {
|
2022-08-29 15:39:16 -07:00
|
|
|
type = types.nullOr floatWithDeprecationError;
|
2017-12-28 09:55:31 +09:00
|
|
|
default = null;
|
2022-08-29 15:39:16 -07:00
|
|
|
example = 1.0;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Sets the speed of the Mission Control animations. The default is given in the example.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-11-21 21:40:11 -06:00
|
|
|
system.defaults.dock.expose-group-apps = mkOption {
|
2017-12-28 09:55:31 +09:00
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2024-11-21 21:40:11 -06:00
|
|
|
Whether to group windows by application in Mission Control's Exposé. The default is false.
|
2017-12-28 09:55:31 +09:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.launchanim = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Animate opening applications from the Dock. The default is true.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.mineffect = mkOption {
|
|
|
|
type = types.nullOr (types.enum [ "genie" "suck" "scale" ]);
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Set the minimize/maximize window effect. The default is genie.
|
2017-06-25 16:38:48 -04:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2016-12-14 16:22:39 +01:00
|
|
|
system.defaults.dock.minimize-to-application = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2016-12-14 16:22:39 +01:00
|
|
|
Whether to minimize windows into their application icon. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.mouse-over-hilite-stack = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Enable highlight hover effect for the grid view of a stack in the Dock.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2016-12-14 16:22:39 +01:00
|
|
|
system.defaults.dock.mru-spaces = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2016-12-14 16:22:39 +01:00
|
|
|
Whether to automatically rearrange spaces based on most recent use. The default is true.
|
|
|
|
'';
|
2016-12-14 13:05:23 +01:00
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.orientation = mkOption {
|
|
|
|
type = types.nullOr (types.enum [ "bottom" "left" "right" ]);
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Position of the dock on screen. The default is "bottom".
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2023-03-20 09:22:41 -07:00
|
|
|
system.defaults.dock.persistent-apps = mkOption {
|
|
|
|
type = types.nullOr (types.listOf (types.either types.path types.str));
|
|
|
|
default = null;
|
|
|
|
example = [ "/Applications/Safari.app" "/System/Applications/Utilities/Terminal.app" ];
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2023-03-20 09:22:41 -07:00
|
|
|
Persistent applications in the dock.
|
|
|
|
'';
|
|
|
|
apply = value:
|
|
|
|
if !(isList value)
|
|
|
|
then value
|
|
|
|
else map (app: { tile-data = { file-data = { _CFURLString = app; _CFURLStringType = 0; }; }; }) value;
|
|
|
|
};
|
|
|
|
|
2024-04-08 14:09:25 +01:00
|
|
|
system.defaults.dock.persistent-others = mkOption {
|
|
|
|
type = types.nullOr (types.listOf (types.either types.path types.str));
|
|
|
|
default = null;
|
|
|
|
example = [ "~/Documents" "~/Downloads" ];
|
2024-05-16 12:48:56 -04:00
|
|
|
description = ''
|
2024-04-08 14:09:25 +01:00
|
|
|
Persistent folders in the dock.
|
|
|
|
'';
|
|
|
|
apply = value:
|
|
|
|
if !(isList value)
|
|
|
|
then value
|
2024-05-15 07:49:00 +01:00
|
|
|
else map (folder: { tile-data = { file-data = { _CFURLString = "file://" + folder; _CFURLStringType = 15; }; }; tile-type = if strings.hasInfix "." (last (splitString "/" folder)) then "file-tile" else "directory-tile"; }) value;
|
2024-04-08 14:09:25 +01:00
|
|
|
};
|
|
|
|
|
2024-11-12 01:24:22 +00:00
|
|
|
system.defaults.dock.scroll-to-open = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
|
|
|
description = ''
|
|
|
|
Scroll up on a Dock icon to show all Space's opened windows for an app, or open stack. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.show-process-indicators = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Show indicator lights for open applications in the Dock. The default is true.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.showhidden = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Whether to make icons of hidden applications tranclucent. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2018-10-11 11:58:08 +09:00
|
|
|
system.defaults.dock.show-recents = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2018-10-11 11:58:08 +09:00
|
|
|
Show recent applications in the dock. The default is true.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-09-28 23:28:34 -05:00
|
|
|
system.defaults.dock.slow-motion-allowed = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-09-30 15:12:13 +01:00
|
|
|
description = ''
|
2024-09-28 23:28:34 -05:00
|
|
|
Allow for slow-motion minimize effect while holding Shift key. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
system.defaults.dock.static-only = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Show only open applications in the Dock. The default is false.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.tilesize = mkOption {
|
|
|
|
type = types.nullOr types.int;
|
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2017-12-28 09:55:31 +09:00
|
|
|
Size of the icons in the dock. The default is 64.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2022-12-18 23:50:26 +01:00
|
|
|
system.defaults.dock.magnification = mkOption {
|
|
|
|
type = types.nullOr types.bool;
|
2023-07-25 18:35:19 +02:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2023-07-24 21:16:04 +02:00
|
|
|
Magnify icon on hover. The default is false.
|
2022-12-18 23:50:26 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.largesize = mkOption {
|
2023-07-25 18:35:19 +02:00
|
|
|
type = types.nullOr (types.ints.between 16 128);
|
2022-12-18 23:50:26 +01:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2023-07-25 18:35:19 +02:00
|
|
|
Magnified icon size on hover. The default is 16.
|
2022-12-18 23:50:26 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2022-01-09 01:58:14 +01:00
|
|
|
system.defaults.dock.wvous-tl-corner = mkOption {
|
2022-01-14 00:58:35 +01:00
|
|
|
type = types.nullOr types.ints.positive;
|
2022-01-09 01:58:14 +01:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-01-09 01:58:14 +01:00
|
|
|
Hot corner action for top left corner. Valid values include:
|
|
|
|
|
2023-06-22 09:05:03 +01:00
|
|
|
* `1`: Disabled
|
|
|
|
* `2`: Mission Control
|
|
|
|
* `3`: Application Windows
|
|
|
|
* `4`: Desktop
|
|
|
|
* `5`: Start Screen Saver
|
|
|
|
* `6`: Disable Screen Saver
|
|
|
|
* `7`: Dashboard
|
|
|
|
* `10`: Put Display to Sleep
|
|
|
|
* `11`: Launchpad
|
|
|
|
* `12`: Notification Center
|
|
|
|
* `13`: Lock Screen
|
|
|
|
* `14`: Quick Note
|
2022-01-09 01:58:14 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.wvous-bl-corner = mkOption {
|
2022-01-14 00:58:35 +01:00
|
|
|
type = types.nullOr types.ints.positive;
|
2022-01-09 01:58:14 +01:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-01-09 01:58:14 +01:00
|
|
|
Hot corner action for bottom left corner. Valid values include:
|
|
|
|
|
2023-06-22 09:05:03 +01:00
|
|
|
* `1`: Disabled
|
|
|
|
* `2`: Mission Control
|
|
|
|
* `3`: Application Windows
|
|
|
|
* `4`: Desktop
|
|
|
|
* `5`: Start Screen Saver
|
|
|
|
* `6`: Disable Screen Saver
|
|
|
|
* `7`: Dashboard
|
|
|
|
* `10`: Put Display to Sleep
|
|
|
|
* `11`: Launchpad
|
|
|
|
* `12`: Notification Center
|
|
|
|
* `13`: Lock Screen
|
|
|
|
* `14`: Quick Note
|
2022-01-09 01:58:14 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.wvous-tr-corner = mkOption {
|
2022-01-14 00:58:35 +01:00
|
|
|
type = types.nullOr types.ints.positive;
|
2022-01-09 01:58:14 +01:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-01-09 01:58:14 +01:00
|
|
|
Hot corner action for top right corner. Valid values include:
|
|
|
|
|
2023-06-22 09:05:03 +01:00
|
|
|
* `1`: Disabled
|
|
|
|
* `2`: Mission Control
|
|
|
|
* `3`: Application Windows
|
|
|
|
* `4`: Desktop
|
|
|
|
* `5`: Start Screen Saver
|
|
|
|
* `6`: Disable Screen Saver
|
|
|
|
* `7`: Dashboard
|
|
|
|
* `10`: Put Display to Sleep
|
|
|
|
* `11`: Launchpad
|
|
|
|
* `12`: Notification Center
|
|
|
|
* `13`: Lock Screen
|
|
|
|
* `14`: Quick Note
|
2022-01-09 01:58:14 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.dock.wvous-br-corner = mkOption {
|
2022-01-14 00:58:35 +01:00
|
|
|
type = types.nullOr types.ints.positive;
|
2022-01-09 01:58:14 +01:00
|
|
|
default = null;
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-01-09 01:58:14 +01:00
|
|
|
Hot corner action for bottom right corner. Valid values include:
|
|
|
|
|
2023-06-22 09:05:03 +01:00
|
|
|
* `1`: Disabled
|
|
|
|
* `2`: Mission Control
|
|
|
|
* `3`: Application Windows
|
|
|
|
* `4`: Desktop
|
|
|
|
* `5`: Start Screen Saver
|
|
|
|
* `6`: Disable Screen Saver
|
|
|
|
* `7`: Dashboard
|
|
|
|
* `10`: Put Display to Sleep
|
|
|
|
* `11`: Launchpad
|
|
|
|
* `12`: Notification Center
|
|
|
|
* `13`: Lock Screen
|
|
|
|
* `14`: Quick Note
|
2022-01-09 01:58:14 +01:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2017-12-28 09:55:31 +09:00
|
|
|
};
|
2016-12-14 13:05:23 +01:00
|
|
|
}
|