I have a strange problem. I have an UITextField in which the user should write the amount of something, so the field is called \"amountField\". Everything looks fine, when t
This is because the BaselineOffset for the textfield got changed.
In UITextFieldDidEndEditing creating an attributed text with NSBaselineOffset: 0 and using that attributedText would fix the problem.
-(IBAction)txtFieldDidEndEditing:(UITextField *)sender {
NSDictionary *style = @{
NSBaselineOffsetAttributeName: @(0)
};
self.txtField.attributedText = [[NSAttributedString alloc] initWithString:self.txtField.text attributes:style];
}