Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!wuarchive!uunet!mstan!chuck From: chuck@Morgan.COM (Chuck Ocheret) Newsgroups: comp.windows.x Subject: Re: how can I put a digital clock in the title bar? Message-ID: <3212@s5.Morgan.COM> Date: 6 May 91 16:33:36 GMT References: <1991Apr25.010422.7232@porthos.cc.bellcore.com> <9104261804.AA10540@dwight.tcs.com> Organization: Morgan Stanley, & Co., Inc. / New York City, NY Lines: 22 > If you are using Xt, somewhere you will have made an applicationShell, > and you could add the code below to your program. It "ticks" every > second... > > ... > > XStoreName(XtDisplay(shell), XtWindow(shell), buf); > ... Also note that if you are using Xt, your shell is probably a subclass of WMShell so you would be better off using the XtNtitle resource instead of calling XStoreName(). XtSetValues() incurs more client CPU overhead but keeps the shell up to date locally. WMShell provides many of the window manager goodies like XtN(min|max)(Width|Height), XtN(width|height)Inc, XtNbase(Width|Height), etc.... ~chuck -- +--------------------+ Chuck Ocheret +---------------+ |chuck@fid.Morgan.COM| Morgan Stanley & Co., Inc. |(212) 703-4474 | | Duty now ... |19th Floor, 1251 Avenue of the Americas|for the future.| +--------------------+ New York, N.Y. 10020 USA +---------------+