Implementing QSlider with two sliders
-
I want to implement QSlider with two slider on it. Here is my scenario:
I need to implement a 24 hour representation on a slider control. User would be allowed to move either of the sliders to any position on the bar. I'll take values of slider position as user selection. QSlider only provides me one slider on it. any idea on how to do it?
Regards
-
Check out Qxt's "QxtSpanSlider":http://libqxt.bitbucket.org/doc/tip/qxtspanslider.html.
Hope this help ;o)
-
Thanks for your reply. How can I integrate QxtSpanSlider into my existing QT project. It is not one of the standard QT modules.
Regards,
-
You will have to build and install it (as per the "user guide":http://dev.libqxt.org/libqxt/wiki/user_guide) and then include Qxt in your .pro file (also detailed in the user guide).
Alternatively, you can have a look at the source, see how they did and implement your own version.
Hope this helps ;o)
-
Thanks for your answer. Is there any control available directly in QT?
-
Hi,
If you mean a "double edge" slider available in Qt ? No, but as jazzycamel wrote, you can use Qxt which is easy to integrate to a project.