On Monday 01 November 2004 14:19, Chris Cannam wrote:
> 
> How about something like the following?  (All the numbers would
> obviously be fungible, they're just there for local colour.)
>
>  - When the mouse button is pressed, make a note of where the pointer is
>    and then start a timer which fires every 20ms.
>  - When the mouse button is released, stop the timer.
>  - Each time the timer fires, see where the pointer's got to.  Then, for
>    each of the four sides of the canvas viewport:
>     - if the pointer is nearer to that side of the viewport than 1/10th
>       of the distance it was when the button was pressed, scroll in the
>       direction of that side of the viewport by a number of pixels N,
>       where N starts at 1 and multiplies by 1.1 each time the scroll
>       happens on a timer callback.
>     - if the pointer is not nearer to that edge than 1/10 of the
>       distance it was when the button was pressed, reset N to 1 and stop
>       scrolling.
>
> Note this would mean separate N for each of the four sides of the canvas
> viewport.

I've committed something along these lines, based on the QScrollView's drag 
autoscroll (although the numbers need fiddling with).

> What do you think, Guillaume -- implementable?  Ideally we would still
> be using page-type scrolling for the normal scrolling during playback,
> as we were until your last set of changes this weekend.

Agreed. Another thing is that what I've committed won't work for the case when 
scrolling occurs while dragging the playback pointer, I'll have to think of 
something for this one.

-- 
                                                Guillaume.
                                                http://www.telegraph-road.org


-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
_______________________________________________
Rosegarden-devel mailing list
[EMAIL PROTECTED] - use the link below to unsubscribe
https://lists.sourceforge.net/lists/listinfo/rosegarden-devel

Reply via email to