[pygtk] GtkWarning: gdk_drawable_get_display

Sandro Dentella sandro at e-den.it
Fri Apr 7 20:27:42 WST 2006


when emitting a 'key-press-event' I get this warnng: what does that
mean. How can I fix it? This is the code that generates the warning:

    entry = gtk.Entry()
    event =   gtk.gdk.Event(gtk.gdk.KEY_PRESS)
    event.keyval = ord(".")
    entry.emit('key-press-event',event)

entry2.py:11: GtkWarning: gdk_drawable_get_display: assertion `GDK_IS_DRAWABLE (drawable)' failed
  entry.emit('key-press-event',event)
entry2.py:11: GtkWarning: gdk_keymap_get_for_display: assertion `GDK_IS_DISPLAY (display)' failed
  entry.emit('key-press-event',event)
entry2.py:11: GtkWarning: gdk_window_set_cursor: assertion `GDK_IS_WINDOW (window)' failed
  entry.emit('key-press-event',event)



I'm using pygtk 2.8.2 and python 2.4.

TIA
sandro
*:-)

PS: how can I emit a 'BackSpace'?

-- 
Sandro Dentella  *:-)
e-mail: sandro a e-den.it 
http://www.tksql.org                    TkSQL Home page - My GPL work


More information about the pygtk mailing list