Newsgroups: comp.windows.x.motif Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!fmrco!sy18337 From: sy18337@fmrco (Terry Traub) Subject: XmList question Message-ID: <1991May16.190348.22823@fmrco> Summary: Setting position in a list Keywords: Motif XmList listbox XmListSetPos Reply-To: sy18337@fmrco.UUCP (Terry Traub) Organization: Fidelity Investment, Boston, MA 02109 Distribution: comp.windows.x.motif Date: Thu, 16 May 91 19:03:48 GMT This is a question regarding XmList in Motif 1.0, X11R4 on SParcStations. I am using Motif listboxes in Browse Select mode to display some rather long lists. I would like to let the user page through the list with keypad commands PgUp, PgDn, Home, and End, but only the Up and Down arrows are supported. I added a KeyPress event handler to intercept these other keystrokes, and it works pretty well, except that when I do an XmListSelectPos(w, 1, True) (followed by XmListSetPos(w, 1)) to home the list, the reverse video bar moves to the desired location (1, in this case) but the highlight box stays where it was, and pressing Up or Down causes the reverse video bar to jump back down to the original location (one up or one down, actually). The question is, how do you force the listbox to completely reset to the position you want? Clearly XmListSetPos() is not enough, though the documentation suggests otherwise. Also, does Motif 1.1.1's list box have this added functionality? I hope there's a painless solution; our users, and I too for that matter, are accustomed to MS Windows' list boxes, which have much better keyboard support built in. Thanks for any help!!! Terry Traub Fidelity Investments uunet!fmrco!lanyard!ttraub