Deepin20.9安装PySide6后QtDesigner无法输入中文
完成PySide6后,QtDesigner无法输入中文,需要手动编译fcitx-qt5时启用对QT6的支持。
安装编译需要的依赖包:
1 | sudo apt install git |
下载fcitx-qt5源代码:https://github.com/fcitx/fcitx-qt5。
修改编译配置支持QT6:
- 进入源代码目录
- 编辑CMakeLists.txt文件内容,将以下内容:
1 | option(ENABLE_QT5 "Enable Qt5" On) |
改为:
1 | option(ENABLE_QT5 "Enable Qt5" Off) |
- 通过以下步骤编译:
1 | mkdir build |
- 编译好的文件:build/qt6/platforminputcontext/libfcitxplatforminputcontextplugin-qt6.so
- 将编译好的文件拷贝至PySide6对应目录下:{PYTHON_HOME}/lib/python3.12/site-packages/PySide6/Qt/plugins/platforminputcontexts/