Contents

usingColorSpaceName(_:device:)

Creates a new color object for the same color, but in the specified color space and specific to the provided device.

Declaration

func usingColorSpaceName(_ name: NSColorSpaceName?, device deviceDescription: [NSDeviceDescriptionKey : Any]?) -> NSColor?

Parameters

  • name:

    The name of the color space containing the new NSColor object. If colorSpace is nil, the most appropriate color space is used.

  • deviceDescription:

    The device description. Device descriptions can be obtained from windows, screens, and printers with the deviceDescription method.

    If deviceDescription is nil, the current device (as obtained from the currently lockFocus’ed view’s window or, if printing, the current printer) is used.

Return Value

The new NSColor object or nil if the specified conversion cannot be done.

See Also

Related Documentation

Deprecated