http://gambaswiki.org/bugtracker/edit?object=BUG.765&from=L21haW4-
Comment #14 by BenoƮt MINISINI: I did a cache. That said, I said nothing as when you want to speed up things, you always make a cache... It was slow because the contents was rich text redrawn at each frame. And drawing rich text is very very slow. So I created three images (the cache). Each image has the height of the drawing area, and is filled with successive parts of the contents. When scrolling, the two first images are used for drawing the contents. When the scroll reaches the end of the second image, the third image is filled with the next part of the contents, and the images are rotates (the second image becomes the first, the third becomes the second, and the first becomes the last). That way, for one cycle of scrolling, the contents is drawn once, and not many times. The contents is based on a GridView, and is picked up by an hack, i.e. calling the hidden drawing event handler of the control. Thanks to the Paint class that does not care with its target device. If it's not clear, read the source code. ------------------------------------------------------------------------------ _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user