0

I want to set focus on entry that is not visible in pyGTK for a barcode scanner.

If I set entry to visible false then I get this error when setting focus on it.

    /home/samuel/visitors-book/visitors_book/__init__.py:60: GtkWarning: IA__gtk_widget_event: assertion `WIDGET_REALIZED_FOR_EVENT (widget, event)' failed
  gtk.main()

Thanks Sam

Samuel Taylor
  • 1,181
  • 2
  • 14
  • 25

1 Answers1

2

You could do without a GtkEntry and capture the keyboard events directly.

But is it so bad to have the entry visible? All barcode terminals I've seen confirm what is read.

Tobias
  • 3,882
  • 2
  • 22
  • 25