问题是:当我使用sudo
或在 Kubuntu 中启动应用程序时kdesudo
,这些应用程序会改变其视觉主题,并且其中一些应用程序的显示会出现问题。
举个例子:
下一个非常奇怪的事情是 Konsole 的输出,在kdesudo
:
eugene@Eugene-KubuntuPC:~$ kdesudo dolphin
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
QPixmap::scaled: Pixmap is a null pixmap
...
QPixmap::scaled: Pixmap is a null pixmap
QPainter::begin: Paint device returned engine == 0, type: 2
QPixmap::scaled: Pixmap is a null pixmap
QPainter::begin: Paint device returned engine == 0, type: 2
QPixmap::scaled: Pixmap is a null pixmap
...
QPixmap::scaled: Pixmap is a null pixmap
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
"ÐÑоÑеÑÑ Ð¿ÑоÑокола trash неожиданно завеÑÑилÑÑ"
QPixmap::scaled: Pixmap is a null pixmap
...
QPixmap::scaled: Pixmap is a null pixmap
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setOpacity: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setOpacity: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setCompositionMode: Painter not active
QPixmap::scaled: Pixmap is a null pixmap
QPixmap::scaled: Pixmap is a null pixmap
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setOpacity: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 2
...
QPixmap::scaled: Pixmap is a null pixmap
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setOpacity: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setOpacity: Painter not active
QPainter::begin: Paint device returned engine == 0, type: 2
QPainter::setCompositionMode: Painter not active
QPixmap::scaled: Pixmap is a null pixmap
...
QPixmap::scaled: Pixmap is a null pixmap
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
...
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
我尝试使用如下环境变量来启动应用程序XDG_CURRENT_DESKTOP=$XDG_CURRENT_DESKTOP XDG_CONFIG_DIRS=$XDG_CONFIG_DIRS XDG_RUNTIME_DIR=$XDG_RUNTIME_DIR
,但结果并没有好多少:
我在 Kubuntu 15.10 中注意到了这个问题,但以为它会在 LTS 版本中得到修复。看来我错了。如何修复?