Path: utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!clyde.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!apple!usc!wuarchive!cs.utexas.edu!asuvax!stjhmc!p88.f15.n300.z1.fidonet.org!Lawson.English From: Lawson.English@p88.f15.n300.z1.fidonet.org (Lawson English) Newsgroups: comp.sys.mac.programmer Subject: Re: Advice on icon animation wanted Message-ID: <33018.27737F46@stjhmc.fidonet.org> Date: 22 Dec 90 15:20:10 GMT Sender: ufgate@stjhmc.fidonet.org (newsout1.26) Organization: FidoNet node 1:300/15.88 - Tucson Apple Core, Tucson AZ Lines: 46 Vasile R. Montan writes in a message to All VRM> I tried this, and it didn't seem to work. I couldn't get the VRM> transfer mode to affect PlotIcon at all, which was why I wondered VRM> if there might not be some special considerations From TechNote #055, Drawing Icons, by Jim Friedlander: "[create two bit maps, one for the icon (iBitMap), one for the mask (mBitMap)] Drawing icons as non-open is basically the same for online and offline volumes. We need to punch a hole in the desktop for the icon. This is analogous to punching a hole in dough with an irrecular shaped cookie-cutter. We can then sprinkle jimmies* all over hte cookie and they will only stick in the area that we punced out (the mask). We do this by copyBitsing the mask onto the desktop (whatever pattern) to our destRect. For non-open, non-selelcted icons, we use the SrcBic mode so we that we punch a white hole: SetRect(destRect,left,top,left+32,top+32); CopyBits(mBitMap, thePort^.portBits, icnRect,destRect,SrcXor,NIL); Then we XOR in the icon: CopyBits(iBitMap, thePort^.portBits,iconRect,destRect,SrcXor, Nil); That's all there is to drawing a icon as non-open, non-selected." [...] "*Jimmies: little bits of chocolate" I trust that this will help? Get ahold of the TechNotes stack, it is well worth your while... Lawson -- Uucp: ...{gatech,ames,rutgers}!ncar!asuvax!stjhmc!300!15.88!Lawson.English Internet: Lawson.English@p88.f15.n300.z1.fidonet.org