On Mon, 2016-11-21 at 13:44 +0200, Jani Nikula wrote: > I wonder if there's a way to define different Execs for clicking on > the icon and handling mailto. The desktop file format specification implies you can just add an extra context entry. For reference, the full specification is here: https://specifications.freedesktop.org/desktop-entry-spec/latest/ Something like this seems like what the spec suggests: [Desktop Entry] Name=Notmuch Emacs Client GenericName=Email Client Comment=Emacs based email client Exec=emacs -f notmuch Icon=emblem-mail Terminal=false Type=Application Categories=Network;Email; [Create Message] Name=Notmuch Emacs Create Message Exec=notmuch-emacs-mua %u MimeType=x-scheme-handler/mailto; However, this did not seem to work when I tried it out in my gnome session. I'm pretty sure creating two separate desktop files (duplicating some of the fields) would work. --- Keith