似乎UIPickerView不再支持将NSAttributedString用于选择器视图项.谁能证实这一点?我在UIPickerView.h文件中找到了NS_AVAILABLE_
IOS(6_0),但这是问题吗?有没有办法解决这个问题,还是我运气不好?
- (NSString *)pickerView:(UIPickerView *)pickerView titleForRow:(NSInteger)row forComponent:(NSInteger)component; - (NSAttributedString *)pickerView:(UIPickerView *)pickerView attributedTitleForRow:(NSInteger)row forComponent:(NSInteger)component NS_AVAILABLE_IOS(6_0); // attributed title is favored if both methods are implemented - (UIView *)pickerView:(UIPickerView *)pickerView viewForRow:(NSInteger)row forComponent:(NSInteger)component reusingView:(UIView *)view;