Closed tylerelias closed 5 years ago
Here's the comment from the other ticket as a reference:
I have just investigated.
Did you install JOplin, using the command line, right? So it created an desktop file and it uses an AppImage. Here is its desktop file:
[Desktop Entry] Encoding=UTF-8 Name=Joplin Comment=Joplin for Desktop Exec=/home/gusbemacbe/.joplin/Joplin.AppImage Icon=/home/gusbemacbe/.joplin/Icon512.png StartupWMClass=Joplin Type=Application Categories=Application; X-AppImage-BuildId=1LpSDS79QxkAP8oaIYEmKvLumiN
You can see as the
Icon=/home/gusbemacbe/.joplin/Icon512.png
is hardcoded. We have to change to softcoded path like:Icon=joplin
The problem is that, as
X-AppImage-BuildId=1LpSDS79QxkAP8oaIYEmKvLumiN
is present, it will update the AppImage and reverts the icon path to the original.
Unfortunately I'm not familiar with the build process of the AppImage on Linux. Maybe @laurent22 has an idea.
I started looking at where an appropriate location to store the icon would be. This gnome article says /usr/share/icons/hicolor/48x48/apps/
and I think ~/.local/share/icons/hicolor/48x48/apps
. Can you test if this would work on your arch system?
@CalebJohn
I was going to say and explain it. The name Icon512.png
should be renamed to joplin.png
and Icon=/home/gusbemacbe/.joplin/Icon512.png
for simply Icon=joplin
in the .desktop
file.
to:
mkdir -p ~/.local/share/icons/hicolor/48x48/apps
wget -nv -O ~/.local/share/icons/hicolor/48x48/apps/joplin.png https://joplinapp.org/images/Icon512.png
to:
echo -e "[Desktop Entry]\nEncoding=UTF-8\nName=Joplin\nComment=Joplin for Desktop\nExec=/home/$USER/.joplin/Joplin.AppImage\nIcon=joplin\nStartupWMClass=Joplin\nType=Application\nCategories=Application;\n$APPIMAGE_VERSION" >> ~/.local/share/applications/appimagekit-joplin.desktop
Looks good! Why don't you make a pull request? That way you get credit for the work you've put in! I think this section could be changed though to reflect to size of the icon
mkdir -p ~/.local/share/icons/hicolor/512x512/apps
wget -nv -O ~/.local/share/icons/hicolor/512x512/apps/joplin.png https://joplinapp.org/images/Icon512.png
@CalebJohn, done.
Hi, I'm on Arch and I use Joplin for taking notes. I noticed that with icon themes the icon for Joplin doesn't change like the rest of them. I posed this issue on another repo, the creator of the icons a currently use here: https://github.com/gusbemacbe/suru-plus-aspromauros/issues/9 He did some digging around and pointed it out that the path to the icon itself is hardcoded and that any changes done to that get reverted (check his explaination in the link above)
I thought I should raise this issue and see what you guys have to say. Also, thanks for this program, and all the hard work.
See image for a visual representation.