TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Apr 2016 |
Maintained by Giuseppe Nucifora.
Depends on: | |
PureLayout | >= 0 |
RZDataBinding | >= 0 |
To run the example project, clone the repo, and run pod install
from the Example directory first.
GradientButton is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "GradientButton"
GradientButton *button = [[GradientButton alloc] initWithFrame:CGRectMake(0, 0, 200, 50)];
[button setCenter:self.view.center];
[button setTitle:@"Normal Button" forState:UIControlStateNormal];
[button setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
[button setbackgroundLayerWithColors:@[[UIColor redColor],[UIColor blueColor]] startPoint:CGPointMake(0, 0)];
[self.view addSubview:button];
GradientButton *autoLayoutButton = [GradientButton newAutoLayoutView];
[autoLayoutButton setTitle:@"Autolayout Button" forState:UIControlStateNormal];
[autoLayoutButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
[autoLayoutButton setbackgroundLayerWithColors:@[[UIColor redColor],[UIColor greenColor],[UIColor whiteColor]] startPoint:CGPointMake(0, 0)];
[self.view addSubview:autoLayoutButton];
Giuseppe Nucifora, [email protected]
GradientButton is available under the MIT license. See the LICENSE file for more info.