Skip to content

Instantly share code, notes, and snippets.

@Tricertops
Created March 4, 2013 13:10
Show Gist options
  • Save Tricertops/5082127 to your computer and use it in GitHub Desktop.
Save Tricertops/5082127 to your computer and use it in GitHub Desktop.
Great debugging tool when you have a lot of views ;)
@implementation UIColor (Random)
+ (instancetype)randomColor {
return [self colorWithRed:(arc4random() % 255) / 255.f
green:(arc4random() % 255) / 255.f
blue:(arc4random() % 255) / 255.f
alpha:1];
}
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment