Timeline widget
-
I want to implement "this":http://img146.imageshack.us/img146/856/timelinecontrol.png control. I've implemented the ruler widget, Do you think that a QGraphicScene is good for the graphical part? the items can be expandable, movable...
Thanks! -
forgot to add that I'll have a line over that control that will move horizontally over the control when I'll press a button. "This":http://img152.imageshack.us/img152/2108/finald.png is how the final widget should look,I've implemented the tree control too.
-
[quote author="Andre" date="1292426686"][quote author="peppe" date="1292425576"]No. Use a plain QWidget (+ subwidgets).[/quote]
Why?I think it could be done in either QML, GraphicsView or plain-old widgets. They all have their strongpoints.
[/quote]I simply think that plain, good ol' QWidgets are simply what he needs: they're easy to draw in a style-compliant manner, they're easy to lay out properly (especially in a "grid" like fashion, without any strange transformation applied), they work in integer coordinates, they're fast, they don't require too much memory nor any gpu acceleration to work properly, etc.
Of course, I'm not saying that it's an easy job -- such a complex widget will probably require a lot of time to be written and tested :)
-
OK, so I guess it depends on the actual needs of Sorin. Personally, I think that if I'd have to write such a widget at this moment, I would give creating a widget based on a QDeclarativeView and implemented with QML serious considderation. That can be combined with custom drawing bits that need that, such as the wave forms. I don't see too many items in this widget where style compliance is of key importance.
You name working with integers and not dealing with transformations a benefit, but I think it might be a drawback. If you have long timeline, zooming may be needed. Transformations are a real benefit to have available then, I think.
-
The problem is that you don't simply "zoom in" such widgets by transforming them. All the text and many other drawings must not be scaled when zooming in/out; the waveform and the ruler must change their level of detail while we zoom; we must guarrantee pixel exactness at each and every zoom factor; and so on. These things drive me to QWidget instead of QGraphicsView/QML.
I know that it's perfectly doable even with them, and all in all, it's up to what one feels more comfortable to deal with :)
That was my opinion and should be taken as such, and I don't want to make anyone change his/her mind :) -
Hi.
I am facing the same problem than some of you. Wondering what's the best approach in order to develop an advanced timeline component, with images, graphics, texts, etc, within it, with zoom in/out capabilities, custom background/colors, etc.Is there any sample code that i could use based on the discussion you had before in this thread? I assume is going to be some sort of mix of QTimeline, QSlider, QGraphics, and some other advanced graphics control usage.
hope you can help me and eventually, share some pieces of code.
thanks,
javier
-
I know what QTimeLine is and his purpose. I am just trying to build an advanced timeline control (Widget?) built with advanced graphical components (images, text, etc) and have the timeline itself move over that complex graphic (something like Movie Maker or Sony Vegas does with his timeline moving over photos and videos you add to the project).
this is the sony vegas timeline for example, with several "channels" for audio and video. the vertical bar is where the time is:
!http://jefa55.zapto.org/images/vegas timeline.JPG(vegas timeline)!