Created
November 6, 2014 04:14
-
-
Save ddonovan/bc27619cda8a8bc47cec to your computer and use it in GitHub Desktop.
Sample of how to add a glow to a UITextField, for something like active control, or error, etc.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)highlightControl: (UITextField *) textField{ | |
; | |
// textField.layer.cornerRadius = 5; | |
// textField.clipsToBounds = YES; | |
// textField.layer.borderWidth = 1; | |
// textField.layer.borderColor =[[UIColor redColor] CGColor]; | |
textField.layer.masksToBounds = NO; | |
textField.layer.shadowColor = [[UIColor redColor] CGColor]; | |
textField.layer.shadowOffset = CGSizeZero; | |
textField.layer.shadowRadius = 5.0f; | |
textField.layer.shadowOpacity = 1.0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment