| Summary: | SVG icons get ignored if PNGs exist in qt platform theme kde | ||
|---|---|---|---|
| Product: | [Frameworks and Libraries] frameworks-kiconthemes | Reporter: | david <12davidkac> |
| Component: | general | Assignee: | Christoph Feck <cfeck> |
| Status: | CONFIRMED --- | ||
| Severity: | normal | CC: | kde, kdelibs-bugs-null |
| Priority: | NOR | ||
| Version First Reported In: | unspecified | ||
| Target Milestone: | --- | ||
| Platform: | Other | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
| Attachments: | Dolphin with Chicago95 icons, platform themes gtk2 (top) and kde (bottom) | ||
Confirmed the cause is that we loop over all extensions and look into all directories
QString KIconTheme::iconPathByName(const QString &iconName, int size, KIconLoader::MatchType match, qreal scale) const
{
for (const QString ¤t : std::as_const(d->mExtensions)) {
const QString path = iconPath(iconName + current, size, match, scale);
if (!path.isEmpty()) {
return path;
}
}
return QString();
}
At that point there is no info anymore about how good that match is.
|
Created attachment 164633 [details] Dolphin with Chicago95 icons, platform themes gtk2 (top) and kde (bottom) SUMMARY Icon themes with both pngs and svgs don't look like they should. PNGs are used no matter what. This can be seen in dolphin with Chicago95 icon theme. Icons above 48x48 should be svgs, but aren't. STEPS TO REPRODUCE 1. Use Chicago95 icon theme 2. Open dolphin using qt platform theme kde (QT_QPA_PLATFORMTHEME=kde dolphin) 3. Set zoom to something bigger than 48 OBSERVED RESULT Big icons are blurry (scaled png) EXPECTED RESULT The icons should be crisp (svg) SOFTWARE/OS VERSIONS KDE Plasma Version: 5.27.10 KDE Frameworks Version: 5.113.0 Qt Version: 5.15.11 ADDITIONAL INFORMATION Another thing I dislike with dolphin's "Information panel" (F11 on keyboard) is that pngs always get scaled to 160x160. This doesn't happen with other qt platform themes (gtk2/lxqt).