From bac1a59d59bb0326bb8b634bbf6ec973b20efd16 Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Thu, 26 Feb 2004 20:42:07 +0000 Subject: Add a
tag between the message text and the signature text (makes it 2004-02-26 Jeffrey Stedfast * e-msg-composer.c (set_editor_text): Add a
tag between the message text and the signature text (makes it nicer looking and also fixes bug #53747. svn path=/trunk/; revision=24897 --- composer/ChangeLog | 8 +++++++- composer/e-msg-composer.c | 16 +++++++++------- 2 files changed, 16 insertions(+), 8 deletions(-) (limited to 'composer') diff --git a/composer/ChangeLog b/composer/ChangeLog index a40f8c785c..a2be3658e4 100644 --- a/composer/ChangeLog +++ b/composer/ChangeLog @@ -1,3 +1,9 @@ +2004-02-26 Jeffrey Stedfast + + * e-msg-composer.c (set_editor_text): Add a
tag between the + message text and the signature text (makes it nicer looking and + also fixes bug #53747. + 2004-02-17 Radek Doulik * e-msg-composer.c (e_msg_composer_unrealize): renamed from unmap @@ -66,7 +72,7 @@ 2004-01-28 Not Zed ** See Bug #53176, probably fixes others too. - + * e-msg-composer.c (set_editor_text): When we set the text, always add the signature implictly. Means we don't have to set it manually and break changing the file, or hit any races. diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index b91d6205fd..a399b47b26 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -1094,13 +1094,15 @@ set_editor_text(EMsgComposer *composer, const char *text, int setsig) /* This copying bullshit is because the bonobo stream interface is just painful */ len = strlen(text); - if (setsig - && (sig = get_signature_html(composer))) { - len += strlen(sig); - content = mem = g_malloc(len+1); - memcpy(mem, text, strlen(text)); - strcpy(mem + strlen(text), sig); - g_free(sig); + if (setsig && (sig = get_signature_html (composer))) { + char *p; + + len += strlen (sig) + 4; + content = p = mem = g_malloc (len + 1); + p = g_stpcpy (mem, text); + p = g_stpcpy (p, "
"); + strcpy (p, sig); + g_free (sig); } else { content = text; } -- cgit