D7: paintbox in scrollbox
Posted on 2010-01-04
A paintbox in a scrollbox does not paint correctly, when the scrollbars are used. The objects replaced, may be partly repainted at different locations on the track they were replaced along (kind of shadowy). Especially when they move out of sight in the scrollbox (and paintbox).
Setting the scrollbars of the scrollbox to smooth does help for it shows from the immediate moment the visuals are moved, whether they will be painted correctly at their new locations. Now, I noticed that the vertical scrollbar set to smooth does work, but the horizontal one does not when it should. Then I thought maybe this is related to the main problem of painting.
I think it must be primarily related to the fact that paintboxes calculate from the top left and therefore do not allow positioning objects above and to the left, even though relatively speaking the objects should be in the correct domain even when scrolled out of sight.
Another idea is that repainting should not start from the moment the scrollbars are moved but only after their moving (using the mouse) has stopped. I would need an 'on stopscrolling' method but for some reason scrollboxes do not have 'on scroll' methods. This I cannot understand.