On Fri, Mar 25, 2005 at 11:11:04AM -0600, Alexandre Julliard wrote:
Modified files: windows : scroll.c dlls/x11drv : scroll.c dlls/user/tests: win.c msg.c
Log message: Rein Klazes wijn@wanadoo.nl ScrollDC and X11DRV_SCROLLDC should scroll only pixels coming from within the visible region, clipped to the clipping region if that exists. Add the destination of pixels coming from the outside of this region to the update region. With tests that depend on this.
Unfortunately, this patch doesn't fix bug 1091: http://bugs.winehq.org/show_bug.cgi?id=1091
On Sun, 27 Mar 2005 11:34:12 -0500, you wrote:
On Fri, Mar 25, 2005 at 11:11:04AM -0600, Alexandre Julliard wrote:
Modified files: windows : scroll.c dlls/x11drv : scroll.c dlls/user/tests: win.c msg.c
Log message: Rein Klazes wijn@wanadoo.nl ScrollDC and X11DRV_SCROLLDC should scroll only pixels coming from within the visible region, clipped to the clipping region if that exists. Add the destination of pixels coming from the outside of this region to the update region. With tests that depend on this.
Unfortunately, this patch doesn't fix bug 1091: http://bugs.winehq.org/show_bug.cgi?id=1091
If I get this correctly, your bug#1091 has to do with scrolling a window that already has an invalidated region before the scroll. None of my patches would affect that (making your deduction more likely true).
Attached is a patch that solves Micha's scroll problem, also discussed under bug #1091. It also does not change the handling of an existing invalidated region.
Changelog:
windows : scroll.c dlls/user/tests : msg.c
ScrollWindow should call ScrollWindowEx with the SW_ERASE flag set. With conformance test.
Rein.
On Mon, Mar 28, 2005 at 02:14:44PM +0200, Rein Klazes wrote:
Attached is a patch that solves Micha's scroll problem, also discussed under bug #1091. It also does not change the handling of an existing invalidated region.
Nice, at least you nailed one :). As for the initial problem that I've reported (http://www.winehq.org/hypermail/wine-devel/2002/09/0748.html), you are correct, it's about interaction with the invalidated region. I've figured that while you have your hands wet in that code, maybe you can take a stab at it. Thanks for taking a look!
On Mon, 28 Mar 2005 07:54:12 -0500, you wrote:
As for the initial problem that I've reported (http://www.winehq.org/hypermail/wine-devel/2002/09/0748.html), you are correct, it's about interaction with the invalidated region. I've figured that while you have your hands wet in that code, maybe you can take a stab at it. Thanks for taking a look!
It is a little more complicated then the way you explain it.
First, if you do not move the window that obstructs the scrolling lists then there are no defects (use something else to cause the lists to scroll). Yet, some added tracing shows that ScrollWindowEx (creating invalidated regions) is called far more often then paintings (which validates those regions). So ScrollWindowEx will typically have to scroll invalidated regions of previous scrolls. And, as far as I can see, the code does this flawlessly.
But, if you move the window that obstructs the scrolling list around, then areas that where obstructed and get exposed must be invalidated. This happens when the exposure events are processed. Now you can imagine that the area that needs to be invalidated is different if it is processed before the scroll or after the scroll. Since there is no synchronization between exposure events and ScrollWindowEx calls, this explains why it must go wrong in some cases and we see the defects.
I've tried a few things but this is a problem that is beyond me, if it is solvable at all. Perhaps Alexandre can give a hint how this should be solved.
Rein.