Tracks Digital Crown rotations by updating the specified binding.
SDKs
- watchOS 6.0+
- Xcode 11.0+
Framework
- Swift
UI
Declaration
func digitalCrownRotation<V>(_ binding: Binding<V>, from minValue: V, through maxValue: V, by stride: V.Stride? = nil, sensitivity: Digital Crown Rotational Sensitivity = .high, isContinuous: Bool = false, isHapticFeedbackEnabled: Bool = true) -> some View where V : Binary Floating Point, V.Stride : Binary Floating Point
Parameters
binding
A value that updates as the Digital Crown is rotated.
minValue
Lower end of the range reported.
maxValue
Upper end of the range reported.
stride
The value will settle on multiples of
stride
.sensitivity
How much the Digital Crown needs to be rotated to move between two integer numbers.
isContinuous
Controls if the value reported stops at
min
andValue max
or if it should wrap around. Default isValue false
.isHapticFeedbackEnabled
Controls the generation of haptic feedback when turning the Digital Crown. Default is
true
.