CLIM mail archive


Re: ScrollBar Control

  Date:     Thu, 3 Mar 94 20:15:52 EST
  From: Nichael Cramer <ncramer@BBN.COM>


  A question about scroll-bar behavior (I'm using the standard Motif
  scroll-bars, not the home-grown ones):

  The current behavior for "dragging the elevator" is that the image in the
  window is also "dragged", that is the scroll-position of the window keeps
  up with the position of the elevator.

  The previous behavior (i.e. in previous releases of CLIM) was that you
  dragged the elevator and then scrolling only occured once when you released
  the elevator (that is the call-back only occured when the button was

  Question:  Is there some way of specifying that the Motif scroll-bars
  work in the second, "only scroll once" manner?

  If there is not, as a work-around, since I am already handling the
  call-back from the scroll-bars myself, is there some way I can query the
  scroll-bar to see if it's in a pointer-button-down state when I receive a
  scrolling call-back ?

  (In the worse case I can try to query the pointer-state directly when I
  receive the call-back.  However this presupposes I receive a final
  call-back when the pointer-button is released.  Does this happen?)

Unfortunately the scroll-bars in ACL CLIM 2.0 don't use the drag-callback
and value-changed-callback slots defined for the scroll bar gadgets.
Instead the method SCROLL-BAR-VALUE-CHANGED-CALLBACK is always called. In
previous releases, as you pointed out, this was only called when the slug
was released. However, in the latest version it is indeed called during
drag operations.

The eventual aim will be to use the drag-callback and value-changed-callback
slots defined for the scroll bar class. In the meantime, I'm afraid there
is no way of distinguishing in the call to SCROLL-BAR-VALUE-CHANGED-CALLBACK

If you want I can send you a patch that will revert to the old behaviour.

Colin Meldrum, Franz Inc.	1995 University Avenue, Suite 275         
colin@Franz.COM (internet)	Berkeley, CA 94704                       
uunet!franz!colin (uucp)	Phone: (510) 548-3600; FAX: (510) 548-8253

Main Index | Thread Index