Do your app icons in Discover look ugly and pixellated? If so, you’re probably a Kubuntu user. Every user of a recent Kubuntu version unfortunately sees horrid low-resolution icons in Discover. It’s very unpleasant.
Today I helped drive an investigation and resolution for this issue. Here’s the good news: it’ll be fixed in the upcoming Kubuntu 18.04, and you can fix it for yourself, today! Here’s how.
- Run the following terminal commands:
sudo sed -i "s/hidpi/large/" /etc/apt/apt.conf.d/60plasma-discover sudo apt update sudo appstreamcli refresh-cache --force
- Restart Discover, if it’s running
Ta-daa! Pretty, high-resolution icons:
This turned out to be a bug in how Discover was packaged in Debian. Ubuntu was re-using the Debian Appstream configuration packaging, and that packaging was erroneously downloading HiDPi versions of small icons instead of large icons. This illustrates an eternal principle in software: the price of 3rd-party and upstream dependencies is eternal communication. When every layer of software is built on top of another layer provided by someone else, communication is mandatory; when the people responsible for each layer don’t talk to one another regularly, bugs creep in. Once all parties were talking to one another in the same (virtual) room, a fix materialized literally within minutes.
Thankfully, this bug has been squashed, and Kubuntu users will once again see pretty app icons.
If my efforts seem useful and you’d like to see more of them, consider becoming a patron on Patreon, LiberaPay, or PayPal.
Oh sweet! Thanks Nate!
LikeLiked by 2 people
Another win!
LikeLike
Discover looks great in Neon now! Well done!
This fix did not work for me in Kubuntu 17.10 though. : ( ??
LikeLike
Please note, I also get a ‘cgcicon invalid backend themes’ pop up when I open Discover. This was happening before I ran your fix here though – I think. Perhaps after installing flatpaks.
I re-installed Discover via Synaptic and ran the above fix again. Icons are still pixillated.
LikeLike
There was an error in the instructions before, which I’ve now corrected. Can you try again?
LikeLiked by 1 person
Groovy! The update is working in Kubuntu 17.10! cheers!
LikeLiked by 1 person
In Kubuntu 16.04
anarcho@kubuntu:~$ sudo sed s/hidpi/large/ /etc/apt/apt.conf.d/60plasma-discover
[sudo] password for anarcho:
sed: can’t read /etc/apt/apt.conf.d/60plasma-discover: No such file or directory
LikeLike
Hmm, maybe the file wasn’t there in Kubuntu 16.04. What output does this command produce?
grep -ri “:DEP-11-icons-” /etc/apt/apt.conf.d/
LikeLike
anarcho@kubuntu:~$ grep -ri “:DEP-11-icons-” /etc/apt/apt.conf.d/
anarcho@kubuntu:~$ sudo sed -i “s/hidpi/large/” /etc/apt/apt.conf.d/60plasma-discover
[sudo] password for anarcho:
sed: can’t read /etc/apt/apt.conf.d/60plasma-discover: No such file or directory
anarcho@kubuntu:~$
LikeLike
apt.conf.d file does not have ’60plasma-discover’
Where can I get the 60plasma-discover from?
Thanks.
LikeLike
Sounds like you need to upgrade Kubuntu to 18.04. But once you do that, you won’t need to apply this workaround, since it’s fixed there. 🙂
LikeLiked by 1 person
Well – I do plan on putting in a new SSD and upgrading/fresh install of Kubuntu sometime this week – or do I wait for Neon Bionic Beaver? : )
LikeLike
Kubuntu and KDE Neon are purposely different and have different aims and goals, so that’s up to you!
LikeLiked by 1 person
So Nate – the notifications for upgrading to 18.04 are supposed to be out -yes? I am on a Dell OEM Ubuntu 16.04 (with Kubuntu backports) – so would that stop me getting the notification or ability to upgrade, do you know???
No biggy – like I said, I plan to put in a bigger drive and fresh install anyway!
LikeLiked by 1 person
Ubuntu is not Kubuntu; you wouldn’t get a notification on Ubuntu 16.04 to upgrade to Kubuntu 18.04. And installing the Kubuntu backports PPA on top of regular Ubuntu seems to me like a sure recipe for breakage and undefined behavior. Since you’re using kind of a franken-setup right now, I would strongly recommend doing a clean install of Kubuntu 18.04.
LikeLiked by 1 person
ok, thanks!
LikeLiked by 1 person
This didn’t work for me. The command `sudo sed s/hidpi/large/ /etc/apt/apt.conf.d/60plasma-discover` just puts the edited file contents on stdout instead of changing the file. So I edited the file manually followed by `sudo appstreamcli refresh-cache –force` but discover still shows pixelated icons. I am using kubuntu-backports ppa and the 60plasma-discover file looks like this:
## This file is provided by KDE Discover to enable the download of
## small-size icons as well as bigger high-res application icons by default.
##
## The small (64x64px) icons are required for Discover to work, while the
## HiDPI icons are required for it to look good.
Acquire::IndexTargets {
deb::DEP-11-icons {
DefaultEnabled “true”;
};
};
Acquire::IndexTargets {
deb::DEP-11-icons-large {
DefaultEnabled “true”;
};
};
LikeLike
Ok, after restarting and waiting a few hours, the icons look crisp. I don’t know why it didn’t work before.
LikeLiked by 1 person
I think you also need to do a `sudo apt update`. I’ve updated the instructions, thanks!
LikeLiked by 1 person
There was an error in the instructions before, which I’ve now corrected. Can you try again?
LikeLiked by 1 person
Just out of curiosity: don’t you need parameter ‘-i’ to actually replace the content of the file?
LikeLike
Oops, yep! See updated instructions.
LikeLiked by 1 person
I hope the patch also got upstreamed to Debian.
LikeLike
It did!
LikeLiked by 1 person
Shouldn’t that be:
sudo sed -i “s/hidpi/large/g” /etc/apt/apt.conf.d/60plasma-discover
LikeLike
Oops, of course! Thanks for the correction.
LikeLiked by 1 person
Doesn’t seem to have fixed it here as the icons still look low resolution and I’m getting this if run from Konsole:
invalid kns backend! “/etc/xdg/servicemenu.knsrc” because: “Config group not found! Check your KNS3 installation.”
invalid kns backend! “/etc/xdg/ksysguard.knsrc” because: “Config group not found! Check your KNS3 installation.”
Discarding invalid backend “servicemenu.knsrc”
Discarding invalid backend “ksysguard.knsrc”
could not find “org.kde.kdenlive.desktop” “”
could not find “org.kde.development” “”
could not find “org.kde.kdenlive.desktop” “”
could not find “org.kde.development” “”
org.kde.knewstuff.core: “Error transferring https://kdenlive.org/data/mltprofilesources.xml – server replied: Not Found”
kns error “/etc/xdg/kdenlive_projectprofiles.knsrc” “Loading of providers from file: https://kdenlive.org/data/mltprofilesources.xml failed”
could not find “org.kde.kdenlive.desktop” “”
could not find “org.kde.development” “”
org.kde.knewstuff.core: Could not find category “KAddressbook Theme”
invalid kns backend! “/etc/xdg/kaddressbook_themes.knsrc” because: “All categories are missing”
Discarding invalid backend “kaddressbook_themes.knsrc”
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
kns error “/etc/xdg/kaddressbook_themes.knsrc” “Invalid Kaddressbook_themes backend, contact your distributor.”
org.kde.knewstuff.core: Could not find category “Calligra Flow Stencil”
invalid kns backend! “/etc/xdg/calligra_stencils.knsrc” because: “All categories are missing”
Discarding invalid backend “calligra_stencils.knsrc”
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
kns error “/etc/xdg/calligra_stencils.knsrc” “Invalid Calligra_stencils backend, contact your distributor.”
org.kde.knewstuff.core: Could not find category “Xfce Icon Theme”
invalid kns backend! “/etc/xdg/cgcicon.knsrc” because: “All categories are missing”
Discarding invalid backend “cgcicon.knsrc”
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
qrc:/qml/DiscoverDrawer.qml:145: TypeError: Cannot read property ‘name’ of null
kns error “/etc/xdg/cgcicon.knsrc” “Invalid Icon Themes backend, contact your distributor.”
LikeLike
There was an error in the instructions before, which I’ve now corrected. Can you try again? Those errors you see on the command-line are unrelated, and were already appearing. If you also get them as GUI pop-up notifications, see https://bugs.kde.org/show_bug.cgi?id=390959
LikeLike
I was getting the kns error messages as pop-ups at the bottom of Discover’s window, but they were disappearing so quickly which is why I tried from the terminal.
LikeLike