diff options
Diffstat (limited to 'src/quicktemplates2/qquickslider.cpp')
-rw-r--r-- | src/quicktemplates2/qquickslider.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/src/quicktemplates2/qquickslider.cpp b/src/quicktemplates2/qquickslider.cpp index d01f26b9..e0df7e69 100644 --- a/src/quicktemplates2/qquickslider.cpp +++ b/src/quicktemplates2/qquickslider.cpp @@ -54,21 +54,24 @@ QT_BEGIN_NAMESPACE Slider is used to select a value by sliding a handle along a track. - \table - \row \li \image qtquickcontrols2-slider-normal.png - \li A slider in its normal state. - \row \li \image qtquickcontrols2-slider-focused.png - \li A slider that has active focus. - \row \li \image qtquickcontrols2-slider-disabled.png - \li A slider that is disabled. - \endtable + In the example below, custom \l from, \l value, and \l to values are set: \code Slider { - value: 0.5 + from: 1 + value: 25 + to: 100 } \endcode + The \l position property is defined as a percentage of the control's size, + scaled within the range \c {0.0 - 1.0}. The \l visualPosition property is + the same, except that it is reversed in a + \l {Right-to-left User Interfaces}{right-to-left} application. The + visualPosition is useful for positioning the handle when styling Slider. + In the example above, \l visualPosition will be \c 0.24 in a left-to-right + application, and \c 0.76 in a right-to-left application. + \sa {Customizing Slider}, {Input Controls} */ |