Newsgroups: comp.windows.x Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!umich!csmil.umich.edu!fribourg.csmil.umich.edu!chymes From: chymes@fribourg.csmil.umich.edu (Charles Hymes) Subject: Please help me fix a Athena text widget. Message-ID: <1990May25.211934.25556@csmil.umich.edu> Sender: news@csmil.umich.edu Organization: Cognitive Science and Machine Intelligence Laboratory Date: Fri, 25 May 90 21:19:34 GMT I h ave been trying to figure this out for days, without sucess. I have a program that was written for X11R3 and used the folloing code: ForceBuildLineTable(ipanel->text) where ipanel->text = XtCreateManagedWidget("IPANEL",asciiStringWidgetClass, box, a, XtNumber(a)); I am trying to replace the X11R3 function ForceBuildLineTable with the X11R4 function _XawBuildLineTable. _XawBuildLineTable takes the arguments _XawTextBuildLineTable (ctx, position, force_rebuild) TextWidget ctx; XawTextPosition position; /* top. */ Boolean force_rebuild; The code for old ForceBuildLineTable() in ites entirety is void ForceBuildLineTable(ctx) TextWidget ctx; { XtTextPosition position; position = ctx->text.lt.top; ctx->text.lt.top++; /* ugly, but it works */ BuildLineTable(ctx, position); } So, to use the new function, I have to provide the parameter position, and get it from the TextWidget ipanal->text. I have been unable to access the elements of TextWidget. Basicly, I cannot figure out what the elements of a TextWidget are, and can therefore only guess what my indirect references should be. I have tried : _XawTextBuildLineTable(ip->text, ip->text->lt.top, TRUE); But my compiler only snorts at me in contempt. Help!!!! Charles Hymes