Protocol

NSColorPickingDefault

A set of methods that provides basic behavior for a color picker.

Declaration

@protocol NSColorPickingDefault

Overview

The NSColorPickingDefault protocol, together with the NSColorPickingCustom protocol (which provides implementation-specific behavior), provides an interface for adding color pickers to an app’s color panel.

Topics

Creating Color Pickers

- initWithPickerMask:colorPanel:

Initializes the receiver with a given color panel and its mode.

Required.

Configuring Color Pickers

- setMode:

Specifies the receiver’s mode.

Required.

- insertNewButtonImage:in:

Sets the image of a given button cell.

Required.

- provideNewButtonImage

Provides the image of the button used to select the receiver in the color panel.

Required.

- minContentSize

Indicates the receiver’s minimum content size.

Required.

- buttonToolTip

Provides the toolbar button help tag.

Required.

Handling Events

- alphaControlAddedOrRemoved:

Sent when the color panel's opacity controls have been hidden or displayed.

Required.

- viewSizeChanged:

Tells the recever when the color panel's view size changes in a way that might affect the color picker.

Required.

Managing Color Lists

- attachColorList:

Tells the receiver to attach the given color list, if it isn’t already displaying the list.

Required.

- detachColorList:

Tells the receiver to detach the given color list, unless the receiver isn’t displaying the list.

Required.

Relationships

Conforming Types

See Also

Color Panels

NSColorPanel

A standard user interface for selecting color in an app.

NSColorPickingCustom

A set of methods that provides a way to add color pickers—custom user interfaces for color selection—to an app’s color panel.

NSColorPicker

An abstract superclass that implements the NSColorPickingDefault protocol.