Bug 479932

Summary: Mail display eat spaces after quote characters
Product: [Applications] kmail2 Reporter: Jerôme Pouiller <jerome.pouiller>
Component: message listAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: montel
Priority: NOR    
Version: 5.22.3   
Target Milestone: ---   
Platform: Debian stable   
OS: Linux   
Latest Commit: Version Fixed In: 6.0.0
Sentry Crash Report:
Attachments: display-issue

Description Jerôme Pouiller 2024-01-17 09:37:06 UTC
Created attachment 164971 [details]
display-issue

STEPS TO REPRODUCE
1. Receive a text mail with spaces characters after quote character. Like that:

> I feel this algorithm complex. I believe I would have written
> something like:
>
>     if (!ctxt->uart_next_frame_ready)
>         uart_read(ctxt);

OBSERVED RESULT

The spaces after '>' are ignored (see screenshot).

Notes:
  - Kmail behaves as expected if several '>' are used
  - I have checked the spaces are still there by looking at the source of the mail
  - The spaces are at the right pace when I reply to the mail.
Comment 1 Jerôme Pouiller 2024-01-17 09:47:19 UTC
The HTML result is different if one quote or several '>' are used.

With one quote:
    <div dir="ltr"><span class="quotemarks">&gt;      </span><font color="#209150">if

With two quotes (in a further reply):
    <div dir="ltr"><span class="quotemarks">&gt;&gt; </span><font color="#1d2791">&nbsp;&nbsp;&nbsp;&nbsp; if
Comment 2 Laurent Montel 2024-01-17 15:52:54 UTC
Hi,
I will  investigate it soon.
Thanks
Comment 3 Laurent Montel 2024-01-31 07:13:27 UTC
Git commit 4aa0cc88d1f758d289bd72400d7af2f3ce4fddd6 by Laurent Montel.
Committed on 31/01/2024 at 07:13.
Pushed by mlaurent into branch 'release/24.02'.

Fix bug 479932: Mail display eat spaces after quote characters

FIXED-IN: 6.0.0

M  +2    -2    messageviewer/src/messagepartthemes/default/plugins/quotehtml.cpp

https://invent.kde.org/pim/messagelib/-/commit/4aa0cc88d1f758d289bd72400d7af2f3ce4fddd6