12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- import QtQuick
- import QtQuick.Controls
- import QtQuick.Templates as T
- import QtQuick.NativeStyle as NativeStyle
- T.Slider {
- id: control
- implicitWidth: Math.max(implicitBackgroundWidth + leftInset + rightInset,
- implicitHandleWidth + leftPadding + rightPadding,
- control.horizontal ? 90 : 0 )
- implicitHeight: Math.max(implicitBackgroundHeight + topInset + bottomInset,
- implicitHandleHeight + topPadding + bottomPadding,
- control.vertical ? 90 : 0 )
- background: NativeStyle.Slider {
- control: control
- subControl: NativeStyle.Slider.Groove
-
-
-
-
-
- useNinePatchImage: false
- }
- handle: NativeStyle.Slider {
- control: control
- subControl: NativeStyle.Slider.Handle
- x: control.leftPadding + (control.horizontal ? control.visualPosition * (control.availableWidth - width) : (control.availableWidth - width) / 2)
- y: control.topPadding + (control.horizontal ? (control.availableHeight - height) / 2 : control.visualPosition * (control.availableHeight - height))
- useNinePatchImage: false
- }
- }
|