No keyboard input in DirectEntry text box

Howdy,

When I try to use a DirectEntry field, in either my own code or unmodified provided examples (FloatingMessages), I cannot get keys to show up in the DirectEntry box. It gets weirder. If I have an initial text, I can hit enter and have the text fed into the supplied command function. So, the keyboard does seem to be interfacing properly (I have some other keybindings which all work), the DirectEntry box seems to work, it just won’t accept keyboard input as text.

Thanks!

FloatingMessages - python-panda3d-examples.googleco … essages.py

Linux, OSX, or Windows? The codepath for accepting keypresses for typing is different from that for just accepting button presses. This is because the former has to accept international key sequences and virtual character typing. On Linux, in particular, this might be broken if something is not quite configured properly in your X11 installation.

David

Your code works fine for me on Ubuntu 8.04, so it looks like something with your system.

Arrr… yeah, panda3d has played much more nicely on my linux boxes, but this issue is coming from an OS X machine (maybe I was lucky enough just to get it to install properly? :stuck_out_tongue:).

Could this be an X11 in OS X issue? I’m not quite sure where to start on this one, since keyboard input only has an issue with entering text in a DirectEntry box.

Thanks,
Kyle

On OSX, the DirectEntry responds to kEventClassTextInput, whereas the other button presses go through kEventClassKeyboard. Maybe there’s some reason why kEventClassTextInput isn’t generating any events on your machine for some reason?

David

I have tried it (under osx) and it seems to work fine (as far as i can tell). I dont think X11 could have a influence on this problem.