Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NSInvalidArgumentException #180

Open
Hatom1K opened this issue Apr 21, 2015 · 5 comments
Open

NSInvalidArgumentException #180

Hatom1K opened this issue Apr 21, 2015 · 5 comments

Comments

@Hatom1K
Copy link

Hatom1K commented Apr 21, 2015

I use FUIButton without IB so i make that in my .m:

self.boutton_commencer.buttonColor = [UIColor carrotColor];
self.boutton_commencer.shadowColor = [UIColor alizarinColor];
self.boutton_commencer.shadowHeight = 3.0f;
self.boutton_commencer.cornerRadius = 6.0f;
self.boutton_commencer.titleLabel.font = [UIFont boldFlatFontOfSize:16];
[self.boutton_commencer setTitleColor:[UIColor cloudsColor] forState:UIControlStateNormal];
[self.boutton_commencer setTitleColor:[UIColor cloudsColor] forState:UIControlStateHighlighted];

And i my .h i set that:

@Property (strong, nonatomic) FUIButton *boutton_commencer;

But when i test this code i get this error:

2015-04-21 19:41:10.833 WeProov[85487:6502034] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[UIColor carrotColor]: unrecognized selector sent to class 0x3bc00c8'

Thanks you !

@jamieomatthews
Copy link
Contributor

Check your installation. Did you install through Cocoapods, or copy the
files? What happends when you command-click on [UIColor carrotColor],
where does it take you?

On Tue, Apr 21, 2015 at 1:48 PM, Hatom1K notifications@github.com wrote:

I use FUIButton without IB so i make that in my .m:

self.boutton_commencer.buttonColor = [UIColor carrotColor];
self.boutton_commencer.shadowColor = [UIColor alizarinColor];
self.boutton_commencer.shadowHeight = 3.0f;
self.boutton_commencer.cornerRadius = 6.0f;
self.boutton_commencer.titleLabel.font = [UIFont boldFlatFontOfSize:16];
[self.boutton_commencer setTitleColor:[UIColor cloudsColor] forState:UIControlStateNormal];
[self.boutton_commencer setTitleColor:[UIColor cloudsColor] forState:UIControlStateHighlighted];

And i my .h i set that:

@Property https://github.com/property (strong, nonatomic) FUIButton
*boutton_commencer;

But when i test this code i get this error:

2015-04-21 19:41:10.833 WeProov[85487:6502034] *** Terminating app due to
uncaught exception 'NSInvalidArgumentException', reason: '+[UIColor
carrotColor]: unrecognized selector sent to class 0x3bc00c8'

Thanks you !


Reply to this email directly or view it on GitHub
#180.

@Hatom1K
Copy link
Author

Hatom1K commented Apr 21, 2015

When i CMD+Click on that i go to Pod folder (Pod/FlatUIKit/UIColor+FlatUI.m) et i show that:

  • (UIColor *) carrotColor {
    static UIColor *carrot = nil;
    static dispatch_once_t carrotToken;

    dispatch_once(&carrotToken, ^{
    carrot = [UIColor colorFromHexCode:@"E67E22"];
    });

    return carrot;
    }

@jamieomatthews
Copy link
Contributor

you might try re-installing the pod. It seems like the file is being seen
at compile time, but not runtime

On Tue, Apr 21, 2015 at 2:00 PM, Hatom1K notifications@github.com wrote:

When i CMD+Click on that i go to Pod folder
(Pod/FlatUIKit/UIColor+FlatUI.m) et i show that:

(UIColor *) carrotColor {
static UIColor *carrot = nil;
static dispatch_once_t carrotToken;

dispatch_once(&carrotToken, ^{
carrot = [UIColor colorFromHexCode:@"E67E22"];
});

return carrot;
}


Reply to this email directly or view it on GitHub
#180 (comment).

@Hatom1K
Copy link
Author

Hatom1K commented Apr 21, 2015

so i remove line "pod 'FlatUIKit'", I type: pod install and I re-add pod "'FlatUIKit'" ?

@Hatom1K
Copy link
Author

Hatom1K commented Apr 21, 2015

No, I have the same issue ..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants