https://bugs.kde.org/show_bug.cgi?id=415770

Rocket Aaron <i...@rocka.me> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |i...@rocka.me

--- Comment #8 from Rocket Aaron <i...@rocka.me> ---
I can reproduce it too, on Plasma 5.27.0. After some experiment, I think I've
figured out what's happening.

gmenu-dbusmenu-proxy hardcoded gtkrcPath as `QDir::homePath() +
QLatin1String("/.gtkrc-2.0")`, but it's not creating the file if it's not
present. kde-gtk-config's `Gtk2ConfigEditor::removeLegacyStrings()` is the
cause:
https://github.com/KDE/kde-gtk-config/blob/4a9185dbc67543544f7010cf39e6c87af44aeca8/kded/config_editor/gtk2.cpp#L54
it uses `Utils::readFileContents(QFile &file)`
https://github.com/KDE/kde-gtk-config/blob/4a9185dbc67543544f7010cf39e6c87af44aeca8/kded/config_editor/utils.cpp#L19
which calls `file.open(QIODevice::ReadWrite | QIODevice::Text)`
and the mode `ReadWrite` means to create the file if it's not exist:
https://doc.qt.io/qt-5/qfile.html#open

So at startup, kde-gtk-config launches and a empty `~/.gtkrc-2.0` file is
created, then gmenu-dbusmenu-proxy watchs the file creation
https://github.com/KDE/plasma-workspace/blob/89d1f0e07955427a083cbc5af34e0ae9fdcdaad4/gmenu-dbusmenu-proxy/menuproxy.cpp#L106
and write the content to the file.

If gmenu-dbusmenu-proxy is disabled, it would simply results an empty
`~/.gtkrc-2.0` file, as this bug describes:
https://bugs.kde.org/show_bug.cgi?id=417534

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to