ibus: format

This commit is contained in:
nyadiia 2024-04-23 13:27:01 -05:00
parent ed922f2ddf
commit 5de2a2e3e9
No known key found for this signature in database
GPG key ID: 229718FDC160E880
2 changed files with 6 additions and 7 deletions

View file

@ -22,7 +22,8 @@ let
''; '';
in { in {
imports = [ ./fcitx5.nix ./hime.nix ./kime.nix ./nabi.nix ./uim.nix ./ibus.nix ]; imports =
[ ./fcitx5.nix ./hime.nix ./kime.nix ./nabi.nix ./uim.nix ./ibus.nix ];
options.i18n = { options.i18n = {
inputMethod = { inputMethod = {

View file

@ -7,8 +7,7 @@ let
cfg = im.ibus; cfg = im.ibus;
impanel = optionalString (cfg.panel != null) "--panel=${cfg.panel}"; impanel = optionalString (cfg.panel != null) "--panel=${cfg.panel}";
ibusPackage = pkgs.ibus-with-plugins.override { inherit (cfg) engines; }; ibusPackage = pkgs.ibus-with-plugins.override { inherit (cfg) engines; };
in in {
{
options = { options = {
i18n.inputMethod.ibus = { i18n.inputMethod.ibus = {
engines = mkOption { engines = mkOption {
@ -23,7 +22,8 @@ in
panel = mkOption { panel = mkOption {
type = with types; nullOr path; type = with types; nullOr path;
default = null; default = null;
example = literalExpression ''"''${pkgs.plasma5Packages.plasma-desktop}/libexec/kimpanel-ibus-panel"''; example = literalExpression ''
"''${pkgs.plasma5Packages.plasma-desktop}/libexec/kimpanel-ibus-panel"'';
description = '' description = ''
Replace the IBus panel with another panel. Replace the IBus panel with another panel.
''; '';
@ -47,9 +47,7 @@ in
services.dbus.packages = [ ibusPackage ]; services.dbus.packages = [ ibusPackage ];
xdg.portal.extraPortals = mkIf config.xdg.portal.enable [ xdg.portal.extraPortals = mkIf config.xdg.portal.enable [ ibusPackage ];
ibusPackage
];
systemd.user.services.ibus-daemon = { systemd.user.services.ibus-daemon = {
Unit = { Unit = {