QT: import kvantum theme name

This commit is contained in:
Carlos Eduardo authored and Carter Li committed 2024-06-27 17:55:48 +08:00
1 parent d979f55c8e
commit 165aa93fd3
1 file changed
+13
+13
View File
@@ -135,6 +135,13 @@ static void detectLXQt(FFQtResult* result)
ffParsePropFileConfig("pcmanfm-qt/lxqt/settings.conf", "Wallpaper=", &result->wallpaper);
}
static void detectKvantum(FFQtResult* result)
{
ffParsePropFileConfigValues("Kvantum/kvantum.kvconfig", 1, (FFpropquery[]) {
{"theme=", &result->widgetStyle},
});
}
const FFQtResult* ffDetectQt(void)
{
static FFQtResult result;
@@ -157,5 +164,11 @@ const FFQtResult* ffDetectQt(void)
else if(ffStrbufIgnCaseEqualS(&wmde->dePrettyName, FF_DE_PRETTY_LXQT))
detectLXQt(&result);
if(ffStrbufEqualS(&result.widgetStyle, "kvantum") || ffStrbufEqualS(&result.widgetStyle, "kvantum-dark"))
{
ffStrbufClear(&result.widgetStyle);
detectKvantum(&result);
}
return &result;
}