Skip to content

Instantly share code, notes, and snippets.

@kmussel
Created August 10, 2012 14:37
Show Gist options
  • Save kmussel/3314696 to your computer and use it in GitHub Desktop.
Save kmussel/3314696 to your computer and use it in GitHub Desktop.
UIButton *peopleFilter = [UIButton buttonWithType:UIButtonTypeCustom];
peopleFilter.frame = CGRectMake(5, 3, 90, 28);
[peopleFilter setImage:[UIImage imageNamed:@"radio_button_off"] forState:UIControlStateNormal];
[peopleFilter setImage:[UIImage imageNamed:@"radio_button_on"] forState:UIControlStateSelected];
peopleFilter.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
peopleFilter.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[peopleFilter setTitle:@"PEOPLE & PLAYERS" forState:UIControlStateNormal];
peopleFilter.titleEdgeInsets = (UIEdgeInsets){2, 2, 0, 0};
peopleFilter.titleLabel.font = [UIFont fontWithName:@"Gotham-Bold" size:11];
peopleFilter.titleLabel.numberOfLines = 2;
peopleFilter.titleLabel.lineBreakMode = UILineBreakModeWordWrap;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment