UITextField属性--PlaceHolder颜色自定义

//设置placeHolder的颜色

    UIColor *color = [UIColor colorWithRed:168/255.0 green:166/255.0 blue:42/255.0 alpha:1.0];

    self.endAddressText.attributedPlaceholder = [[NSAttributedString alloc] initWithString:@"请输入目的地" attributes:@{NSForegroundColorAttributeName: color}];

你可能感兴趣的:(placeholder,UITextField)