This is a example on how you can top align text in a NSButton using a custom cell class.
#import "MSButtonTextTopCell.h"
MSButtonTextTopCell *cell = [[MSButtonTextTopCell alloc] init];
NSButton *button = [[NSButton alloc] initWithFrame:CGRectMake(0, 0, 100, 100];
[button setCell:cell];
[button setTitle:@"Button Text"];
[self addSubview:button];