Tag: uipickerviewdatasource

UIPickerView:NSAttributedString在iOS 7中不可用?

看来UIPickerView不再支持使用NSAttributedStringselect器视图项目。 任何人都可以确认吗? 我在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;