Structure

NSWorkspace.DesktopImageOptionKey

Keys that indicate how to display a new desktop image.

Declaration

struct DesktopImageOptionKey

Overview

Specify the following keys when calling the setDesktopImageURL(_:for:options:) method.

Topics

Option Keys

static let imageScaling: NSWorkspace.DesktopImageOptionKey

A key that contains the behavior to use when scaling the image.

static let allowClipping: NSWorkspace.DesktopImageOptionKey

A key that contains the behavior to use when clipping the image.

static let fillColor: NSWorkspace.DesktopImageOptionKey

A key that contains the behavior to use when filling the empty space around the image.

Relationships

See Also

Managing the Desktop Image

func desktopImageURL(for: NSScreen) -> URL?

Returns the URL for the desktop image for the given screen.

func setDesktopImageURL(URL, for: NSScreen, options: [NSWorkspace.DesktopImageOptionKey : Any])

Sets the desktop image for the given screen to the image at the specified URL.