<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSLevelIndicator/numberOfMajorTickMarks",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSLevelIndicator(py)numberOfMajorTickMarks"
  },
  "title" : "numberOfMajorTickMarks"
}
-->

# numberOfMajorTickMarks

The number of major tick marks associated with the receiver.

```
var numberOfMajorTickMarks: Int { get set }
```

## Discussion

The number of major tick marks must be less than or equal to the number of tick marks returned by [`numberOfTickMarks`](/documentation/AppKit/NSLevelIndicator/numberOfTickMarks). For example, if the number of tick marks is 11 and you specify 3 major tick marks, the resulting level indicator will display 3 major tick marks alternating with 8 minor tick marks, as in the example shown in [`NSLevelIndicator`](/documentation/AppKit/NSLevelIndicator).

![Major and minor tick marks in a level indicator](images/com.apple.appkit/media-1965752.gif)

---

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)