freenode/#clim - IRC Chatlog
Search
8:34:36
loke
jackdaniel: OK, I've been looking at the CLIm code now. Turns out that scrolling is done in the SCROLL-EXTENT function (in panes.lisp). It basically just calls MOVE-SHEET. The MOVE-SHEET method (in sheets.lisp) sets the sheet transformation using (SETF (SHEET-TRANSFORMATION ...) ...).
8:38:23
loke
There is an :AROUND method on this SETF function, which calls DISPATCH-REPAINT when the sheet is viewable.
8:39:16
loke
The DISPATCH-REPAINT is passed a single region, which is a union of the SHEET-REGION and the OLD-REGION (why they do that, I have no idea. Shouldn't it be enough to just include the new region?)
8:40:16
loke
Anyway, the magic should happen around there somewhere there I guess? (we're talking about the (SETF SHEET-TRANSFORMATION) in sheets.lisp line 228.
10:05:56
jackdaniel
loke: if you want to blit image, you need to know what region has been drawn before
10:06:22
jackdaniel
so old-region may be used to do exactly that (part of it needs to be repainted anyway, but intersection is there in the buffer)
10:08:58
loke
Right, but the methid doesn't know how the transformation has happened. All it gets is a single region which should be redrawn
10:09:35
loke
By the time the redraw metssage is received, there is no inforamtion as to what triggered the redraw.
10:13:13
loke
If I display a presentation, but I want some horizontal spacing to the left of it... What is the proper way to achieve this?
12:46:34
loke
jackdaniel: That's unfortunately not enough, since you need to know the exact scrolling location before and after the event, and the redraw only gives you the latter. Also note that the _same_ redraw event is sent whenever any kind of redraw is needed, not just scrolling.