From: james t. <ti...@ma...> - 2005-06-22 18:59:21
|
ok, ...well, finally been up and running for the last week, so I just wanted to do some thinking out loud, and perhaps some group think will help... ...when we last talked about this in december, I had tracked down some "aggressive" re-drawing that Tk is doing in a particular example patch provided by mads linden: basically, when XMoveResizeWindow is called, it's invalidating everything that's a child subwindow, which is forcing an update of the all of the child subwindow clipping regions when the window is next drawn... ...a better way to do this would be to limit the area that is invalidated, or update just the clipping area that is being affected, and not the entire window and it's subwindows...that seems simple to say, but I'm a bit confused as to how to do this, based on how the code is now...for instance, should there be another function similar to TkMacOSXInvalClipRgns that somehow figures out just the area that needs to be invalidated, and then invalidates just those subwindows? Is this even possible given Tk's drawing model (ie. do we have that kind of information at hand when the decision is to be made)? ...also, I don't understand why this particular event is spawning calls to XMoveResizeWindow and not XMoveWindow, since there isn't any resizing of any of the windows involved? I realize that these functions are basically copies of each other code-wise, so it may be a no-issue...OTOH, in both there is a note that says "It is currently assumed that Tk will need to completely redraw anyway", so it seems likely this is a place to attack...? ...finally, I had shown jeff an "n-squared" problem with this invalidation/updating, but I've since found that that only occurs during the set-up/mapping of the windows: actual redrawing doesn't seem to be done "n-squared", but it is done for everything whether it was affect by the move or not... ...so I'm all over the place, and feedback is greatly appreciated! jamie |