Page 1 of 1

Desktop integration

PostPosted: 16 Apr 2011, 20:18
by Gallaecio
I would like Red Eclipse to distribute an official .desktop file for desktop integration (so the game is listed in desktop environments’ menus). This would not only make life easier for packagers, but also for translators who could work on desktop entries translation from upstream instead of having duplicated efforts in different GNU/Linux distributions.

I attach an .desktop example, based on the one in Arch Linux's AUR and with additional translations for Galician and Spanish.

By the way, I saw you link PlayDeb and AUR from the main page, so I’ll leave you this link in case you want to do the same with Chakra.

Re: Desktop integration

PostPosted: 17 Apr 2011, 08:45
by qreeves
Done, and done.

Re: Desktop integration

PostPosted: 02 May 2011, 13:02
by arand
Added Swedish translation and integrated this with my debian packaging : )
( ref. https://edge.launchpad.net/~arand/+archive/redeclipse )
{l Code}: {l Select All Code}
[Desktop Entry]
Type=Application
Version=1.1
Name=Red Eclipse
Name[es]=Eclipse rojo
Name[gl]=Eclipse vermello
Name[sv]=Röd Eklips
GenericName=First-person shooter game
GenericName[es]=Juego de tiros en primera persona
GenericName[gl]=Xogo de tiros en primeira persoa
GenericName[sv]=Förstapersonsskjutare
Comment=First-person shooter with agile gameplay and built-in editor
Comment[es]=Juego de tiros en primera persona con editor incorporado
Comment[gl]=Xogo de tiros en primeira persoa con editor incorporado
Comment[se]=Förstapersonsskjutare med rörlig spelstil och inbyggd baneditor
Icon=redeclipse
TryExec=redeclipse
Exec=redeclipse
Categories=Game;ActionGame;

Note that I use a wrapper script here in /usr/games/redeclipse:
{l Code}: {l Select All Code}
#!/bin/sh
for arg
do
    if [ "$arg" = --help ]
    then
       exec man redeclipse
    fi
done

RE_OPTIONS="-r"
cd /usr/lib/games/redeclipse
exec ./reclient ${RE_OPTIONS} ${1+"$@"}
# ${1+"$@"} is a portability hack, keyword "wrapper script"

- arand

Re: Desktop integration

PostPosted: 31 Jul 2011, 21:45
by Gallaecio
Two things:

1. Version field is not referred to Red Eclipse version, but to .desktop file version, so it should be changed to 1.0 (just found out myself).
2. Since you need to edit it to fix point 1, please, remove also final dot from Spanish (es) and Galician (gl) translations of GenericName (comment should still have the final dot, though).

Also, would be great if you provide a PNG version of Red Eclipse icon (maybe saved in the same folder as the .desktop file), since the .desktop standard only uses PNG for raw images and SVG for vectorial ones.

Nothing else, now time to continue playing! (I’m getting addicted to this game :)

EDIT: Ok, one detail I just noticed. Action, in categories, should be replaced with “ActionGame”. See Categories.

Re: Desktop integration (added DE, PT, IT lang translation)

PostPosted: 09 Aug 2011, 00:32
by fluxord
Hi, I just added German, Portuguese and Italian (DE, PT, IT) translations. Also capitalized the characters of "Name[]=" for all languages.
Gallaecio {l Wrote}:Two things:

1. Version field is not referred to Red Eclipse version, but to .desktop file version, so it should be changed to 1.0 (just found out myself).
2. Since you need to edit it to fix point 1, please, remove also final dot from Spanish (es) and Galician (gl) translations of GenericName (comment should still have the final dot, though).

So it should look like this (using arand's wrapper script):
{l Code}: {l Select All Code}
[Desktop Entry]
Type=Application
Version=1.0
Name=Red Eclipse
Name[de]=Roter Eklipse
Name[es]=Eclipse Rojo
Name[gl]=Eclipse Vermello
Name[it]=Eclisse Rosso
Name[pt]=Eclipse Vermelho
GenericName=First-person shooter game
GenericName[de]=Ego-Shooter Spiel
GenericName[es]=Juego de tiros en primera persona
GenericName[gl]=Xogo de tiros en primeira persoa
GenericName[it]=Sparatutto in prima persona
GenericName[pt]=Jogo de tiros em primeira pessoa
GenericName[sv]=Förstapersonsskjutare
Comment=First-person shooter with agile gameplay and built-in editor.
Comment[de]=Ego-Shooter Spiel mit agilen Gameplay und integriertem Editor.
Comment[es]=Juego de tiros en primera persona con jugabilidad ágil y editor incorporado.
Comment[gl]=Xogo de tiros en primeira persoa con xogo áxil e editor incorporado.
Comment[it]=Sparatutto in prima persona con agile gameplay ed editor incorporato.
Comment[pt]=Jogo de tiros em primeira pessoa com jogabilidade ágil e editor incorporado.
Comment[se]=Förstapersonsskjutare med rörlig spelstil och inbyggd baneditor.
Icon=redeclipse
Icon=redeclipse
TryExec=redeclipse
Exec=redeclipse
Categories=Game;ActionGame

===EDIT 1===
* Added the "with agile gameplay" to the "Comment[]" translations, except for Swedish (I don't know it).