<!--
{
  "availability" : [
    "macCatalyst: -",
    "macOS: 10.0.0 - 10.9.0"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSPrinter/rectForKey:inTable:",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSPrinter(im)rectForKey:inTable:"
  },
  "title" : "rectForKey:inTable:"
}
-->

# rectForKey:inTable:

Returns the rectangle associated with the specified key.

```
- (NSRect) rectForKey:(NSString *) key inTable:(NSString *) table;
```

## Parameters

`key`

The key whose value you want.

`table`

The name of a table from the printer’s PPD file.

## Return Value

The rectangle value. Returns `NSZeroRect` if the key is not in the table or the receiver lacks a PPD file.

---

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)