<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.15.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSStepperTouchBarItem/init(identifier:drawingHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSStepperTouchBarItem(cm)stepperTouchBarItemWithIdentifier:drawingHandler:"
  },
  "title" : "init(identifier:drawingHandler:)"
}
-->

# init(identifier:drawingHandler:)

Creates a `NSStepperTouchBarItem` using the result of `drawingHandler` to display the stepper’s value as an image.

```
convenience init(identifier: NSTouchBarItem.Identifier, drawingHandler: @escaping (NSRect, Double) -> Void)
```

## Parameters

`drawingHandler`

A block that draws a graphical representation of the stepper’s value in the specified rectangle. The coordinates of this rectangle are specified in points.

---

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)