Newsgroups: comp.windows.x Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!think.com!snorkelwacker.mit.edu!bloom-beacon!dont-send-mail-to-path-lines From: converse@expo.lcs.mit.EDU (Donna Converse) Subject: Re: Dialog Translations Message-ID: <9104291917.AA01628@excess.lcs.mit.edu> Sender: daemon@athena.mit.edu (Mr Background) Organization: X Consortium, MIT Laboratory for Computer Science References: <1991Apr29.173747.29152@colorado.edu> Date: 29 Apr 91 19:17:26 GMT Lines: 28 > Guys, ??? > I have an action I want to bind to a dialog widget, I have the translation > declared as: > > (A) static String trans = > "Return: testcall()\n"; > > and the action declared as: > > XtActionsRec actionTable[] = { > {"test", test}, > }; Should be {"testcall", test}, Think about it. > > After my calls to ( par_tr_tab = XtParseTranslationTable(trans)) and > XtOverrideTranslations(mydialogbox, par_tr_tab), I add the action > with XtAddACtions(actionTable, XtNumber(actionTable)); Add the actions to the application context (XtAddActions or XtAppAddActions) before you install the translations (XtOverrideTranslations).