View Single Post
Posts: 53 | Thanked: 90 times | Joined on Nov 2009 @ Manaus, Brazil
#4
Originally Posted by nux View Post
It seems that pannable area scrolling after initialize is not working if window is already visible.
One possibility is that scroll_to_child() only works reliably after the event loop has started. You might use gobject.timeout_add() (or gobject.idle_add()) to add the scrolling as an asynchronous event.

I attached a (working) example showing how to use gobject.timeout_add(). In the example the pannable area scrolls to a random button every 2 seconds.
Attached Files
File Type: txt test_scroll.txt (940 Bytes, 66 views)
__________________
Anderson Lizardo
 

The Following 2 Users Say Thank You to lizardo For This Useful Post: