yakker@ucrmath.ucr.edu (matt robinson) (08/24/90)
Well, from the response I got from my last question, I guess just one more in the basket won't hurt too much (In other words, you guys who answer questions here are great...Thanks for the time and energy you give to help out others.), so here's my question. I have a text widget which is displaying a file to the user that is read only. Now, the problem I am having with this is that every time there is an update on the file (for whatever reason, almost like a make) I want to read the file from the disk and redisplay it to the user. Right now, I don't know of any widget to just get rid of the source in the file (other than maybe XtTextReplace, but that doesn't allow for a file specification; rather, a char *.) so I don't know where to begin to look for a delete function to remove the text. Is there some good old fashioned delete text function, or do I have to use some other means of deleting the file from the widget? If anyone has anything to throw in there, (including a couple of lines of code, if that would be all it takes to do), I would appreciate it. Thanks for your time. Matt Robinson Meta Access, Inc. Santa Barbara, CA
argv@turnpike.Eng.Sun.COM (Dan Heller) (08/25/90)
In article <8301@ucrmath.ucr.edu> yakker@ucrmath.ucr.edu (matt robinson) writes: > Right now, I don't know of any widget to just get rid of the > source in the file (other than maybe XtTextReplace, but that > doesn't allow for a file specification; rather, a char *.) You should be posting this stuff to comp.windows.x.motif. Anwyay, you can delete the text in a widget using: XmTextSetString(text_widget, ""); If you want to replace the entire widget text completely, then use some other string besides "". -- dan ---------------------------------------------------- O'Reilly && Associates argv@sun.com / argv@ora.com Opinions expressed reflect those of the author only.