On Mon, 27 Mar 2000, Sven Radej wrote: > On Mon, 27 Mar 2000, Stefan Taferner wrote: > (...) > >It's ported, by does not use QString yet. I am stuck at the point that I > >would like to keep encodings out of kmail if possible, but I was not able > >to decide in which format the mails should be kept. > > Hmm... do I get it right? > If someone uses special charsets (Latin 2, cyrilics, or two byte, Chinese, > whatever) it is encoded and mail always travels encoded. Shouldn´t > KMMessage class handle only technical stuff, like setting/getting headers, > adding/getting parts, etc? If so, it is only QCString job (or am I very > wrong?). Decoding should be done at very end, when displaying text, images, > whatever, right? Not if you want to work with the data. E.g. sort by subject or search in the text. Then you need to decode it first. It even makes sense to decode it when the mail enters the running application. Then you don't have to bother encodings for the lifetime of the message in memory. If you do decoding when the message is read, you loose the original message. But if you keep the original, you need twice as much memory. Not that problem for one message, but if there are a couple of parsed messages .... What do you think is better? having only currently required messages in memory, or having all messages opened of the current folder? The first version conserves memory, the second is faster. Kind regards, Stefan