<!--
{
  "availability" : [
    "macOS: 10.10.3 -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSPressureConfiguration/set()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSPressureConfiguration(im)set"
  },
  "title" : "set()"
}
-->

# set()

Changes the pressure configuration of the trackpad to the initialized pressure configuration.

```
func set()
```

## Discussion

During a mouse drag or pressure event sequence, this method may be called to change the pressure configuration of the trackpad to the initialized pressure configuration. The trackpad’s pressure configuration is automatically reset when the user releases the mouse or ends the gesture. If called outside of a mouse drag or pressure event sequence, this method has no effect on the trackpad.

Ideally, pressure behavior should be configured by adjusting the `pressureConfiguration` property of a view prior to a mouse drag or gesture event occurring, such as before the view is displayed. Otherwise, the user may complete the mouse drag or gesture before the configuration has time to take effect.

## See Also

[`NSView`](/documentation/AppKit/NSView)

The infrastructure for drawing, printing, and handling events in an app.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)