I would like to add a shadow effect to my UITextField currently what I\'m achieving is this: As you can see the shadow is not rounded in the corners. My code:
try this, code is in objective C, but same for swift
self.textField.layer.shadowColor = [[UIColor blackColor] CGColor]; self.textField.layer.shadowOffset = CGSizeMake(0.0, 1.0); self.textField.layer.shadowOpacity = 1; self.textField.layer.shadowRadius = 0.0;