montnaro@spyder.crd.ge.com (Skip Montanaro) (01/05/91)
The ScrolledWindow widget is very handy, but I can't figure out how, if at all, you can scroll its contents under program control. I'd like to initialize the scrollbar position based upon mouse input the user gives in another window. It seems to be set up to only allow scrolling through user input to the scrollbars. Can anybody point me in the right direction? This is Motif 1.0.3 binary from ICS running under SunOS. Thanks, -- Skip (montanaro@crdgw1.ge.com)
steve@mnetor.UUCP (Steve Rees) (01/09/91)
The easiest way (IMHO) to do this is to:
1) Get the scrollbar widget id from the scrolled window.
2) Give the slider it's new value, via the XmNvalue (?) resource.
3) Give the scrollbar a whack in the side of the head with XtCallCallbacks();
this will make it recognize the new slider value, and do everything
you'd expect.
Good luck.
--
Steve Rees
{uunet|utzoo}!mnetor!steve or (better) steve%mnetor.uucp@uunet.uu.net
Ma Bell: +1 416 475 8980 ext. 322
Why isn't ping pong called pik pok?