Damage extension reports backing store damage against the wrong window
Submitted by Keith Kriewall
Assigned to Adam Jackson @ajax
Description
Drawing to a window's backing store is reported as damage against the obscuring window, not the window actually drawn upon.
For example, given a window heirarchy as follows...
Parent and Child_1 (same size):
| | | Child_2: Child_1a: | | ---------- ---------- | | | | | | | | | | | | | | | | | | | | | | | | | | ---------- ---------- | | |
Parent: @(0,0) for [30,11] Child_1: @(0,0) for [30,11], BackingStore=WhenMapped Child_2 (a sibling of Child_1): @(3,3) for [10,6] Child_1a (an inferior of Child_1): @(17,3) for [10,6]
... create and map the windows; create DAMAGE level=RawRectangles for Child_1, Child_2, and Child_1a; create a GC with SubwindowMode=ClipByChildren; then draw a zero-width line drawn on Child_1 from (0,5) through (29,5).
Expected result: DamageNotify on Child_1 @(0,5) for [30,1]
Actual result: DamageNotify on Child_2 @(0,2) for [10,1] DamageNotify on Child_1a @(0,2) for [10,1] DamageNotify on Child_1 @(0,5) for [3,1] DamageNotify on Child_1 @(13,5) for [17,1]
The damage reported on child_1a and child_2 is unexpected because the drawing has not affected either of these windows.
Tested on X.Org servers version 6.8.2 (Damage v1.0) and 1.3.0 (Damage v1.1). Possibly related to bug 3785, but probably not.
Version: 7.3 (2007.09)