---
title: NSTouch
framework: appkit
role: symbol
role_heading: Class
path: appkit/nstouch
---

# NSTouch

A snapshot of a particular touch at an instant in time.

## Declaration

```swift
class NSTouch
```

## Overview

Overview A touch event is not persistent throughout the touch. A touch creates new instances as it progresses. Use the identity property to follow a specific touch across its lifetime. Touches do not have a corresponding screen location. The first touch of a touch collection latches to the view underlying the cursor using the same hit detection as mouse events. Additional touches on the same device latch to the same view. Latches remain on views until the user ends a touch or an event cancels it.

## Topics

### Getting the Touch Type

- [type](appkit/nstouch/type.md)
- [NSTouch.TouchType](appkit/nstouch/touchtype.md)
- [NSTouch.TouchTypeMask](appkit/nstouch/touchtypemask.md)

### Using Touch Properties

- [identity](appkit/nstouch/identity.md)
- [phase](appkit/nstouch/phase-swift.property.md)
- [NSTouch.Phase](appkit/nstouch/phase-swift.struct.md)
- [normalizedPosition](appkit/nstouch/normalizedposition.md)
- [isResting](appkit/nstouch/isresting.md)

### Using Touch Device Properties

- [device](appkit/nstouch/device.md)
- [deviceSize](appkit/nstouch/devicesize.md)

### Getting the Touch Location

- [location(in:)](appkit/nstouch/location(in:).md)
- [previousLocation(in:)](appkit/nstouch/previouslocation(in:).md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSCopying](foundation/nscopying.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Mouse, Keyboard, and Touch Events

- [NSEvent](appkit/nsevent.md)
