Ubuntu 24.04 Transmission icon

Title: Taming Transmission on Ubuntu 24.04 (Wayland) and setting a custom icon

Ubuntu Version: 24.04
Desktop Environment: GNOME (Wayland)

Summary: Force GNOME/Wayland to use a custom .desktop launcher for Transmission, avoid duplicate icons, and ensure .torrent and magnet links open the correct launcher.

Prerequisites:

  • transmission-gtk installed (/usr/bin/transmission-gtk)

  • Permission to edit files in /usr/share/applications and ~/.local/share/applications

Steps:

  1. Create the custom launcher
    Open the file:

bash

nano ~/.local/share/applications/transmission-custom.desktop

Paste exactly:

ini
    [Desktop Entry]
    Name=Transmission
    Exec=env GDK_BACKEND=x11 /usr/bin/transmission-gtk
    Icon=transmission
    Terminal=false
    Type=Application
    StartupNotify=true
    StartupWMClass=com.transmissionbt.transmission
    Categories=Network;P2P;
  1. Neutralize the system launcher (optional)

bash

sudo nano /usr/share/applications/transmission-gtk.desktop

Under [Desktop Entry], add:

ini

NoDisplay=true 
StartupWMClass=__IGNORE_ME__
  1. Set defaults for .torrent and magnet
bash
xdg-mime default transmission-custom.desktop application/x-bittorrent
xdg-mime default transmission-custom.desktop x-scheme-handler/magnet
  1. Update desktop database
bash
update-desktop-database ~/.local/share/applications
  1. Log out and log back in (Wayland session)

Verification:

  • Launch Transmission from Activities.

  • Open a .torrent and a magnet link; confirm only one (custom) icon appears in the dock.

Notes:

  • GDK_BACKEND=x11 forces a stable StartupWMClass under Wayland.

  • Added screenshots using the editor’s image upload.

  • Tag your post with: 24.04, Wayland, transmission, desktop-file

Attachable .desktop file (save as transmission-custom.desktop if you want to download):

ini
    [Desktop Entry]
    Name=Transmission
    Exec=env GDK_BACKEND=x11 /usr/bin/transmission-gtk
    Icon=transmission
    Terminal=false
    Type=Application
    StartupNotify=true
    StartupWMClass=com.transmissionbt.transmission
    Categories=Network;P2P;

Isn’t it the same or easier as setting the correct StartupWMClass app ID for Transmission instead? I remember back when I was on 24.04 I experienced that issue of missing Transmission icon. I found this article that had a fix. I’m currently on 26.04 and it has thus far been fixed. I believe Transmission themselves fixed it upstream with a newer release. Although, AppArmor still has some permission issues with Transmission on 26.04

@alonsp2gb-k Welcome to Ubuntu Discourse :slight_smile:

Since this is not a support request, more of a guide, I moved it to Lounge > Tips & Tricks

Thanks for sharing with the community.

1 Like

Good morning @billy5155.
Thank you for his comment.
The Guide is just that, a Guide.
That aims to provide a solution to:
“Ubuntu 24.04 + Wayland, which is the mode where Transmission gives the most war”.
There is a real bug in “Transmission 4.0.1”:
Transmission 4.0.1
It is important to note which is NOT a SOLUTION to the aforementioned “bug”, it is just a way to get around the “bug”.
Best regards
@alonsp2gb-k

For a Spanish version of this Guide:
GuĂ­a en es_Es

I hope it is useful.
Best regards

1 Like