Path: utzoo!utgpu!watserv1!watmath!att!att!bu.edu!rpi!zaphod.mps.ohio-state.edu!van-bc!ubc-cs!uw-beaver!zephyr.ens.tek.com!tektronix!reed!chaffee From: chaffee@reed.UUCP (Alex Chaffee) Newsgroups: comp.sys.mac.programmer Subject: Re: Dialog boxes with Think Class Library Message-ID: <15649@reed.UUCP> Date: 4 Nov 90 01:50:11 GMT References: <1990Oct29.200612.28712@midway.uchicago.edu> Organization: Reed College, Portland OR Lines: 31 In <1990Oct29.200612.28712@midway.uchicago.edu> rtp1@quads.uchicago.edu (raymond thomas pierrehumbert) writes: > In short: How do I do modal dialog boxes with the Think Class >Library? Please reply via email, as I don't keep up with this >conference. I will summarize to the net if there is interest. Since modal dialogs have their own event handler (the dialog manager, through ModalDialog()), and are, after all, modal, they don't really fit in the philosophy or heirarchy of the TCL (panes and switchboards and all that). You should just write dialog boxes the way you always have, as a normal C function - or as a class if you like, but one outside the TCL. I'm considering converting my library for dealing with dialogs into a class. If I ever get around to it, I'll post it. The idea would be: a dialog class has methods for initialization and standard event handling; you'd write a subclass which overrides an ItemHit method to take care of special cases - basically replacing the "switch (itemHit)" statement which follows ModalDialog(). But it seems a bit like overkill. BTW, there are some classes floating around the net that do modeless dialogs in the TCL. One actually makes a TCL window by reading a DLOG/DITL resource. >rtp1@midway.uchicago.edu - Alex -- Alex Chaffee chaffee@reed.{UUCP,BITNET} Reed College, Portland OR 97202 ____________________