ibus: add ibusEngine type and nest panel option
the panel option was outside of the 'i18n.inputMethod.ibus' option
This commit is contained in:
parent
6303bd7085
commit
def6605523
|
@ -6,6 +6,12 @@ let
|
||||||
im = config.i18n.inputMethod;
|
im = config.i18n.inputMethod;
|
||||||
cfg = im.ibus;
|
cfg = im.ibus;
|
||||||
impanel = optionalString (cfg.panel != null) "--panel=${cfg.panel}";
|
impanel = optionalString (cfg.panel != null) "--panel=${cfg.panel}";
|
||||||
|
ibusEngine = types.package // {
|
||||||
|
name = "ibus-engine";
|
||||||
|
check = x:
|
||||||
|
(lib.types.package.check x)
|
||||||
|
&& (attrByPath [ "meta" "isIbusEngine" ] false x);
|
||||||
|
};
|
||||||
ibusPackage = pkgs.ibus-with-plugins.override { inherit (cfg) engines; };
|
ibusPackage = pkgs.ibus-with-plugins.override { inherit (cfg) engines; };
|
||||||
in {
|
in {
|
||||||
options = {
|
options = {
|
||||||
|
@ -18,15 +24,15 @@ in {
|
||||||
Enabled IBus engines.
|
Enabled IBus engines.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
panel = mkOption {
|
||||||
panel = mkOption {
|
type = with types; nullOr path;
|
||||||
type = with types; nullOr path;
|
default = null;
|
||||||
default = null;
|
example = literalExpression ''
|
||||||
example = literalExpression ''
|
"''${pkgs.plasma5Packages.plasma-desktop}/libexec/kimpanel-ibus-panel"'';
|
||||||
"''${pkgs.plasma5Packages.plasma-desktop}/libexec/kimpanel-ibus-panel"'';
|
description = ''
|
||||||
description = ''
|
Replace the IBus panel with another panel.
|
||||||
Replace the IBus panel with another panel.
|
'';
|
||||||
'';
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue