UIButtonSetBackgroundColorForState
UIButton set background color for state extension in Swift/OC.
Install / Use
/learn @swordray/UIButtonSetBackgroundColorForStateREADME
UIButtonSetBackgroundColorForState
Add method setBackgroundColor:forState: to UIButton.
Example
To run the example project, clone the repo, and run pod install from the Example directory first.
Requirements
- iOS 7 or later
Installation
UIButtonSetBackgroundColorForState is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "UIButtonSetBackgroundColorForState"
Usage
- (void)setBackgroundColor:(nullable UIColor *)color forState:(UIControlState)state;
Author
Jianqiu Xiao, swordray@gmail.com
Sponsors
License
UIButtonSetBackgroundColorForState is available under the MIT license. See the LICENSE file for more info.
