On Wed, 28 May 2008, imacarthur wrote:

>> Does something like this exist? If not, how do I go about modifying
>> the existing Fl_Roller wheel?
>
> I don't think anything quite like that exists, but I guess you can
> make something up pretty easy - the fltk valuators (e.g.
> Fl_Value_Input, Fl_Roller) all respond to mouse drag movement. I
> guess in a subclassed handle method you could just record the mouse X
> position on button-down, and pass the delta between current-X and
> that original-X to the callback? Something like that?

I guess I'd probably use the 'previous' x rather than the original, so
that any mouse movement to the left gives a negative value, and any 
movement to the right a positive value (even if the mouse cursor is on the 
left of the original click).

Sounds workable.

Thank you,
Marc

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to