_rightTF.placeholder = @"請輸入註冊時的手機號碼";
NSMutableDictionary *dict = [NSMutableDictionary dictionary];
dict[NSForegroundColorAttributeName] = [UIColor colorWithRed:25/255.0 green:158/255.0 blue:253/255.0 alpha:0.4];
NSAttributedString *attr = [[NSAttributedString alloc] initWithString:_rightTF.placeholder attributes:dict];
[_rightTF setAttributedPlaceholder: attr];
[_rightTF setValue:[UIFont boldSystemFontOfSize:15 * HomePageDefineWidth] forKeyPath:@"_placeholderLabel.font"];
設置UItextfiled的placehold的顏色和大小
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.