Generic Instance Method

digitalCrownRotation(_:from:through:by:sensitivity:isContinuous:isHapticFeedbackEnabled:)

Tracks Digital Crown rotations by updating the given binding.

Declaration

func digitalCrownRotation<V>(_ binding: Binding<V>, from minValue: V, through maxValue: V, by stride: V.Stride? = nil, sensitivity: DigitalCrownRotationalSensitivity = .high, isContinuous: Bool = false, isHapticFeedbackEnabled: Bool = true) -> some View where V : BinaryFloatingPoint, V.Stride : BinaryFloatingPoint

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 minValue and maxValue or if it should wrap around. Default is false.

isHapticFeedbackEnabled

Controls the generation of haptic feedback when turning the Digital Crown. Default is true.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software