Files
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

47 lines
846 B
Nix

{
config,
pkgs,
lib,
...
}:
let
imcfg = config.i18n.inputMethod;
cfg = imcfg.uim;
in
{
options = {
i18n.inputMethod.uim = {
toolbar = lib.mkOption {
type = lib.types.enum [
"gtk"
"gtk3"
"gtk-systray"
"gtk3-systray"
"qt5"
];
default = "gtk";
example = "gtk-systray";
description = ''
selected UIM toolbar.
'';
};
};
};
config = lib.mkIf (imcfg.enable && imcfg.type == "uim") {
i18n.inputMethod.package = pkgs.uim;
environment.variables = {
GTK_IM_MODULE = "uim";
QT_IM_MODULE = "uim";
XMODIFIERS = "@im=uim";
};
services.xserver.displayManager.sessionCommands = ''
${pkgs.uim}/bin/uim-xim &
${pkgs.uim}/bin/uim-toolbar-${cfg.toolbar} &
'';
};
}