详尽Ubuntu18安装搜狗输⼊法教程0x01:安装fcitx
命令⾏执⾏
sudo apt-get install fcitx fcitx-table-wbpy
0x02:设置系统输⼊法
已⽀持Ubuntu1604、1804、1910、2004、2010
各系统安装步骤可能略有不同,以Ubuntu1804为例。
1、添加中⽂语⾔⽀持
打开 系统设置——区域和语⾔——管理已安装的语⾔——在“语⾔”tab下——点击“添加或删除语⾔”
弹出“已安装语⾔”窗⼝,勾选中⽂(简体),点击应⽤
回到“语⾔⽀持”窗⼝,在键盘输⼊法系统中,选择“fcitx”
注:
如果在键盘输⼊法系统中,没有“fcitx”选项时,建议先打开终端⼿动安装fcitx:sudo apt-get install fcitx
等安装成功之后再执⾏上述步骤
点击“应⽤到整个系统”,关闭窗⼝,重启电脑
2、通过命令⾏安装搜狗输⼊法
sudo dpkg -i sogoupinyin_版本号_
注:
如果安装过程中提⽰缺少相关依赖,则执⾏如下命令解决:
sudo apt -f install
3、笔者实践过程:
输⼊
sudo dpkg -i sogoupinyin_2.4.0.3469_amd64.deb
输出
Selecting previously unselected package sogoupinyin. (Reading database ... 285619 files and directories currently installed.) Preparing to unpack sogoupinyin_2.4.0.3469_amd64.deb ... Unpacking sogoupinyin (2.4.0.3469) ... dpkg: dependency problems prevent configuration of sogoupinyin: sogoupinyin depends on fcitx-libs | libfcitx-qt0; however: Package fcitx-libs is not installed. Package libfcitx-qt0 is not installed. sogoupinyin depends on libqt5qml5; however: Package libqt5qml5 is not installed. sogoupinyin depends on libqt5quick5; however: Package libqt5quick5 is not installed. sogoupinyin depends on
libqt5quickwidgets5; however: Package libqt5quickwidgets5 is not installed. sogoupinyin depends on qml-module-qtquick2; however: Package qml-module-qtquick2 is not installed. dpkg: error processin
g package sogoupinyin (--install): dependency problems - leaving unconfigured Processing triggers for gnome-menus (3.13.3-11ubuntu1.1) ... Processing triggers for desktop-file-utils (0.23-1ubuntu3.18.04.2) ... Processing triggers for mime-support (3.60ubuntu1) ... Processing triggers
for  (0.17-2) ... Errors were encountered while processing: sogoupinyin
输⼊
sudo apt install -f
输出
Reading Done Building dependency tree Reading Done Done The following packages were automatically installed and are no longer required: linux-headers-5.4.0-67-generic linux-hwe-5.4-headers-5.4.0-66 linux-hwe-5.4-headers-5.4.0-67 linux-image-5.4.0-67-generic linux-modules-5.4.0-67-generic linux-modules-extra-5.4.0-67-generic Use 'sudo apt autoremove' to remove them. The following additional packages will be installed:  libfcitx-qt0 libqt5qml5 libqt5quick5 libqt5quickwidgets5 qml-module-qtquick2 Suggested packages: qt5-qmltooling-plugins The following NEW packages will be installed: fcitx-libs libfcitx-qt0 libqt5qml5 libqt5quick5
libqt5quickwidgets5 qml-module-qtquick2 0 upgraded, 6 newly installed, 0 to remove and 77 not upgraded. 1 not fully installed or removed. Need to get 2,583 kB of archives. After this operation, 10.2 MB of additional disk space will be used. Do you want to continue? [Y/n]
输⼊“Y”回车
再次执⾏安装搜狗命令
sudo dpkg -i sogoupinyin_2.4.0.3469_amd64.deb
输出
(Reading database ... 286507 files and directories currently installed.) Preparing to unpack
sogoupinyin_2.4.0.3469_amd64.deb ... Unpacking sogoupinyin (2.4.0.3469) over (2.4.0.3469) ... Setting up sogoupinyin (2.4.0.3469) ... Processing triggers for gnome-menus (3.13.3-11ubuntu1.1) ... Processing triggers for  (0.23-
1ubuntu3.18.04.2) ... Processing triggers for mime-support (3.60ubuntu1) ... Processing triggers for hicolor-icon-theme (0.17-2) ...
表⽰安装成功
配置输⼊法步骤
1.点击下⾯图中图标,选择“配置当前输⼊法”
ubuntu安装教程
2.点击⼜下⾓“+”号,导⼊搜狗输⼊法