I
ivan
Hello,
How do I move the keyboard cursor position in a Tix.HList?
I am using an HList with the right mouse button bound to pop up a
menu. If the right click is done on an unselected item, I change the
selection to that item. This works, however the keyboard cursor
position remains at the last item selected with arrow keys or left
click. How can I move this as well as the selection?
def onrightclick(event):
rightselected=hlist1.nearest(event.y)
if hlist1.selection_includes(rightselected) <> "0":
callpopup(rightselected)
else:
hlist1.selection_clear()
hlist1.selection_set(rightselected)
callpopup(rightselected)
hlist1.bind("<Button-3>", onrightclick)
Thanks,
Ivan
How do I move the keyboard cursor position in a Tix.HList?
I am using an HList with the right mouse button bound to pop up a
menu. If the right click is done on an unselected item, I change the
selection to that item. This works, however the keyboard cursor
position remains at the last item selected with arrow keys or left
click. How can I move this as well as the selection?
def onrightclick(event):
rightselected=hlist1.nearest(event.y)
if hlist1.selection_includes(rightselected) <> "0":
callpopup(rightselected)
else:
hlist1.selection_clear()
hlist1.selection_set(rightselected)
callpopup(rightselected)
hlist1.bind("<Button-3>", onrightclick)
Thanks,
Ivan