[gimp] app: block all unhandled key events in the text style editor



commit 6fcb5c137d3fa52ec0d9ec0a64c7d008426a3e2f
Author: Michael Natterer <mitch gimp org>
Date:   Thu Mar 4 18:53:53 2010 +0100

    app: block all unhandled key events in the text style editor
    
    so they don't affect the on-canvas editor.

 app/widgets/gimptextstyleeditor.c |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/app/widgets/gimptextstyleeditor.c b/app/widgets/gimptextstyleeditor.c
index f48c8f3..2aecc2c 100644
--- a/app/widgets/gimptextstyleeditor.c
+++ b/app/widgets/gimptextstyleeditor.c
@@ -161,6 +161,14 @@ gimp_text_style_editor_init (GimpTextStyleEditor *editor)
 {
   GtkWidget *image;
 
+  /*  don't let unhandled key events drop through to the text editor  */
+  g_signal_connect_after (editor, "key-press-event",
+                          G_CALLBACK (gtk_true),
+                          NULL);
+  g_signal_connect_after (editor, "key-release-event",
+                          G_CALLBACK (gtk_false),
+                          NULL);
+
   /*  upper row  */
 
   editor->upper_hbox = gtk_hbox_new (FALSE, 0);
@@ -173,14 +181,6 @@ gimp_text_style_editor_init (GimpTextStyleEditor *editor)
                       FALSE, FALSE, 0);
   gtk_widget_show (editor->font_entry);
 
-  /*  don't let unhandled key events drop through to the text editor  */
-  g_signal_connect_after (editor->font_entry, "key-press-event",
-                          G_CALLBACK (gtk_true),
-                          NULL);
-  g_signal_connect_after (editor->font_entry, "key-release-event",
-                          G_CALLBACK (gtk_false),
-                          NULL);
-
   editor->size_label = gtk_label_new ("0.0");
   gtk_misc_set_padding (GTK_MISC (editor->size_label), 2, 0);
   gtk_box_pack_start (GTK_BOX (editor->upper_hbox), editor->size_label,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]