After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 336348 - [Advanced Timeline] Zoom should be possible with scroll wheel
[Advanced Timeline] Zoom should be possible with scroll wheel
Status: RESOLVED FIXED
Product: pitivi
Classification: Other
Component: User interface
Git
Other Linux
: Normal normal
: 0.13.1
Assigned To: Brandon Lewis
Pitivi maintainers
Depends on:
Blocks: 337894
 
 
Reported: 2006-03-28 14:28 UTC by Andy Wingo
Modified: 2009-03-02 23:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
scroll event patch (1.41 KB, patch)
2007-04-10 13:09 UTC, kris.fn
none Details | Review

Description Andy Wingo 2006-03-28 14:28:38 UTC
Two things:

1) scroll-wheeling over the ruler should zoom in and out
2) holding down some modifier while scrollwheeling over the timeline should do the same
Comment 1 Andy Wingo 2006-03-28 14:38:28 UTC
Here's another possibility: Make the tracks shorter, and remove the vertical scrollbar. Force all tracks to be visible. This shouldn't be that big of a deal -- I expect 8 tracks would be the maximum one would want to work with with pitivi, and if they were sufficiently short (32 px maybe), 8x32 = 256 pixels, not too much to deal with (depending on your screen size of course).

The relation to this bug would be at that point you could use the scroll wheel purely for zooming and panning the timeline (one would have a modifier of course), and you don't have to worry about hidden tracks.
Comment 2 Edward Hervey 2006-03-28 14:50:38 UTC
I agree on making them shorter, right now they're really too thick.
But as to make them all visible, it might be tricky, since :
_ I don't want to limit the number of output tracks (although 8 should be enough)
_ Those tracks may contain many layers (for the effects and sources) which will eventually increase their thickness
Comment 3 Andy Wingo 2006-03-28 15:08:34 UTC
A possibility would be that when you are looking at one particular piece of the timeline it makes the others slightly smaller. Not sure. Although there is a cost to making all of them visible there are definite benefits as well. Also when making a UI you have a good idea of how many of a particular object will be visible at once, and that understanding influences your decisions re: the various tradeoffs. Something to think about.
Comment 4 Chris Van Patten 2006-08-17 21:10:57 UTC
Don't remove the vertical scrollbar.  Professional productions might have tons of tracks and they'll want to easily be able to get to them all, especially if they don't have a high screen resolution.
Comment 5 Andy Wingo 2006-08-21 09:10:35 UTC
(In reply to comment #4)

I can see the need if you have >N tracks, where N is about 4 or 8, but with smaller numbers of tracks no scrollbar should be required.
Comment 6 Edward Hervey 2006-08-21 09:24:07 UTC
The best is to simulate the 'automatic' visibility behaviour of scrollbars in scrolled windows. If there's under N bars then force the widget to allocate more space vertically, if there's more than N bars, then show scrollbar.
Comment 7 kris.fn 2007-04-10 13:09:59 UTC
Created attachment 86105 [details] [review]
scroll event patch

Hi, here is a patch to make the zoom work with the scroll wheel over the ruler, I hope it is done in the right way. The patch also change the "drawPosition" def from a red line to a black triangle, i saw that it was temporary so this is just a try, keep it if you like it more.
Comment 8 Edward Hervey 2007-04-17 09:17:51 UTC
Adjusting title
Comment 9 Jean-François Fortin Tam 2009-02-10 01:59:50 UTC
Well, tried looking at the patch, and I don't think it is relevant to pitivi git master. Maybe Kris could try updating it? In any case, +1, killer feature that I use all the time. Actually, I would like that (de)zoom-on-scroll to apply to the entire timeline zone, not just the timeline ruler: the ruler, the clips, the area in general. 

Scrolling is useless when you can use zooming as a much faster scrolling mechanism (from experience). Zooming in/out rapidly to the position of the mouse cursor is equivalent to moving through the timeline with scrolling, so it kills two birds with one stone.
Comment 10 Jean-François Fortin Tam 2009-02-10 02:36:54 UTC
By "not relevant", I mean that I tried applying it to git master, and a bunch of functions changed/disappeared so it doesn't work.
Comment 11 Brandon Lewis 2009-02-19 01:23:04 UTC
i'm not sure i need a patch to do this anyways, though I appreciate the effort. The question is do we really want the scroll wheel to do zooming or seeking, or something else?
Comment 12 Jean-François Fortin Tam 2009-02-19 12:07:42 UTC
My 2¢ is that zooming is much more useful for quickly going in and out from high precision editing to "global bird eye's view" in a split second, and that it also replicates (to some extent) the functionality of scrolling.

Scrolling and seeking can also be done by other means (dragging the scrollbars, which is a fast operation; dragging the timeline playhead, which is a fast operation; using the keyboard shortcuts to seek).
Comment 13 Brandon Lewis 2009-02-26 21:39:29 UTC
In master moving mousewheel over ruler zoom the timeline. Otherwise it works as before.
Comment 14 Jean-François Fortin Tam 2009-02-27 13:25:46 UTC
Not entirely fixed, please reopen. Zooming indeed works by scrolling over the timeline ruler, but not as expected. The zooming should be centered around the position of the cursor over the timeline. Currently, it zooms according to the beginning of the timeline, making me lose focus of where my clip (which I wanted to zoom "into") is.

So, if my mouse is at 34 seconds in the timeline and I zoom in/out, the 34 seconds mark should stay under the cursor at all times.
Comment 15 Brandon Lewis 2009-03-01 04:34:11 UTC
It took the better part of the last two days to figure out what the heck was going on, but I finally got this to work. Enjoy.
Comment 16 Jean-François Fortin Tam 2009-03-02 23:03:35 UTC
It "almost" works perfectly, except one thing: the centering around the playhead doesn't always work.

Take a look at http://jeff.ecchi.ca/public/bug-pitivi-336348-playhead-zoom-centering.ogv

In that video, it does great when you are zoomed further in, but for the first 3 zoom levels, it breaks. For the 1st zoom level, it would be "understandable" since the timeline isn't wide enough to warrant recentering around the playhead, but the next 2 zoom levels are, and they are not recentered as I would expect.

Basically, make sure that centering is kept at all times unless the timeline is zoomed out so much that it's not long enough to be wider than the window.