---
title: "init(identifier:drawingHandler:)"
framework: appkit
role: symbol
role_heading: Initializer
path: "appkit/nssteppertouchbaritem/init(identifier:drawinghandler:)"
---

# init(identifier:drawingHandler:)

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

## Declaration

```swift
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.

## See Also

### Creating a stepper item

- [init(identifier:formatter:)](appkit/nssteppertouchbaritem/init(identifier:formatter:).md)
