- Trine 2 will be visible to any launcher the user might use. (Menu, Unity, GNOME Do, etc.)
- You get a launcher entry which knows to vanish if you delete Trine 2 without using a specialized uninstaller.
Instructions (Structured for Users):
- Open ~/Desktop/trine2.desktop in your text editor of choice. (gedit, kate, mousepad, leafpad, etc.)
- Change Categories= to Categories=Game; so it will show up in the right place.
- Make a copy of the Exec line and change it to TryExec so the icon knows to vanish if Trine 2 is deleted.
- Rename the file from trine2.desktop to frozenbyte-trine2.desktop to satisfy the vendor prefix check.
- Run xdg-desktop-menu install ~/Desktop/frozenbyte-trine2.desktop to copy it into the launcher system.
- You can now delete the desktop icon if you want to.
Extra Suggestion for Devs: You may also want to add a Comment=... line to the desktop file. A lot of launchers use it as an explanatory tooltip. (Desura fills in the game's description when generating launchers, so the original Trine gets a launcher tooltip that begins with "Trine is a beautiful fantasy action platformer". (I won't clutter up the post with the full thing.)
- You could also use Categories=Game;Platformer; like the Desura-generated launcher for the original Trine, but "Platformer" isn't technically valid and will have no effect in any spec-compliant launcher since Categories is supposed to only use values from the list list in the spec. There isn't really a proper category for platformers in the current version of the spec so I usually use Categories=Game;ActionGame;.
- The TryExec line tells the launcher that the icon's visibility should be conditional on whether the specified file exists and is executable. It's separate from Exec because some apps need to be launched by wrappers like optirun, aoss, or pasuspender which don't get uninstalled when the game goes away. Just making a copy of the Exec line works for Trine 2 because of how simple the Exec line is. ...and no, I don't know why TryExec must be provided to get the auto-hiding behaviour even when it's identical to Exec.
- xdg-desktop-menu wants launcher names to be namespaced by vendor to avoid the need to use Windows-style GUIDs for distinguishing between upgrades and namespace collisions. Hence, the final step will abort if the filename doesn't take the form vendorname-appname.desktop