(Basic) decoding now works



Hi there,

For standard encodings, there's a new function which should be used in
stead of the write_to_stream:

void tny_msg_mime_part_iface_decode_to_stream (TnyMsgMimePartIface
*self, TnyStreamIface *stream);

The write_to_stream will write the mime-part exactly like how it's in
the E-mail. So it will not be decoded.

This new decode_to_stream supports a few standard encodings like base64,
uuencoded, quoted printable and the text/* encodings including some
windows encodings. There's also a _is_attachment method/property for the
mime-part type; this will determine whether or not a specific mime-part
is to be considered as a attachment (for example some signatures like
the pgp signature isn't an attachment).

It's not yet possible to add your own decoder/encoder nor filter. I'm
not sure whether or not this is really needed. For crafting E-mails with
mime-parts it will be needed to encode the mime-parts you add. I might,
however, automate this in the library. Making an external/extra encoder/
decoder api in tinymail perhaps unnecessary.


-- 
Philip Van Hoof, software developer at x-tend 
home: me at pvanhoof dot be 
gnome: pvanhoof at gnome dot org 
work: vanhoof at x-tend dot be 
http://www.pvanhoof.be - http://www.x-tend.be




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