Icon not showing runtime

I created a flutter built AppImage from the flutter Appimage Medium article after failing to make snaps.
I followed the directions and it worked so easy. Great!

It is called Tipitaka Pali Reader

However, the icon does not seem to show.
I tried modifying the desktop as stated in some other websites
StartupWMClass= “tipitaka_pali_reader”
but that did not work.

Is there a reason why this is not working?

1 Like

However, the icon does not seem to show.

Which icon is missing where? Please post a screenshot. Thanks!

There should be an icon on the ubuntu side bar when the app is running. This is blank.
I have the filename listed in the desktop file (without png).
The png is in the directory for building.

This was listed as an ubuntu fix… but did not work
StartupWMClass="tipitaka_pali_reader"


[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Name=Tipitaka Pali Reader
Exec=tipitaka_pali_reader %u
Icon=logo
Categories=Utility;
StartupWMClass="tipitaka_pali_reader"

I had a friend make an install sh file: It seems to work well and I get an icon added to my ubuntu left app shortcut bar. Here it is below. I will deliver a zip with the app logo and sh file.
It could be modified to help others. I don’t want to recommend or use for myself the appImage installer app. I’m more comfortable with a bash script for myself and logically what I would give others too. This does not require any root privs ans will be accepted better just like appImages over deb.

Nevertheless, this is dependent on the desktop file rather than the appImage produced in contrast to kdenLive appImage that works fine.

#!/bin/bash

basename=tipitaka_pali_reader
appimages=${basename}.AppImage
icons=${basename}.png
desktopfile=${basename}.desktop

# System
# desktopdir=/usr/share/applications/
# appdir=/usr/local/bin/
# iconsdir=/usr/share/icons/

cat > $desktopfile <<EOF
[Desktop Entry]
Name=Tipitaki Pali Reader
# Name[my]=.
# Name[th]=.
# Name[zh]=.
# Name[vi]=.
Comment=A Modern Application for Reading Pali
# Comment[my]=.
# Comment[th]=.
# Comment[zh]=.
# Comment[vi]=.
Exec=${HOME}/.local/bin/tipitaka_pali_reader.AppImage
Terminal=false
Type=Application
Icon=${HOME}/.local/share/icons/tipitaka_pali_reader.png
StartupWMClass=Tipitaki Pali Reader
Categories=Utility;Education;
Keywords=Pali;Reader;Dictionary;Dhamma;Tipitaka
EOF

# User
desktopdir=~/.local/share/applications/
appdir=~/.local/bin/
iconsdir=~/.local/share/icons/

for sysdir in $desktopdir $appdir $iconsdir 
do
	echo "$sysdir"
	if [ ! -d "$sysdir" ]; then
  	mkdir -p "${sysdir}";
	fi
done


chmod +x $appimages $desktopfile
cp -v $appimages $appdir
cp -v $icons $iconsdir
cp -v $desktopfile $desktopdir

# application-desktop file with commands
# desktop-file-install tipitaka_pali_reader.desktop  --dir=$HOME/.local/share/applications  
# update-desktop-database -q

# application to menu fav bar
application="'${basename}.desktop'"
favourites="/org/gnome/shell/favorite-apps"
dconf write ${favourites} \
    "$(dconf read ${favourites} \
    | sed "s/, ${application}//g" \
    | sed "s/${application}//g" \
    | sed -e "s/]$/, ${application}]/")"

The difference is probably that there is a Kdenlive icon in the icon theme of your system, but there is not an icon for your application in the icon theme of your system. Your system doesn’t know how to load an icon from AppImages (unless you are using a “desktop integration” tool like appimaged from go-appimage). To change that, the desktop environment would need to start knowing about how to handle AppImages.