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

# drawKnob()

Draws the knob.

```
func drawKnob()
```

## Discussion

You should never need to invoke this method directly, but may wish to override it to customize the appearance of the knob.

## See Also

[`func rect(for: NSScroller.Part) -> NSRect`](/documentation/AppKit/NSScroller/rect(for:))

Returns the rectangle occupied by `aPart`, which for this method is interpreted literally rather than as an indicator of scrolling direction.



---

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)