http://my.oschina.net/u/219482/blog/341452 感謝做者linux
ubuntu 14.04從Qt官網下載的最新版qt,安裝過程很順利,但卻發現沒辦法輸入中文(我用的是 fcitx), 即便下載了fcitx-frontend-qt5和fcitx-frontend-qt4也仍是沒用。ubuntu
想必是qt版本的緣由吧。frontend
後來,試着將從源中安裝的fcitx-frontend-qt5複製到Qt安裝目錄下,居然能夠了。spa
方法以下(fcitx輸入法):.net
1.安裝fcitx-frontend-qt5orm
sudo apt-get install fcitx-frontend-qt5blog
2.將安裝後的fcitx-frontend-qt5複製到qt安裝目錄ci
一般,fcitx-frontend-qt5在下面的目錄路徑中(可用命令dpkg -L 包名看文件安裝路徑):get
/usr/lib/x86_64-linux-gnu/qt5/plugins/platforminputcontexts/libfcitxplatforminputcontextplugin.so
input
將該文件複製到
qt安裝目錄//Tools/QtCreator/bin/plugins/platforminputcontexts
和
qt安裝目錄/5.3/gcc_64/plugins/platforminputcontexts
中
從新打開 QtCreator,終於能夠輸入中文了。
若是仍是不行,重啓電腦,再打開Qtcreator,就能夠了
ibus的操做方法與這相似
其實不少qt編寫的程序沒法輸入中文,將fcitx-frontend-qt5複製到該程序相應的目錄下,就能夠正常了,如wps和linux 下的代碼閱讀軟件 understand,用這種方法都解決了輸入法沒法輸入中文的問題