Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado
Re: Non-exclusive buttons initial selection
munter@glhpx11.cen.uiuc.edu (Alan Edwin Munter) wrote: > > I have been trying to figure out how to select one of a bgroup of three > non-exclusive buttons when the widget is realized. > > The command: > > WIDGET_CONTROL, bgroup1, set_button=1 > > will select all of them, but I can't figure out how to select > just one. > When you create the widget button-group, use the keyword IDS to return a lonarr containing the widget id's of the individual buttons in the group: bgroup1 = cw_bgroup( tlb, ..., ids = ids_grp1, ...) Then use widget_control on these individual button widgets: widget_control, ids_grp1(0), set_button=1 widget_control, ids_grp1(1), set_button=0 ... Dave Foster UCSD Brain Image Analysis Laboratory foster@bial1.ucsd.edu