Path: utzoo!attcan!uunet!husc6!bbn!uwmcsd1!uxc!tank!nucsrl!bob From: bob@eecs.nwu.edu (Bob Hablutzel) Newsgroups: comp.sys.mac.programmer Subject: Re: Hiliting inactive controls (statText in dialog) Message-ID: <10050017@eecs.nwu.edu> Date: 17 Sep 88 22:41:26 GMT References: <266@iconsys.UUCP> Organization: Northwestern U, Evanston IL, USA Lines: 18 > I have some editText fields in a dialog with statText labels. > Depending on where the information from the dialog is going > I may want some editText fields inactive. Thus I want to > do something to the labels to "dim" them, like inactive labels > of buttons. I tried GetDItem(), and then HiliteControl(), but > that just crashed me. Any ideas? The reason they crashed is that the editText items are textEdit items, not controls. There isn't a really clean way of "dimming" a text edit item that I know of, but you might want to play with this: Inactivate the item (using SetDItem and adding itemDisable to the item type), then set the paint mode to srcAnd and paint the view rectangle with a grey pattern. When the item is reactivated, grab the text edit handle (tricky, but not impossible), and refresh it. The real problem here should be getting the handle and refreshing - making these user items would be something worth looking into (especially for modeless dialogs...) Bob Hablutzel BOB@NUACC.ACNS.NWU.EDU