Bug 465601

Summary: mailto URL does not allow a body with line breaks
Product: [Applications] kmail2 Reporter: Pony Hütchen <b5f>
Component: composerAssignee: kdepim bugs <kdepim-bugs>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version First Reported In: 5.22.0   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Pony Hütchen 2023-02-11 22:44:59 UTC
SUMMARY
***
I expected that clicking on a mailto-link like the following inside kmails message viewer will open a message composer with a two lines message:
mailto:test@test.com?subject=test&body=line1%0D%0Aline2
However all the newlines are replaced by spaces.
***


STEPS TO REPRODUCE
1. Create an email that contains the above mailto-link. The link can be as text or within <a href=></a> in an html mail. 
2. Open the mail with kmails message viewer.
3. Click on the link.

OBSERVED RESULT
A composer opens with the text: "line1 line2"

EXPECTED RESULT
A composer should open with the text: "line1
line2"

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.26.4
KDE Frameworks Version: 5.101.0
Qt Version: 5.15.7

ADDITIONAL INFORMATION
Running
kmail "mailto:test@test.com?subject=test&body=line1%0D%0Aline2"
shows the expected behaviour, as well as clicking a mailto-link inside a browser.