Function damage
pub fn damage(
previous: &Scene,
previous_parts: &SectionParts,
current: &Scene,
current_parts: &SectionParts,
) -> Result<Vec<Rect>, Unproven>Expand description
Damage, in section coordinates, between two frames of a section drawn
with parts: the old and new bounds of every part whose commands changed
(or what a hinted part’s hint says changed). Ok with no rects means
the section is unchanged.
When the parts nested inside some part differ between the frames (a menu that opened inside an overlay drew a part of its own), the parts down to the deepest nesting both frames still have alike are compared instead, each part at that depth as a whole: a window’s menu damages its window, a window a lane draws again damages that lane.