Path: utzoo!attcan!uunet!lll-winken!ames!apple!usc!bloom-beacon!EXPO.LCS.MIT.EDU!kit From: kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) Newsgroups: comp.windows.x Subject: Re: Getting a time stamp in Xt Message-ID: <8907051713.AA19380@expo.lcs.mit.edu> Date: 5 Jul 89 17:13:14 GMT References: <104@uc.msc.umn.edu> Sender: daemon@bloom-beacon.MIT.EDU Organization: The Internet Lines: 23 > Is there a cleaner way to get the time stamp? Here is one. Rather than using the callback proceedure for the widget define your own global action routine (see XtAppAddActions) and bind it to your widget via a translation. One of the parameters passed to an action routine is the event. Thus your application will have the event. One caution when using this method is that in configurable programs you may not be able to assume the type of event that activates the proceedure (The user can modify the translation table to suit his/her tastes). Be sure to check the "type" field in the event, so that you are getting the right structure element out of the Event's Union. Chris D. Peterson MIT X Consortium Net: kit@expo.lcs.mit.edu Phone: (617) 253 - 9608 Address: MIT - Room NE43-213