# HG changeset patch # User Luke Schierer # Date 1079555024 0 # Node ID 5562e8a74c94a509b8e64089b7e3d1197bf895d5 # Parent 4b4547b23facd6f1cd9b485935a43a4322ddd132 [gaim-migrate @ 9196] " if the user has the pref set to false, we're still handling the key.. This is bad if for instance.. the user wants to do something like ctrl-shift-b-3 to display a superscripted 3. This patch makes the callback function return FALSE so that it will propergate down to the GtkTextView and give the user the desired behavior. i realized this will conflict when i finish 9, 10, and 11 on simguys list, and since i already had 11 done.. I'll just throw it in with this.. so here's the updated update patch ;) simguy's imhtml bug 11 is that the italic and underline buttons don't get toggled when you press ctrl-i ctrl-u this fixes that as well as my initial comment ;)" --Gary Kramlich committer: Tailor Script diff -r 4b4547b23fac -r 5562e8a74c94 src/gtkimhtml.c --- a/src/gtkimhtml.c Wed Mar 17 18:23:30 2004 +0000 +++ b/src/gtkimhtml.c Wed Mar 17 20:23:44 2004 +0000 @@ -393,9 +393,10 @@ object = g_object_ref(G_OBJECT(imhtml)); g_signal_emit(object, signals[TOGGLE_FORMAT], 0, GTK_IMHTML_BOLD); g_object_unref(object); + return TRUE; } } - return TRUE; + return FALSE; break; case 'f': @@ -410,17 +411,27 @@ case 'i': case 'I': if (imhtml->format_functions & GTK_IMHTML_ITALIC) - if(imhtml->html_shortcuts) + if(imhtml->html_shortcuts) { gtk_imhtml_toggle_italic(imhtml); - return TRUE; + object = g_object_ref(G_OBJECT(imhtml)); + g_signal_emit(object, signals[TOGGLE_FORMAT], 0, GTK_IMHTML_ITALIC); + g_object_unref(object); + return TRUE; + } + return FALSE; break; case 'u': /* ctrl-u is GDK_Clear, which clears the line. */ case 'U': if (imhtml->format_functions & GTK_IMHTML_UNDERLINE) - if(imhtml->html_shortcuts) + if(imhtml->html_shortcuts) { gtk_imhtml_toggle_underline(imhtml); - return TRUE; + object = g_object_ref(G_OBJECT(imhtml)); + g_signal_emit(object, signals[TOGGLE_FORMAT], 0, GTK_IMHTML_UNDERLINE); + g_object_unref(object); + return TRUE; + } + return FALSE; break; case '-':