[英]QGtkStyle could not resolve GTK
I have a series of apps installed in Ubuntu 18.04 using Anaconda. 我使用Anaconda在Ubuntu 18.04中安装了一系列应用程序。 They run just fine, but the menus appear as blank.
它们运行得很好,但菜单显示为空白。
Some of these apps are: 其中一些应用程序是:
For all of them I obtain the same error when I execute them: 对于所有这些,我执行时会得到相同的错误:
QGtkStyle could not resolve GTK. Make sure you have installed the proper libraries.
I have been trying to sort it for hours without success. 我一直试图将它分类几个小时而没有成功。
Any idea of how to fix this? 知道怎么解决这个问题吗?
As a quick fix, add 作为快速解决方案,请添加
export QT_STYLE_OVERRIDE=gtk2
to your .bashrc
. 到你的
.bashrc
。 Then your menus should at least have some text again. 然后你的菜单至少应该有一些文字。
This is not strictly speaking a GTK theming problem. 这严格来说不是GTK主题问题。 Instead, this is because your Qt version is old.
相反,这是因为你的Qt版本已经过时了。 You need install
qt=5.9
. 你需要安装
qt=5.9
。
In my case, that problem was caused because I use conda-forge channel and qt is in 5.6 version there. 在我的情况下,这个问题是因为我使用conda-forge通道而qt是5.6版本。 When explicitly install
qt=5.9
from default channel the problem was solved without change .bashrc
file. 当从默认通道显式安装
qt=5.9
,问题解决了,而没有更改.bashrc
文件。
I soleved it by upgrading and installing pkg-config 我通过升级和安装pkg-config来完成它
sudo apt upgrade && sudo apt install pkg-config
AND Jupyter series just works well! 和Jupyter系列效果很好!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.