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

# drawArrow(_:highlight:)

Draws the scroll button indicated by `arrow`, which is either `NSScrollerIncrementArrow` (the down or right scroll button) or `NSScrollerDecrementArrow` (up or left).

```
func drawArrow(_ whichArrow: NSScroller.Arrow, highlight flag: Bool)
```

## Discussion

If `flag` is <doc://com.apple.documentation/documentation/Swift/true>, the button is drawn highlighted; otherwise it’s drawn normally. You should never need to invoke this method directly, but may wish to override it to customize the appearance of scroll buttons.

> Note:
> The ``doc://com.apple.appkit/documentation/AppKit/NSScroller/drawArrow(_:highlight:)`` method is not invoked in macOS 10.7 and later.

## 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)