Skip to content

New job: KEMailClientLauncherJob

David Faure requested to merge work/dfaure/mailclientlauncherjob into master

This replaces KToolInvocation::invokeMailer, and builds on top of KApplicationLauncherJob, to launch the application whose desktop file mentions x-scheme-handler/mailto and pass it a mailto URL.

KToolInvocation::invokeMailer supported non-standard syntax in the Exec line like %s for subject, %c for cc etc. Mostly to launch kmail, and for hand-crafted desktop files. Nowadays kmail supports mailto URLs, and so do most other email clients (at least Evolution and mutt do). One exception is Thunderbird which doesn't support attach= in mailto URLs for security reasons so we have to use a different command-line for thunderbird (just like xdg-email does).

Tested kmail, thunderbird and mutt after selecting them in kcmshell5 componentchooser (though mutt exits before sending the email, since it's not properly configured).

KF6 task: https://phabricator.kde.org/T14328

Edited by David Faure

Merge request reports