Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!olivea!spool.mu.edu!think.com!sdd.hp.com!elroy.jpl.nasa.gov!ncar!gatech!mcnc!rti!mozart!sondheim.unx.sas.com!julian From: julian@sondheim.unx.sas.com (Phil Julian) Newsgroups: comp.windows.x.motif Subject: Re: problems with scrolled list widget Keywords: list scroll Message-ID: <1991Jun18.144448.21954@unx.sas.com> Date: 18 Jun 91 14:44:48 GMT References: <1991Jun10.151441.25250@bwdls61.bnr.ca> Sender: news@unx.sas.com (Noter of Newsworthy Events) Reply-To: julian@sondheim.unx.sas.com (Phil Julian) Organization: SAS Institute Inc. Lines: 35 Nntp-Posting-Host: sondheim.unx.sas.com In article <1991Jun10.151441.25250@bwdls61.bnr.ca>, dannyd@bwdls47.bnr.ca (Daniel Duguay) writes: |> I'm running Motif 1.1 under HP-UX 7.05. |> |> I've got a scrolled list widget created using XmCreateScrolledList |> that I regenerate by doing on XmDeleteAllItems and adding the |> new items using XmListAddItem(w, XmString, i+1). |> |> If the list has enough items that a scrollbar is required, one |> appears. If I try to regenerate the list after I've moved the |> scrollbar down even slightly, my application goes runaway. If I leave the |> scrollbar in its initial position ( the top of the list is seen ), I have |> no problems. Has anyone experienced similar problems ?? Here's a look |> at my application after a kill -11. |> ... ... ... |> Danny |> dannyd@bnr.ca If you just want to update the list selections, then why don't you try setting the resources. I have used this to update a list in extended selection mode, because figuring out what has been updated seems too complex. I used this code in a callback routine which copies the selected items from one list to another: void Copy2_rt_list (w, client_data, call_data) Widget w; caddr_t *client_data; XmListCallbackStruct *call_data; { int n; Arg args[10]; n = 0; XtSetArg (args[n], XmNitemCount, call_data->selected_item_count); n++; XtSetArg (args[n], XmNitems, call_data->selected_items); n++; XtSetValues (rt_list, args, n); }