View Single Post
Posts: 875 | Thanked: 918 times | Joined on Sep 2010
#106
Originally Posted by Mitrandir View Post
But if we don't want to rotate buffer every time, the buffer will need to contain widgets in rotated form and all widget drawing operations need to be rotated individually while painting into the buffer. I think this might be slower...
Continue drawing to the normal mode buffer, but when the list is scrolled blit the already rotated window contents (area A) to the new position, update the normal mode buffer with the changes, extract the exposed area (area B), rotate it and copy into the window.

When the list is scrolled up the exposed area is at the bottom so area A is the bottom of the list minus the top portion that gets moved off screen and area B is the new contents at bottom of list.

That should improve scrolling speed since you are only drawing and rotating the newly exposed area. The rest is blitted from its already rotated form.