info-mac@uw-beaver (12/13/84)
From: kato.SV@XEROX.ARPA There seems to be something I don't understand about TEUpdate (TECalc, et al). When I resize a window to be larger, I call TECalc to recalculate linestart. I call TEUpdate when I get an update event but I also put one after the SizeWindow. What I expected to happen was for the text to be re-formatted to the new larger window and the old text erased. The former happens but not the latter, unless you either put a window in front of the text window then take it away or hit a key. The old text then gets erased. What am I doing wrong? It seems to me that TEKey must be calling some routine to redraw the window. I'd like to call that instead of putting in the code that FILE.TEXT has to do the same thing. I'd also like to know if my understanding of InvalRect is correct. It seems to me that this tells QuickDraw that whatever is in this rectangle needs to be re-drawn. Any subsequent drawing in the rectangle is not drawn until an update event occurs. Does InvalRect erase the rectangle, then draw what has accumulated or is the stuff just drawn over what's there? (Super SIGH!) Kato.sv@Xerox.ARPA
info-mac@uw-beaver (12/18/84)
From: cornell!kevin@lasspvax.arpa (Kevin Saunders) [] Yes indeedy, you have got to erase that area yourself. I believe that the effect of InvalRect is only to add the Rect argument to the window's update region; thus, you can call InvalRect, get back an update event, and *then* you blank and redraw the text in your update routine. Also, I would avoid the TECalc routine: slow as mud. Cheerfully, another MacLobotomy case, Kevin Eric Saunders lasspvax.kevin@cornell.arpa