Commit Graph

257 Commits

Author SHA1 Message Date
a260d79633 EMailFormatterQuoteExtension: Don't be cute with struct declarations.
Declare the instance and class structs normally so Gtk-Doc can make
sense of it.
2013-07-07 09:28:50 -04:00
3774c9c4c1 EMailFormatterPrintExtension: Don't be cute with struct declarations.
Declare the instance and class structs normally so Gtk-Doc can make
sense of it.
2013-07-07 09:26:25 -04:00
0cb0dc0ddd Bug #699576 - Mail reader frame is black (in the mail view) 2013-06-27 20:57:41 +02:00
7b8a8a6a24 EMailFormatter: Remove the header API.
Use the EMailPartHeaders API instead.
2013-06-08 00:25:15 -04:00
06e391117a EMailFormatterQuoteHeaders: Avoid EMailFormatter header API.
Use e_mail_part_headers_dup_default_headers() to extract specific
headers to show in the desired order.
2013-06-08 00:25:15 -04:00
93d5cdd57a EMailFormatterHeaders: Avoid EMailFormatter header API.
Use e_mail_part_headers_dup_default_headers() to extract specific
headers to show in the desired order.
2013-06-08 00:25:15 -04:00
27c92e7f3d Add EMailPrintConfigHeaders.
This splits the print dialog's "Headers" tab into a separate widget.

EMailPrintConfigHeaders takes an EMailPartHeaders and displays its print
model, which is a representation of all message headers (except subject)
with an on/off flag for each.  The headers can be toggled and reordered,
and the changes are written back to the print model.

During printing, EMailFormatterPrintHeaders uses the same print model
to determine which headers to show and in what order (except subject).

This approach is much saner than the old method, which was trying to
manipulate WebKitWebView DOM directly to toggle and reorder headers.
This approach also happens to work, whereas the old method did not.
2013-06-08 00:25:15 -04:00
64388b6b82 Add e_mail_part_headers_ref_print_model().
Returns a GtkTreeModel of header names and values and visibility flags,
built from the CamelMimeMessage.  The tree model rows can be reordered
and toggled prior to printing.

Also add e_mail_part_headers_is_default() as a handy helper.
2013-06-08 00:25:15 -04:00
c5313b3614 EMailPartHeaders: Add a "default-headers" property.
This will replace the headers API in EMailFormatter.  Need a more
permanent place for headers since EMailFormatter is too disposable.

Also add an ESettingsMailPartHeaders class, which binds the new property
to the "show-headers" setting with a suitable mapping function to filter
out disabled header names.
2013-06-08 00:25:11 -04:00
bcfd1a9257 Make EMailPart and its subclasses extensible. 2013-06-07 15:47:14 -04:00
9a1265ea24 EMailFormatterQuoteHeaders cleanups. 2013-06-07 15:47:03 -04:00
257286b6ce EMailFormatterHeaders cleanups. 2013-06-07 15:47:03 -04:00
863fee6479 e_mail_formatter_format_header: Split the header param.
Split the _camel_header_raw struct parameter into separate "header_name"
and "header_value" string parameters, which is all the function actually
needs to work.
2013-06-06 14:08:21 -04:00
312d230cd2 e_mail_formatter_format_header: Remove unused CamelMedium param. 2013-06-06 13:54:42 -04:00
6be4901bae EMailPart: Add "part-list" property.
This is a weak reference to the EMailPartList to which the EMailPart
has been added.  The property is set by e_mail_part_list_add_part().

New functions:

  e_mail_part_ref_part_list()
  e_mail_part_set_part_list()
2013-06-05 16:38:31 -04:00
552952d2cc Define GEnumClass types for mail formatter/parser enums. 2013-06-04 13:10:02 -04:00
9b9d1935d7 Remove Evolution icon from header section.
We don't show an icon for other mailers, and the tiny 16x16 pixel
icon looks stupid next to the much larger contact/gravatar image.
2013-05-29 13:09:36 -04:00
2d251a9597 Distinguish "attachment-wrapper" elements from attachments.
The HTML for attachments always has the following form:

<div class="attachment-wrapper" id="something" style="display: block;">
  <actual attachment element>
</div>

The <div> element controls attachment visibility through its "display"
style attribute, which is either "block" or "none".

Problem is the <actual attachment element> was getting the same ID as
its parent <div> element.  So when either element was requested by ID,
in certain cases the wrong element was returned and caused misbehavior
and console warnings.

Solve this by adding a "wrapper" suffix to the <div> element ID.  So in
the example above, id="something" gets the <actual attachment element>,
whereas id="something.wrapper" gets the <div> element.
2013-05-29 07:09:20 -04:00
fa39ba7c5d EMailFormatterAttachment cleanups. 2013-05-29 07:09:20 -04:00
04aa0fba1f Rename libemformat to libevolution-mail-formatter.
To make Evolution's shared libraries more consistent.

Also add an evolution-mail-formatter documentation module.
2013-05-28 09:56:30 -04:00
70a9fcdf9c Rename libeshell to libevolution-shell.
To make Evolution's shared libraries more consistent.

Also rename the documentation module to evolution-shell.
2013-05-28 09:56:30 -04:00
6c9a3243c9 Rename libeutil to libevolution-util.
To make Evolution's shared libraries more consistent.

Also rename the documentation module to evolution-util.
2013-05-28 09:56:30 -04:00
9058c6f85d Make EAttachment a little more thread-safe.
EAttachment is now used from worker threads by EMailFormatterAttachment,
so add some thread-safe accessor functions to eliminate potential races.

Added thread-safe functions:

    e_attachment_dup_disposition()
    e_attachment_ref_file()
    e_attachment_ref_file_info()
    e_attachment_ref_icon()
    e_attachment_ref_mime_part()
    e_attachment_dup_description()
    e_attachment_dup_thumbnail_path()

Renamed functions:

    e_attachment_get_mime_type() -> e_attachment_dup_mime_type()

Removed non-thread-safe functions:

    e_attachment_get_file()
    e_attachment_get_file_info()
    e_attachment_get_icon()
    e_attachment_get_mime_part()
    e_attachment_get_description()
    e_attachment_get_thumbnail_path()
2013-05-23 16:36:02 -04:00
256422cab2 Attachment-related cleanups. 2013-05-23 16:36:01 -04:00
f9ffe64723 Convert EMailPart to a GObject.
EMailPart is reference-counted, subclassed, and allows a custom
finalize function.  There's no excuse for it not to use GObject.
2013-05-19 13:07:22 -04:00
62daae00eb Add e_mail_part_attachment_ref_attachment(). 2013-05-19 13:07:21 -04:00
67227b428b Add e_mail_part_get_validity_flags(). 2013-05-19 13:07:21 -04:00
543b4d9321 Add e_mail_part_has_validity(). 2013-05-19 13:07:21 -04:00
42d1e89f02 Add e_mail_part_set_is_attachment(). 2013-05-19 13:07:21 -04:00
ca09edf8fa Add e_mail_part_get_is_attachment(). 2013-05-19 13:07:21 -04:00
875746e0ef Add e_mail_part_set_mime_type(). 2013-05-19 13:07:21 -04:00
0ee556d346 Add e_mail_part_get_mime_type(). 2013-05-19 13:07:21 -04:00
f19058ea7a Add e_mail_part_ref_mime_part(). 2013-05-19 13:07:20 -04:00
5ad0b6d8f7 Add e_mail_part_id_has_substr(). 2013-05-19 13:07:20 -04:00
5fd2243080 Add e_mail_part_id_has_suffix(). 2013-05-19 13:07:20 -04:00
366b731a16 Add e_mail_part_id_has_prefix(). 2013-05-19 13:07:20 -04:00
794e28d239 Add e_mail_part_set_cid(). 2013-05-19 13:07:20 -04:00
5bea269ce8 Add e_mail_part_get_cid(). 2013-05-19 13:07:20 -04:00
c025ffbb29 Add e_mail_part_get_id(). 2013-05-19 13:07:20 -04:00
cd5a55f981 em-format cleanups. 2013-05-19 13:07:20 -04:00
f6f11a1da2 EMailPart: Store validity pairs in a GQueue. 2013-05-19 13:07:20 -04:00
2207b9f8a3 Remove e_mail_formatter_get_headers().
Not thread-safe.  Use e_mail_formatter_dup_headers() instead.
2013-05-14 15:20:14 -04:00
2c5d0444bb Add e_mail_formatter_header_copy().
Duplicates an EMailFormatterHeader struct.
2013-05-14 15:20:14 -04:00
d80d4b16d6 EMailFormatterPrint cleanups. 2013-05-14 15:20:14 -04:00
5551dd5a54 EMailFormatter cleanups. 2013-05-14 15:20:14 -04:00
448aa307c3 Right-align mail header names.
We used to do this before WebKit and it looked better.

Also fix up the header section for right-to-left locales:
put the collapse button on the right, and images on the left.
2013-05-08 23:06:23 -04:00
26ca1f2c56 EMailFormatterHeaders cleanups. 2013-05-08 14:39:21 -04:00
58ef547151 Coding style and whitespace cleanup. 2013-05-08 08:28:09 -04:00
9567024148 Bug #699551 - Signature is not removed on reply 2013-05-06 19:31:43 +02:00
2a0d0870ca Bug #696531 - Force white background for HTML parts 2013-05-03 11:03:35 +02:00