wxChoice - GTK forces use of mouse to change selection

Frank Millman wrote:

Thanks, Robin. It turns out that a read-only combo box works better for my
purposes. Thanks for the suggestion.

I have two minor niggles with the combo box -

1. Using GTK, the up/down arrows wrap around from the bottom/top to the
top/bottom of the list if you reach the end/beginning. I don't particularly
like this, and it is inconsistent with the behaviour if you display the full
list - in that case it stays at the top or bottom and does not wrap.

I tried to trap EVT_KEY_DOWN to override this behaviour, but it gives me
every keystroke *except* up/down arrow. Presumably they are swallowed by
EVT_COMBOBOX. Ironically under MSW I do get the arrow keys, but there I am
happy with the behaviour.

These may not be fixable without making changes to gtk.

2. You use Append to append a single item, with or without client data. You
use AppendItems to append many items, but you cannot associate client data
with the items. It would be nice to have the best of both worlds.

This could be accomodated in wxWidgets, but I think it would lose the performance benefits of adding lots of items all at once as it would probably have to fall back to adding them one at a time internally.

ยทยทยท

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!