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

# drawsBackground

A Boolean value that indicates if the clip view draws its background color.

```
var drawsBackground: Bool { get set }
```

## Discussion

If your [`NSClipView`](/documentation/AppKit/NSClipView) is enclosed in an [`NSScrollView`](/documentation/AppKit/NSScrollView), you should set the [`drawsBackground`](/documentation/AppKit/NSClipView/drawsBackground) property on the [`NSScrollView`](/documentation/AppKit/NSScrollView). Setting this property to <doc://com.apple.documentation/documentation/Swift/false> on an [`NSScrollView`](/documentation/AppKit/NSScrollView) has the added effect of setting the [`NSClipView`](/documentation/AppKit/NSClipView) property [`copiesOnScroll`](/documentation/AppKit/NSClipView/copiesOnScroll) to <doc://com.apple.documentation/documentation/Swift/false>. The side effect of setting the [`drawsBackground`](/documentation/AppKit/NSClipView/drawsBackground) property on the [`NSClipView`](/documentation/AppKit/NSClipView) is the appearance of “trails” (vestiges of previous drawing) in the document view as it is scrolled.

---

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)