Platforms to show: All Mac Windows Linux Cross-Platform

NSColorSpaceMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Cocoa Drawing MBS MacBase Plugin 8.6 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The NSColorSpace class enables the creation of objects representing custom color spaces.

You can make custom color spaces from ColorSync profiles or from ICC profiles. NSColorSpace also has factory methods that return objects representing the system color spaces.

Constants

Constant Value Description
NSCalibratedBlackColorSpace "NSCalibratedBlackColorSpace" Calibrated color space with black and alpha components (pure black is 1.0) Deprecated in Mac OS X v10.6.
Example
NSCalibratedRGBColorSpace "NSCalibratedRGBColorSpace" Calibrated color space with red, green, blue, and alpha components. You can also create a color with HSB (hue, saturation, brightness) and alpha components and can extract these components.
Example
NSCalibratedWhiteColorSpace "NSCalibratedWhiteColorSpace" Calibrated color space with white and alpha components (pure white is 1.0) Example
NSCMYKColorSpaceModel 2 The CYMK (cyan, yellow, magenta, black) color-space model. Can refer to both device-dependent and generic color space variants.
Available in Mac OS X v10.4 and later.
Example
NSCustomColorSpace "NSCustomColorSpace" Custom NSColorSpace object and floating-point components describing a color in that space. A custom color-space object represents a color space that is not necessarily predefined by the Application Kit. See "Working With Color Spaces" for information on creating custom color-space objects.
NSDeviceBlackColorSpace "NSDeviceBlackColorSpace" Device-dependent color space with black and alpha components (pure black is 1.0) Example
NSDeviceCMYKColorSpace "NSDeviceCMYKColorSpace" Device-dependent color space with cyan, magenta, yellow, black, and alpha components. Example
NSDeviceNColorSpaceModel 4 DeviceN is a color-space model from Adobe Systems, Inc. used in PostScript and PDF color specification. Available in Mac OS X v10.4 and later.
Example
NSDeviceRGBColorSpace "NSDeviceRGBColorSpace" Device-dependent color space with red, green, blue, and alpha components. You can also create a color with HSB (hue, saturation, brightness) and alpha components and can extract these components.
Example
NSDeviceWhiteColorSpace "NSDeviceWhiteColorSpace" Device-dependent color space with white and alpha components (pure white is 1.0) Example
NSGrayColorSpaceModel 0 The grayscale color-space model. Can refer to both device-dependent and generic color space variants. Available in Mac OS X v10.4 and later.
Example
NSIndexedColorSpaceModel 5 An indexed color space, which identifies specified discrete colors in a color list by index number. An indexed color value (a color specification in indexed color space) consists of an index value that refers to a color in a color list.

Available in Mac OS X version 10.5 and later.
Example
NSLABColorSpaceModel 3 The L*a*b* device-independent color-space model, which represents colors relative to a reference white point. Available in Mac OS X v10.4 and later.
Example
NSNamedColorSpace "NSNamedColorSpace" Catalog name and color name components. The components of this color space are indexes into lists or catalogs of prepared colors. The catalogs of named colors come with lookup tables that are able to generate the correct color on a given device.
NSPatternColorSpace "NSPatternColorSpace" Pattern image (tiled) Identifies a pattern color space, which is simply an image that is repeated over and over again in a tiled pattern.
NSPatternColorSpaceModel 6 Identifies a pattern color space, which is simply an image that is repeated over and over again in a tiled pattern. Available in Mac OS X version 10.5 and later.
Example
NSRGBColorSpaceModel 1 The RGB (red green blue) color-space model. Can refer to both device-dependent and generic color space variants.
Available in Mac OS X v10.4 and later.
Example
NSUnknownColorSpaceModel -1 This model is not known to NSColorSpace. Available in Mac OS X v10.4 and later.

This class has no sub classes.

Some methods using this class:

Some properties using for this class:

Some examples using this class:

Blog Entries

Release notes

  • Version 24.0
  • Version 19.1
    • Added work around to NSColorSpaceMBS.File property to make it work better.
  • Version 18.5

The items on this page are in the following plugins: MBS MacBase Plugin.


NSColorSamplerMBS   -   NSComboBoxMBS


The biggest plugin in space...