<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSPrinter/init(type:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSPrinter(cm)printerWithType:"
  },
  "title" : "init(type:)"
}
-->

# init(type:)

Creates and returns a printer object initialized to the first available printer with the specified make and model information.

```
init?(type: NSPrinter.TypeName)
```

## Parameters

`type`

A string describing the make and model information. You can get this string using the [`printerTypes`](/documentation/AppKit/NSPrinter/printerTypes) method.

## Return Value

An initialized `NSPrinter` object, or `nil` if the specified printer was not available.

## See Also

[`type`](/documentation/AppKit/NSPrinter/type)

A description of the printer’s make and model.



---

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)