[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: hilighting
- To: info-mcl@cambridge.apple.com
- Subject: Re: hilighting
- From: lynch@ils.nwu.edu
- Date: Tue, 2 Mar 93 08:55:09 CST
- Cc: mcdougal@cs.uchicago.edu (Tom McDougal)
>I'm trying to figure out how to hilight an object using the hilite
>mode described in IM V, 61-62. It says:
>
>"There are two ways to use hilite mode. The easiest is to call
>
> BitClr (Ptr(HiliteMode,pHiliteBit))
>
>just before calling InvertRect..."
>
>On the next page it says:
>
>"The constants used with hilite mode are listed below:
>
> CONST
> hilite = 50;
> pHiliteBit = 0;"
>
>
>Well, I couldn't figure this out, so I searched files for "hilite" and
>found this example, in MCL:library:Inspector
>Folder:inspector-window.lisp:
>
>; Invert a region using the highlight color (see Inside Mac V-62).
>(defun %invert-region (rgn)
> (with-macptrs ((hiliteMode (%int-to-ptr #x938)))
> (%put-byte hiliteMode (logand #x7f (%get-byte hiliteMode))))
> (#_InvertRgn :ptr rgn))
>
>
>The connection between this code and what IM-V says could use some
>hilighting!