Path: utzoo!utgpu!watserv1!watmath!att!rutgers!psuvax1!xavier!jackiw From: jackiw@cs.swarthmore.edu (Nick Jackiw) Newsgroups: comp.sys.mac.programmer Subject: Re: Hiding editable text Message-ID: Date: 11 Jul 90 16:48:30 GMT References: <25533@cs.yale.edu> Sender: news@xavier.swarthmore.edu (Usenet News) Reply-To: jackiw@cs.swarthmore.edu (Nick Jackiw) Organization: Visual Geometry Project, Swarthmore College, PA Lines: 31 tarr-michael@CS.Yale.EDU (michael tarr) writes: > > I have a modal dialog box with some radio buttons and associated > editable text fields. When a button is clicked I want the appropriate > text field to appear, when its opponent is clicked I wish the field to > disappear and become uneditable (not just hidden as in drawing over > it)... > > Mike Tarr As of Inside Mac IV, the Dialog Manager accepts two toolbox calls, HideDItem(theDialog:DialogPtr; itemNo:integer); ShowDItem(theDialog:DialogPtr; itemNo:integer); which remove and display dialog items, respectively. EditText items are handled properly (i. e. deactivated if active, and no longer accessible by the tab key). If you need to create a DITL in which an item is by default hidden, you can either make the DLOG initially invisible and HideDItem after GetNewDialog and before ShowWindow, or you can add 16384 to its regular left and right coordinates in the DITL itself. -- ------------------------ Nick Jackiw jackiw@cs.swarthmore.edu "Every minute of the future Visual Geometry Project jackiw@swarthmr.bitnet is a memory of the past." Swarthmore College, PA 19081-1397 -Laivach