Instance Method

drawTitle:withFrame:inView:

Draws the button’s title centered vertically in a specified rectangle.

Declaration

- (NSRect)drawTitle:(NSAttributedString *)title withFrame:(NSRect)frame inView:(NSView *)controlView;

Parameters

title

The title of the button.

frame

The rectangle in which to draw the title.

controlView

The control being drawn.

Return Value

The bounding rectangle for the text of the title.

Discussion

This method is called automatically when the button is redrawn; you should not call it directly.

See Also

Drawing the Button Content

- drawBezelWithFrame:inView:

Draws the border of the button using the current bezel style.

- drawImage:withFrame:inView:

Draws the image associated with the button’s current state.