<!--
{
  "availability" : [
    "iOS: 12.0.0 -",
    "iPadOS: 12.0.0 -",
    "macCatalyst: 13.1.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CarPlay",
  "identifier" : "/documentation/CarPlay/CPGridButton",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "CarPlay"
    ],
    "preciseIdentifier" : "c:objc(cs)CPGridButton"
  },
  "title" : "CPGridButton"
}
-->

# CPGridButton

A menu item button displayed on a grid template.

```
class CPGridButton
```

## Topics

### Creating a Grid Button

[`-  initWithTitleVariants:image:handler:`](/documentation/CarPlay/CPGridButton/init(titleVariants:image:handler:))

Creates a grid button with the specified title variants, image, and action handler.

### Controlling the Grid Button

[`enabled`](/documentation/CarPlay/CPGridButton/isEnabled)

A Boolean value that enables and disables the grid button.

### Obtaining Grid Button Information

[`titleVariants`](/documentation/CarPlay/CPGridButton/titleVariants)

An array of title variants for the button.

[`image`](/documentation/CarPlay/CPGridButton/image)

The image displayed on the button.

## Relationships

### Conforms To

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`CVarArg`](/documentation/Swift/CVarArg)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`NSCoding`](/documentation/Foundation/NSCoding)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`Equatable`](/documentation/Swift/Equatable)

[`NSSecureCoding`](/documentation/Foundation/NSSecureCoding)

[`Hashable`](/documentation/Swift/Hashable)

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

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)