[Development] QStylePlugin::create() being called multiple times?

René J.V. Bertin rjvbertin at gmail.com
Thu Sep 14 15:18:41 CEST 2017


Hi,

Is there any reason why QStylePlugin::create() would be called multiple times in an application that doesn't do any widget style changing itself?
This is on a KDE desktop with the plasma integration plugin installed and KDE_SESSION_VERSION set.

Whatever the reason why this happens, what happens with the QStyle instances created by the preceding ::create() calls? Or rather, what can I do with them to prevent side-effects? My style plugin currently keeps track of all style instances it creates, and could delete the old instances each time a new one is deleted if that's safe.

If that's not safe, can I at least call oldStyleInstance->disconnect() and sever all connections it has to the D-Bus, safely?

Thanks,
René



More information about the Development mailing list