Index: em-format-html.c =================================================================== --- em-format-html.c (revision 34757) +++ em-format-html.c (working copy) @@ -1484,22 +1484,34 @@ else html = mhtml = camel_text_to_html (value, emfh->text_html_flags, 0); + gboolean is_rtl = gtk_widget_get_default_direction() == GTK_TEXT_DIR_RTL; if (emfh->simple_headers) { fmt = "%s: %s
"; } else { if (flags & EM_FORMAT_HTML_HEADER_NOCOLUMNS) { - if (flags & EM_FORMAT_HEADER_BOLD) + if (flags & EM_FORMAT_HEADER_BOLD){ fmt = "%s: %s"; - else + }else{ fmt = "%s: %s"; + } } else if (flags & EM_FORMAT_HTML_HEADER_NODEC) { - fmt = "%s %s"; + if(is_rtl) + fmt = "%2$s%1$s "; + else + fmt = "%s %s"; } else { - - if (flags & EM_FORMAT_HEADER_BOLD) - fmt = "%s: %s"; - else - fmt = "%s: %s"; + + if (flags & EM_FORMAT_HEADER_BOLD) { + if(is_rtl) + fmt = "%2$s%1$s: "; + else + fmt = "%s: %s"; + } else { + if(is_rtl) + fmt = "%2$s%1$s: "; + else + fmt = "%s: %s"; + } } } @@ -1838,7 +1850,10 @@ if (header_sender && header_from && mail_from_delegate) { camel_stream_printf(stream, ""); - camel_stream_printf(stream, "
"); + if(gtk_widget_get_default_direction == GTK_TEXT_DIR_RTL) + camel_stream_printf(stream, ""); + else + camel_stream_printf(stream, ""); /* To translators: This message suggests to the receipients that the sender of the mail is different from the one listed in From field. */ @@ -1852,9 +1867,12 @@ g_free (header_sender); g_free (header_from); + + if(gtk_widget_get_default_direction() == GTK_TEXT_DIR_RTL) + camel_stream_printf(stream, "
\n"); + else + camel_stream_printf(stream, "
\n"); - camel_stream_printf(stream, "
\n"); - /* dump selected headers */ h = (EMFormatHeader *)emf->header_list.head; if (h->next == NULL || emf->mode == EM_FORMAT_ALLHEADERS) {