Instance Method

setButtonType:

Sets how the button highlights while pressed and how it shows its state.

Declaration

- (void)setButtonType:(NSButtonType)type;

Parameters

aType

A constant specifying the type of button. This can be one of the constants defined in NSButtonType.

Discussion

The setButtonType: method redisplays the button before returning.

The types available are for the most common button types, which are also accessible in Interface Builder; you can configure different behavior with the highlightsBy and showsStateBy properties.

Note that there is no -buttonType method. The set method sets various button properties that together establish the behavior of the type.

See Also

Displaying the Cell

highlightsBy

A set of flags that indicate how the button highlights when it receives a mouse-down event (that is, when the button is pressed).

showsStateBy

The flags that indicate how the button cell shows its alternate state.