Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!zaphod.mps.ohio-state.edu!mips!sgi!shinobu!odin!sgihub!dragon!eukanuba.wpd.sgi.com!mikey From: mikey@eukanuba.wpd.sgi.com (Mike Yang) Newsgroups: comp.windows.x.motif Subject: Re: callbacks for text widget Keywords: text,callback,reason Message-ID: <1990Sep18.162031.10832@relay.wpd.sgi.com> Date: 18 Sep 90 16:20:31 GMT References: <14983@gouda.quad.com> <1990Sep16.004605.9095@relay.wpd.sgi.com> <829@auto-trol.UUCP> Sender: news@relay.wpd.sgi.com ( CNews Account ) Reply-To: mikey@sgi.com Organization: Silicon Graphics, Inc. Lines: 31 In article <829@auto-trol.UUCP>, marbru@auto-trol.UUCP (Martin Brunecky) writes: |> [ Plus, I am a firm believer that Xt was invented to RELIEF an |> application programmer from looking at X events. Thus, even though |> Motif blindly follows DECwindows in passing events to the callback, |> I don't ever use those. One of reasons of having a widget is |> to hide underlying X input system from an application. This, |> however, puts a little more responsibility on a widget writer, so |> that applications don't have to compensate for poor widget by |> knitting a whole net of workarounds based on X calls around it]. I agree with you. For the common case, the point of Xt and Motif is to hide the need for Xlib knowledge from the developer. However, it would be a big mistake to make the knowledge completely inaccessible and thus limit the ability of Xt/Motif programs. For instance, when dealing with ICCCM selections a timestamp is needed Since many of the Motif callbacks provide the event structure, this can be used for a timestamp for, say, owning the selection when a list box item is chosen. If the Motif callbacks didn't provide this extra information, I'd have to use something like CurrentTime, and in the ICCCM viewpoint, I would be a\ bad boy. So I'm thankful that although I don't often need the event field, it's usually there when I do need it. (I say "usually" because it's not there when a text selection is made -- Grrr.) ----------------------------------------------------------------------- Mike Yang Silicon Graphics, Inc. mikey@sgi.com 415/335-1786