Page MenuHomePhabricator

Homescreen example: Apps without icons are not clickable
Open, TODOPublic

Description

The problem

Some apps have no icons or maybe invalid ones. Neovim, for example, has no ".desktop" file, and MPV has a .desktop file - but it seems like its icon is invalid, even though it is described in /usr/share/applications/mpv.desktop:

[Desktop Entry]
Type=Application
Name=mpv Media Player
...
Icon=mpv
...
Categories=AudioVideo;Audio;Video;Player;TV;

Since there's no icon, they cannot be clicked (even their names) and so they cannot be executed from the homescreen.

Possible solutions

  1. Maybe there could be a fallback icon;
  2. Maybe their name could be clickable;
  3. Maybe click could be related to their region - or, like 1., have a fallback icon that is just an empty image that fills the icon rectangle.

Additional Material

jptiz created this task.Feb 20 2020, 1:03 PM
jptiz triaged this task as TODO priority.

The purpose of this sample is to showcase the Efl.Ui.Spotlight widget, therefore, I am not interested in making it waterproof.
However, during its development it uncovered some icon management issues in EFL, and that is good.

Right now, I am more interested in knowing why some apps have no icon than in adding a fallback path for apps without icon.

If neovim has no .desktop file it should not appear in the homescreen at all. Does it appear? (I cannot read the text in your picture, sorry)

The mpv application has an icon named mpv. Do you have any file named mpv* in /usr/share/icons/*?

jptiz added a comment.Feb 20 2020, 1:24 PM

About the purpose: understood, gonna update the main post.

About the image: Oh, sorry, phab compressed the image a whole lot. But yeah, there is a Neovim there, even tough there is no neovim.desktop in /usr/share/applications nor ~/.local/share/applications.

About the mpv icon:

$ ls -1 /usr/share/icons/**/*mpv*
/usr/share/icons/hicolor/16x16/apps/mpv.png
/usr/share/icons/hicolor/32x32/apps/mpv.png
/usr/share/icons/hicolor/64x64/apps/mpv.png
/usr/share/icons/hicolor/scalable/apps/mpv.svg
/usr/share/icons/hicolor/symbolic/apps/mpv-symbolic.svg
/usr/share/icons/Papirus/16x16/apps/gnome-mpv.svg
/usr/share/icons/Papirus/16x16/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/16x16/apps/mpv.svg
/usr/share/icons/Papirus/16x16/apps/xt7-player-mpv.svg
/usr/share/icons/Papirus/22x22/apps/gnome-mpv.svg
/usr/share/icons/Papirus/22x22/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/22x22/apps/mpv.svg
/usr/share/icons/Papirus/22x22/apps/xt7-player-mpv.svg
/usr/share/icons/Papirus/24x24/apps/gnome-mpv.svg
/usr/share/icons/Papirus/24x24/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/24x24/apps/mpv.svg
/usr/share/icons/Papirus/24x24/apps/xt7-player-mpv.svg
/usr/share/icons/Papirus/32x32/apps/gnome-mpv.svg
/usr/share/icons/Papirus/32x32/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/32x32/apps/mpv.svg
/usr/share/icons/Papirus/32x32/apps/xt7-player-mpv.svg
/usr/share/icons/Papirus/48x48/apps/gnome-mpv.svg
/usr/share/icons/Papirus/48x48/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/48x48/apps/mpv.svg
/usr/share/icons/Papirus/48x48/apps/xt7-player-mpv.svg
/usr/share/icons/Papirus/64x64/apps/gnome-mpv.svg
/usr/share/icons/Papirus/64x64/apps/mpv-icon-8bit-64x64.svg@
/usr/share/icons/Papirus/64x64/apps/mpv.svg
/usr/share/icons/Papirus/64x64/apps/xt7-player-mpv.svg

The *@" are all symlinks to mpv.svg in the same directory.

jptiz added a comment.Feb 20 2020, 1:27 PM

Oh, okay, found the neovim issue: the file is actually called "nvim.desktop", not "neovim.desktop", that's why. My eyes just didn't catch it at first.

The fact that the indicator widget (the little dots at the top) is not centered tells me that your EFL is not up to date.
And this reminds me that to fix the missing icons D11381 needs to land first, doh!

jptiz added a comment.Feb 27 2020, 7:46 AM

True, my EFL was out of date!

Fixed it. Now the little dots are centered, and can confirm that after D11381 landed icons are back to normal - except for Manjaro User Guide, Manjaro Settings Manager, sonic-pi, Virtual Machine Manager and hp-uiscan.

Using /usr/share/applications/manjaro-settings-manager.desktop as an example:

[Desktop Entry]
Name=Manjaro Settings Manager
...
Icon=preferences-desktop

These are the icons I have with that name:

$ ls -1 /usr/share/icons/**/preferences-desktop.*
/usr/share/icons/Adwaita/16x16/legacy/preferences-desktop.png
/usr/share/icons/Adwaita/22x22/legacy/preferences-desktop.png
/usr/share/icons/Adwaita/24x24/legacy/preferences-desktop.png
/usr/share/icons/Adwaita/32x32/legacy/preferences-desktop.png
/usr/share/icons/Adwaita/48x48/legacy/preferences-desktop.png
/usr/share/icons/Enlightenment-X/categories/128/preferences-desktop.png
/usr/share/icons/Enlightenment-X/categories/16/preferences-desktop.png
/usr/share/icons/gnome/16x16/categories/preferences-desktop.png
/usr/share/icons/gnome/22x22/categories/preferences-desktop.png
/usr/share/icons/gnome/24x24/categories/preferences-desktop.png
/usr/share/icons/gnome/32x32/categories/preferences-desktop.png
/usr/share/icons/gnome/48x48/categories/preferences-desktop.png
/usr/share/icons/HighContrast/scalable/categories/preferences-desktop.svg
/usr/share/icons/Papirus/16x16/apps/preferences-desktop.svg
/usr/share/icons/Papirus/22x22/apps/preferences-desktop.svg
/usr/share/icons/Papirus/24x24/apps/preferences-desktop.svg
/usr/share/icons/Papirus/32x32/apps/preferences-desktop.svg
/usr/share/icons/Papirus/48x48/apps/preferences-desktop.svg
/usr/share/icons/Papirus/64x64/apps/preferences-desktop.svg

What else can I see so I can help you with this?

I'm afraid this is as far as my knowledge of Linux icons and Efreet reach. Unless @bu5hm4n or @zmike want to pitch in, this is not a terribly urgent matter.

Hi!

The problem with your icons is that none of these is in hicolor. Which means, when we are dealing with the fallback to what we have in the default theme, we are on the fly checking for hicolor. However, it might not be 100% the case, as i do not know if we are going into fallback handling or not, as i do not know your config. Want to share it ? :)

jptiz added a comment.Feb 27 2020, 9:23 AM

You mean this?