Created by: rcdilorenzo
Reasoning
If you add several of the floating label properties as UIAppearance selectors, it makes it so that you don't have to configure every single instance. I've been considering using this in an app that has tons of text fields in it, which makes UIAppearance nearly a requirement for single setup. However, this doesn't prohibit setting the properties exactly as they are on each instance. Also, you will override the UIAppearance property if you that property specifically on an instance.
UIAppearance Properties
- [Added]
floatingLabelFont
- [Updated]
floatingLabelTextColor
- [Updated]
floatingLabelActiveTextColor
Example Usage
Here's a simple example of how to use these UIAppearance properties if anyone is unfamiliar. This code must be executed before the 1st initialization of a JVFloatLabeledTextField
:
[[JVFloatLabeledTextField appearance] setFloatingLabelActiveTextColor:[UIColor redColor]];
[[JVFloatLabeledTextField appearance] setFloatingLabelFont:[UIFont fontWithName:@"HelveticaNeue-UltraLight" size:kJVFieldFloatingLabelFontSize]];