前言
Ubuntu 24.04 LTS 作为最新的长期支持版本,默认使用 Fcitx5 输入法框架,而搜狗输入法目前仍然基于 Fcitx4 框架。本教程将详细介绍如何在 Ubuntu 24.04 上成功安装搜狗输入法,并解决常见的兼容性问题。
环境说明
- 系统版本:Ubuntu 24.04 LTS
- 搜狗输入法版本:sogoupinyin_4.2.1.145_amd64.deb
- 输入法框架:Fcitx4(需要从 Fcitx5 降级)
安装步骤
第一步:系统环境准备
由于 Ubuntu 24.04 默认使用 Fcitx5,而搜狗输入法需要 Fcitx4 框架,我们需要先卸载 Fcitx5 并安装 Fcitx4。
# 更新系统软件包
sudo apt update
# 卸载 Fcitx5 和 IBus(如果存在)
sudo apt remove --purge fcitx5* ibus*
# 清理系统残留
sudo apt autoremove && sudo apt autoclean
# 安装 Fcitx4 输入法框架
sudo apt install fcitx
# 设置 Fcitx 开机自启动
sudo cp /usr/share/applications/fcitx.desktop /etc/xdg/autostart/
第二步:配置语言支持
- 打开系统设置:
Settings→Region & Language - 点击
Manage Installed Languages - 在弹出的'语言支持'窗口中:
- 点击
Install / Remove Languages... - 勾选
Chinese (simplified),点击Apply - 在
Keyboard input method system下拉菜单中选择fcitx - 点击
Apply System-Wide
- 点击
注意:如果在键盘输入法系统中没有"fcitx"选项,说明第一步的安装可能有问题,请重新执行 sudo apt install fcitx。
第三步:下载搜狗输入法
前往官方下载页面:https://shurufa.sogou.com/linux
- 选择
Linux 个人版 - 选择
X86_64架构 - 下载
sogoupinyin_4.2.1.145_amd64.deb安装包
或者使用命令行直接下载:
# 创建下载目录
mkdir -p ~/Downloads/sogou
~/Downloads/sogou
wget https://ime.sogoucdn.com/202308071026/sogoupinyin_4.2.1.145_amd64.deb

