Class

UIPencilInteraction

An interaction that tells your app the user double-tapped their Apple Pencil.

Declaration

@interface UIPencilInteraction : NSObject

Overview

The user can interact with Apple Pencil by double-tapping it. To detect the double tap in your app, create a UIPencilInteraction object and assign it a delegate object. Then add the interaction to your app’s view. When the user double-taps their Pencil, the interaction calls the delegate’s pencilInteractionDidTap: method.

Topics

Handling Interactions

delegate

The object that handles the double-tap interactions the user makes on their Apple Pencil.

UIPencilInteractionDelegate

The interface an object implements to handle double taps the user makes on their Apple Pencil.

Enabling Interactions

enabled

A Boolean value that specifies whether the system reports double taps on Apple Pencil to your app.

Determining User Preference

preferredTapAction

The user’s preferred double-tap action, as specified in the Settings app.

UIPencilPreferredAction

The preferred double-tap actions that a user can select from in the Settings app.

Relationships

Inherits From

Conforms To

See Also

Interactions

UIPencilInteractionDelegate

The interface an object implements to handle double taps the user makes on their Apple Pencil.