slc1290@hare.udev.cdc.com (steve chesney x4662) (05/17/91)
Our application has a possible use for something like the XmList widget to display narrative text. (This text is reference only, so a text widget IMHO is inappropriate). The List widget comes with behavior that allows the user to select from the list. I cannot find a way to turn this behavior off as selection makes no sense in this context. Is there a straightforward way (straighter than playing with highlight color resources) to turn off selection in a list? -- Steve Chesney Control Data Corporation slc1290@hare.udev.cdc.com
nazgul@alfalfa.com (Kee Hinckley) (05/17/91)
> Our application has a possible use for something like the XmList widget to > display narrative text. (This text is reference only, so a text widget IMHO is > inappropriate). The List widget comes with behavior that allows the user to I'm not sure why text is inappropriate. It seems to me a readonly text widget is exactly what you'd want. Particularly since the user may want to select pieces of it. Alfalfa Software, Inc. | Poste: The EMail for Unix nazgul@alfalfa.com | Send Anything... Anywhere 617/646-7703 (voice/fax) | info@alfalfa.com I'm not sure which upsets me more: that people are so unwilling to accept responsibility for their own actions, or that they are so eager to regulate everyone else's.
bonnett@seismo.CSS.GOV (H. David Bonnett) (05/17/91)
My approach to this is to use an XmLabel in a scrolled window. This way I can just change the text in a single call w/o the problems of dealing with the List widget. This is inherently unselectable. I can post/mail code if you need it. -- -dave bonnett- Center for Seismic Studies; Arlington, VA bonnett@seismo.css.gov : All standard disclaimers apply.
jfr@locus.com (Jon Rosen) (05/18/91)
In article <33292@shamash.cdc.com> slc1290@hare.udev.cdc.com (steve chesney x4662) writes: >Our application has a possible use for something like the XmList widget to >display narrative text. (This text is reference only, so a text widget IMHO is >inappropriate). The List widget comes with behavior that allows the user to >select from the list. I cannot find a way to turn this behavior off as >selection makes no sense in this context. Is there a straightforward way >(straighter than playing with highlight color resources) to turn off selection >in a list? I don't think you want to use an XmList widget. If I understand you correctly, you want to use a widget to display narrative text read-only (i.e., your comment that it is for reference only...) The XmList widget is explicitly for selection purposes. While you presumably could go in an override al the translations and shut off the selection mechanism, it would be simpler to use an XmText widget and set XmNeditable to False. This says the text widget can not allow editing (i.e., read-only). We do this with our help screens and it works fine. Jon Rosen
beau1029@mstr.hgc.edu (donald beaudry) (05/18/91)
In article <33292@shamash.cdc.com> slc1290@hare.udev.cdc.com (steve chesney x4662) writes: > ...Is there a straightforward way >(straighter than playing with highlight color resources) to turn off selection >in a list? > Sure there is... try XtSetSensitive(my_list_widget, 0).