@property (nonatomic, strong) NSArray *listData;
self.listData = [UIFont familyNames];
放在表视图里面:
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
// Return the number of rows in the section.
return self.listData.count;
}
cell.textLabel.text = self.listData[indexPath.row];
cell.textLabel.font = [UIFont fontWithName:self.listData[indexPath.row] size:20];