See here:
And this integrates nicely with myrlyn-sudo (which is what the myrlyn-sudo.desktop file calls) because it preserves the needed environment variables.
myrlyn-sudo
myrlyn-sudo.desktop
Somewhat related:
HTH