--- evolution-2.11.2/plugins/print-message/print-message.c.fix-indic-printing 2007-05-13 13:41:09.000000000 -0400 +++ evolution-2.11.2/plugins/print-message/print-message.c 2007-05-18 15:32:12.000000000 -0400 @@ -65,7 +65,7 @@ EMFormatHTMLPrint *efhp; action = GTK_PRINT_OPERATION_ACTION_PREVIEW; - message = e_msg_composer_get_message (composer, 1); + message = e_msg_composer_get_message_print (composer, 1); efhp = em_format_html_print_new (NULL, action); em_format_html_print_raw_message (efhp, message); --- evolution-2.11.2/composer/e-msg-composer.h.fix-indic-printing 2007-04-18 06:17:34.000000000 -0400 +++ evolution-2.11.2/composer/e-msg-composer.h 2007-05-18 15:30:56.000000000 -0400 @@ -101,6 +101,8 @@ CamelMimePart *part); CamelMimeMessage *e_msg_composer_get_message (EMsgComposer *composer, gboolean save_html_object_data); +CamelMimeMessage *e_msg_composer_get_message_print (EMsgComposer *composer, + gboolean save_html_object_data); CamelMimeMessage *e_msg_composer_get_message_draft (EMsgComposer *composer); void e_msg_composer_show_sig_file (EMsgComposer *composer); gboolean e_msg_composer_get_send_html (EMsgComposer *composer); --- evolution-2.11.2/composer/e-msg-composer.c.fix-indic-printing 2007-04-18 06:17:34.000000000 -0400 +++ evolution-2.11.2/composer/e-msg-composer.c 2007-05-18 15:30:56.000000000 -0400 @@ -5273,6 +5273,49 @@ } CamelMimeMessage * +e_msg_composer_get_message_print (EMsgComposer *composer, gboolean save_html_object_data) +{ + EMsgComposer *temp_composer; + CamelMimeMessage *msg; + GString *flags; + + msg = build_message (composer, save_html_object_data); + temp_composer = e_msg_composer_new_with_message (msg); + camel_object_unref (msg); + + /* build flags string */ + flags = g_string_sized_new (128); + if (temp_composer->priv->send_html) + g_string_append (flags, "text/html"); + else + g_string_append (flags, "text/plain"); + if (temp_composer->priv->pgp_sign) + g_string_append (flags, ", pgp-sign"); + if (temp_composer->priv->pgp_encrypt) + g_string_append (flags, ", pgp-encrypt"); + if (temp_composer->priv->smime_sign) + g_string_append (flags, ", smime-sign"); + if (temp_composer->priv->smime_encrypt) + g_string_append (flags, ", smime-encrypt"); + + /* override composer flags */ + temp_composer->priv->send_html = TRUE; + temp_composer->priv->pgp_sign = FALSE; + temp_composer->priv->pgp_encrypt = FALSE; + temp_composer->priv->smime_sign = FALSE; + temp_composer->priv->smime_encrypt = FALSE; + + msg = build_message (temp_composer, save_html_object_data); + camel_medium_set_header (CAMEL_MEDIUM (msg), + "X-Evolution-Format", flags->str); + + e_msg_composer_delete (temp_composer); + g_string_free (flags, TRUE); + + return msg; +} + +CamelMimeMessage * e_msg_composer_get_message_draft (EMsgComposer *composer) { CamelMimeMessage *msg;