I'm using lieer/gmi to send email, and it has the builtin assumption
that no new messages will be added to the maildir.
See https://github.com/gauteh/lieer/issues/54
When a new message was saved after sending, the address headers were not
encoded correctly. The complete header was encoded as one encoded word
without separating the tokens.
For example the header
To: émail <émail@example.net>, mail <mail@example.net>\n\n
was stored as
=?utf-8?b?w6ltYWlsIDzDqW1haWxAZXhhbXBsZS5uZXQ+LCBtYWlsIDxtYWlsQGV4YW1wbGUubmV0Pg==?=\n\n
in stead of
To: =?utf-8?q?=C3=A9mail?= <=?utf-8?q?=C3=A9mail?=@example.net>, mail <mail@example.net>\n\n
This incorrect header ended up in the notmuch database and the message
was not found with address queries.
The solution also improves utf8 handling by storing all headers and body utf8
encoded (in stead of using 7bit encoding).
Sending emails do not require all the hooks to be called:
E.g. one may be calling `mbsync` on their `notmuch` hooks and hence be forced to wait quite some time on each sent email.
Tags are suggested when the prefixes ` +`, ` -` or ` tag:` are found in the inserted text.
We deactivate some keymappings to when the completion menu is shown.
When this happens TAB and ENTER select the highlighted suggestion, UP and DOWN change the selection, ESC hide the menu.
QWebEnginePage.acceptNavigationRequest only intercepts navigating to a
different URL (i.e. clicking a link). Any other requests don't use this
method, so remote images, stylesheets, etc. would still be loaded.
Obviously this can enable tracking in malicious messages.
By also setting a QWebEngineUrlRequestInterceptor on the profile, all
requests are intercepted. Local protocols are allowed, and for
everything else, settings.html_block_remote_requests is used to decide
whether to block the request.