kicad-developers team mailing list archive
Mailing list archive
Re: redraw on erase track segment
Dick Hollenbeck <dick@...>
Wed, 05 Mar 2008 11:13:25 -0600
Thunderbird 22.214.171.124 (X11/20080227)
I tested the new code about delete track segment on a very large board
(8 layers, 4000 pads 1350 vias...)
It is reasonably fast on my PC ( a low cost computer which is 4 years old).
An enhancement could be to redraw only the region modified in order to
reduce the flicker (all kicad draw functions already use a clip box).
If we can do this inside of the event loop then I think this is a good
idea. If you are talking about doing it "in line" and not in the event
loop, then I don't think this is a good idea. (The MAC boys have
complained about unnecessary stuff happening outside the event loop.)
Normally when the event loop dispatches to the application it can pass
the dirty rectangle and this is what I think would be an improvement,
but only if Kicad can handle it there.
Looking at *void* wxWindow::*Refresh*(*bool*/ eraseBackground = true/,
*const wxRect <cid:part1.04050801.07080900@...>* */rect = NULL/)
we see that it takes a "dirty" rectangle, a subset of the window to
repaint or to mark as dirty. And this would be consistent with working
with the event loop properly.
Can Kicad receive this dirty rectangle in its event dispatcher and pay
attention to it? If yes, then great, if not...... well we could add
the dirty rect to the call, and later pay attention to the rectangle.
Please let me know and if there is an example, please point me to it and
I will be happy to add this support to my patch.