diff --git a/lua/lib/settings.lua b/lua/lib/settings.lua index 3dd079d..3a47827 100644 --- a/lua/lib/settings.lua +++ b/lua/lib/settings.lua @@ -39,6 +39,7 @@ settings["modules"] = { swayosd = true, cliphist = true, pypr = true, + fcitx5 = false, } return require("lua.lib.utils").extend_config(settings, "lua.user.settings") diff --git a/lua/modules/fcitx5.lua b/lua/modules/fcitx5.lua new file mode 100644 index 0000000..9a35cdd --- /dev/null +++ b/lua/modules/fcitx5.lua @@ -0,0 +1,24 @@ +local bind = require("lua.lib.bind") + +local M = {} + +M.binds = { + { + keys = bind.with_leader("CTRL + E"), + dispatcher = hl.dsp.exec_cmd("pkill fcitx5 -9;sleep 1;fcitx5 -d"), + desc = "restart fcitx5", + }, +} + +M.autostart = { + function() + hl.exec_cmd("fcitx5 -d") + end, +} + +M.envs = { + QT_IM_MODULE = "fcitx", + XMODIFIERS = "@im=fcitx", +} + +return M