Created
April 20, 2026 02:58
-
-
Save erhwenkuo/530d2da9d0faede188359c597ee7f32f to your computer and use it in GitHub Desktop.
在 Ubuntu 24.04 中設定 Fcitx5 大易輸入法
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 在 Ubuntu 24.04 中設定 Fcitx5 大易輸入法 | |
| 在 Ubuntu 24.04 中設定 Fcitx5 大易輸入法,需要先安裝核心框架、接著安裝包含大易碼表的擴充套件,並調整系統輸入法設定。 | |
| ## 步驟 1:安裝 Fcitx5 核心與大易套件 | |
| 開啟終端機並執行以下指令,安裝 Fcitx5 框架、組態工具以及大易所在的碼表套件: | |
| ```bash | |
| sudo apt update | |
| sudo apt install build-essential | |
| sudo apt install libfcitx5core-dev libfcitx5utils-dev libfcitx5config-dev libfcitx5utils-dev gettext | |
| sudo apt install fcitx5 fcitx5-config-qt fcitx5-chinese-addons fcitx5-table-extra | |
| sudo apt install libboost-all-dev libimetable-dev extra-cmake-modules libimecore-dev | |
| ``` | |
| * fcitx5-chinese-addons: 提供中文支援基礎。 | |
| * fcitx5-table-extra: 包含大易 (Dayi)、嘸蝦米與行列等碼表輸入法。 | |
| 取得 fcitx5 大易輸入法 從 GitHub 取得 fcitx5 大易輸入法的原始碼。執行以下命令: | |
| ```bash | |
| git clone https://github.com/fcitx/fcitx5-table-dayi.git | |
| ``` | |
| 編譯和安裝 進入 fcitx5 大易輸入法的原始碼目錄,建立建置目錄,配置並編譯,最後安裝。執行以下命令: | |
| ```bash | |
| cd fcitx5-table-dayi | |
| mkdir build | |
| cd build | |
| cmake .. | |
| make | |
| sudo make install | |
| ``` | |
| ## 步驟 2:將 Fcitx5 設為系統預設 | |
| 1. 執行 `im-config` 開啟輸入法配置視窗。 | |
| 2. 點擊 `Yes` 確認修改,然後從清單中選擇 `fcitx5`,點擊 `OK`。 | |
| 3. 登出並重新登入(或重啟電腦)以使設定生效。 | |
| ## 步驟 3:在 Fcitx5 中加入大易輸入法 | |
| 1. 在應用程式選單中搜尋並開啟「Fcitx 5 設置」("Fcitx 5 Configuration")。 | |
| 2. 在「目前輸入法」視窗中,點擊右側的「加入輸入法」按鈕。 | |
| 3. 取消勾選「僅顯示當前語言」,在搜尋框輸入 `Dayi` 或 大易。 | |
| 4. 選取「大易」(Dayi) 並點擊「加入」。 | |
| ## 步驟 4:環境變數配置 (選用,若無法輸入時使用) | |
| 若在部分軟體(如 VS Code 或 Chrome)中無法切換輸入法,請在 `~/.profile` 或 `/etc/environment` 檔案末尾加入以下內容並重新登入: | |
| ```bash | |
| export XMODIFIERS=@im=fcitx | |
| export GTK_IM_MODULE=fcitx | |
| export QT_IM_MODULE=fcitx | |
| ``` | |
| 提示: Fcitx5 預設的切換快捷鍵是 `Ctrl + Space`,您可以在設定視窗的「全局選項」中自行更改。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment