1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-12-24 10:49:48 +01:00

Add blur options to compton

This commit is contained in:
Anton Plotnikov 2018-04-15 05:19:37 +03:00 committed by Nikita Uvarov
parent 5bdebf5ab0
commit 8ff7d934b2
No known key found for this signature in database
GPG key ID: F7A5FB3A7C10EF96

View file

@ -24,7 +24,15 @@ let
shadow-offset-y = ${toString (elemAt cfg.shadowOffsets 1)};
shadow-opacity = ${cfg.shadowOpacity};
shadow-exclude = ${toJSON cfg.shadowExclude};
'' +
optionalString cfg.blur ''
# blur
blur-background = true;
blur-background-exclude = ${toJSON cfg.blurExclude};
no-dock-blur = ${toString cfg.noDockBlur};
'' + ''
# opacity
active-opacity = ${cfg.activeOpacity};
inactive-opacity = ${cfg.inactiveOpacity};
@ -42,6 +50,35 @@ in {
options.services.compton = {
enable = mkEnableOption "Compton X11 compositor";
blur = mkOption {
type = types.bool;
default = false;
description = ''
Enable background blur on transparent windows.
'';
};
noDockBlur = mkOption {
type = types.bool;
default = false;
description = ''
Avoid blur on docks.
'';
};
blurExclude = mkOption {
type = types.listOf types.str;
default = [];
example = [
"class_g = 'slop'"
"class_i = 'polybar'"
];
description = ''
List of windows to exclude background blur.
See <literal>compton(1)</literal> man page for more examples.
'';
};
fade = mkOption {
type = types.bool;
default = false;