Platforms to show: All Mac Windows Linux Cross-Platform

NSColorMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Cocoa Drawing MBS MacBase Plugin 7.2 ✅ Yes ❌ No ❌ No ✅ Yes All
The class for a Cocoa color.
Example
dim c as NSColorMBS = NSColorMBS.blueColor
MsgBox str(c.blueComponent)

System Effect

Constant Value Description
SystemEffectDeepPressed 2 Deep Pressed
SystemEffectDisabled 3 Disabled
SystemEffectNone 0 No
SystemEffectPressed 1 Pressed
SystemEffectRollover 4 Rollover

Color Types

Constant Value Description
TypeCatalog 2 nColor with a catalog name and a color name. These colors can be dynamic and have multiple underlying color values.one
TypeComponentBased 0 Colors which have a color space (specified as NSColorSpace) and appropriate number of CGFloat components.
TypePattern 1 Colors that draw a pattern, specified as an NSImage.

This class has no sub classes.

Some methods using this class:

Some properties using for this class:

Some events using this class:

Some examples using this class:

Blog Entries

Xojo Developer Magazine

Videos

Release notes

  • Version 21.2
  • Version 19.4
    • Added systemIndigoColor and systemTealColor to NSColorMBS class.
  • Version 19.3
    • Changed NSColorMBS constructor and colorValue property to always use generic RGB for compatibility to Xojo.
  • Version 18.4
    • Added 40 new methods to NSColorMBS class for MacOS 10.14 Mojave.
    • Fixed bug in NSColorMBS with alpha channel from Xojo color.
    • Fixed NSColorMBS.colorValue for new colors on MacOS Mojave.
  • Version 17.1
    • Added NSColorMBS.Constructor for convenient color creation.

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


NSColorListMBS   -   NSColorPanelMBS


The biggest plugin in space...