i3-sway: add option trayPadding (tray_padding) for bars (#3829)
This commit is contained in:
parent
d1d0ee37c3
commit
68eaf4b577
|
@ -69,8 +69,8 @@ rec {
|
||||||
};
|
};
|
||||||
|
|
||||||
barStr = { id, fonts, mode, hiddenState, position, workspaceButtons
|
barStr = { id, fonts, mode, hiddenState, position, workspaceButtons
|
||||||
, workspaceNumbers, command, statusCommand, colors, trayOutput, extraConfig
|
, workspaceNumbers, command, statusCommand, colors, trayOutput, trayPadding
|
||||||
, ... }:
|
, extraConfig, ... }:
|
||||||
let colorsNotNull = lib.filterAttrs (n: v: v != null) colors != { };
|
let colorsNotNull = lib.filterAttrs (n: v: v != null) colors != { };
|
||||||
in ''
|
in ''
|
||||||
bar {
|
bar {
|
||||||
|
@ -93,6 +93,8 @@ rec {
|
||||||
lib.hm.booleans.yesNo (!workspaceNumbers)
|
lib.hm.booleans.yesNo (!workspaceNumbers)
|
||||||
}")
|
}")
|
||||||
(optionalString (trayOutput != null) "tray_output ${trayOutput}")
|
(optionalString (trayOutput != null) "tray_output ${trayOutput}")
|
||||||
|
(optionalString (trayPadding != null)
|
||||||
|
"tray_padding ${toString trayPadding}")
|
||||||
(optionals colorsNotNull (indent
|
(optionals colorsNotNull (indent
|
||||||
(lists.subtractLists [ "" null ] [
|
(lists.subtractLists [ "" null ] [
|
||||||
"colors {"
|
"colors {"
|
||||||
|
|
|
@ -293,6 +293,15 @@ let
|
||||||
default = "primary";
|
default = "primary";
|
||||||
description = "Where to output tray.";
|
description = "Where to output tray.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
trayPadding = mkNullableOption {
|
||||||
|
type = types.int;
|
||||||
|
default = null;
|
||||||
|
description = ''
|
||||||
|
Sets the pixel padding of the system tray.
|
||||||
|
This padding will surround the tray on all sides and between each item.
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue