aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2001-08-06 00:55:13 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2001-08-06 00:55:13 +0800
commitf29e762e0bc379caef1a2899d7d8bd43c2d45228 (patch)
tree142883443548d5e26db1ef37ec076ef341a7fa2f /mail
parentee07364c0671bad04c76f3c7b8775b4c8e241ef0 (diff)
downloadgsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar.gz
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar.bz2
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar.lz
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar.xz
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.tar.zst
gsoc2013-evolution-f29e762e0bc379caef1a2899d7d8bd43c2d45228.zip
Make the title of the window "subject - Message" instead of just
* message-browser.c (message_browser_message_loaded): Make the title of the window "subject - Message" instead of just "subject". Also, display "(No subject)" if the subject is NULL. [Fix #6399, 8-bit characters are not displayed in window title.] * message-browser.c (message_browser_message_loaded): Convert the subject from UTF-8 to GTK. svn path=/trunk/; revision=11695
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog11
-rw-r--r--mail/message-browser.c14
2 files changed, 24 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 275a54671a..bb1caf2ace 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,5 +1,16 @@
2001-08-05 Ettore Perazzoli <ettore@ximian.com>
+ * message-browser.c (message_browser_message_loaded): Make the
+ title of the window "subject - Message" instead of just "subject".
+ Also, display "(No subject)" if the subject is NULL.
+
+ [Fix #6399, 8-bit characters are not displayed in window title.]
+
+ * message-browser.c (message_browser_message_loaded): Convert the
+ subject from UTF-8 to GTK.
+
+2001-08-05 Ettore Perazzoli <ettore@ximian.com>
+
[Revert the previous changes, there seems to be something wrong
with it.]
diff --git a/mail/message-browser.c b/mail/message-browser.c
index 741c663cd8..4562ff8eb5 100644
--- a/mail/message-browser.c
+++ b/mail/message-browser.c
@@ -25,6 +25,8 @@
#endif
#include <gal/util/e-util.h>
+#include <gal/widgets/e-unicode.h>
+
#include <bonobo/bonobo-exception.h>
#include <bonobo/bonobo-ui-component.h>
#include <bonobo/bonobo-ui-container.h>
@@ -108,6 +110,7 @@ message_browser_message_loaded (FolderBrowser *fb, const char *uid, MessageBrows
{
CamelMimeMessage *message;
char *subject = NULL;
+ char *title;
g_warning ("got 'message_loaded' event");
@@ -115,8 +118,17 @@ message_browser_message_loaded (FolderBrowser *fb, const char *uid, MessageBrows
if (message)
subject = (char *) camel_mime_message_get_subject (message);
+
+ if (subject != NULL)
+ subject = e_utf8_to_gtk_string (GTK_WIDGET (mb), subject);
+ else
+ subject = _("(No subject)");
+
+ title = g_strdup_printf (_("%s - Message"), subject);
- gtk_window_set_title (GTK_WINDOW (mb), subject ? subject : "");
+ gtk_window_set_title (GTK_WINDOW (mb), title);
+
+ g_free (title);
}
static void