discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GNUMail running on macOS 12.6 (Apple Silicon)


From: H. Nikolaus Schaller
Subject: Re: GNUMail running on macOS 12.6 (Apple Silicon)
Date: Tue, 27 Sep 2022 08:16:43 +0200

Hi

> Am 26.09.2022 um 16:04 schrieb Riccardo Mottola <riccardo.mottola@libero.it>:
> 
> Hi,
> 
> 
> On 2022-09-26 12:05:41 +0000 Ondrej Florian <onflapp@yahoo.com> wrote:
> 
>> Hi Hugo,
>> I am working on GNUMail extensively myself.
>> Just currious, did you get IMAP working?
>> I got POP3 working after some patching but IMAP is still problematic.
> 
> that is strange, both work since a long time and I use IMAP with GNUmail 
> since years, even for reading and composing this right mail.
> 
>> Support for attachment is still hit and miss. For example your message only 
>> shows as text.
> 
> That is, I fear, easily explained. Florian's message was written with Apple's 
> Mail and the the message is HTML, which GNUMail does not support and won't in 
> the near possible future.

Well, it would not be very difficult by either using Apple's WebKit or 
SimpleWebKit to transform the raw message body into an NSAttributedString.

Conversion from HTML to NSAttributedString can be done through code like

https://git.goldelico.com/?p=mySTEP.git;a=blob;f=AppKit/Sources/NSAttributedStringAdditions.m;h=67fd9feb6acd33a7e236b9257250d6106d2a216a;hb=refs/heads/master#l818

It creates an WebView, loads the NSData, waits until done an asks the WebView 
for its attributedString (a standard method of WebKit or SimpleWebKit). I would 
assume that processing RTF formatted mails is also ending up in an 
attributedString through a different path. So there are basically two 
converters NSData -> NSAttributedString depending on mail body format.

SimpleWebkit would be sufficient for simple HTML. AFAIR it is only lacking 
JavaScript (which should not be active in a Mail client anyways) and many CSS 
features (basic CSS also works) but plain text e-mails even with embedded 
attachments should be doable.

> GNUMail supports Text and RTF. So it switches to the Text mail part, but 
> somehow misses to display the attachments, which are not inline anymore. 
> Tricky thing I fear.
> Mozilla SeaMonkey handles it correctly instead.
> 

BR,
Nikolaus





reply via email to

[Prev in Thread] Current Thread [Next in Thread]