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

How to map the icon name to the library's enum? #10

Closed
klwoon opened this issue Jun 30, 2017 · 2 comments
Closed

How to map the icon name to the library's enum? #10

klwoon opened this issue Jun 30, 2017 · 2 comments
Labels

Comments

@klwoon
Copy link

klwoon commented Jun 30, 2017

For example the IcoFont 5-start-hotel is referenced by .icofont(.fiveStarHotel), is there any direct mapping?

Or is there any way to reference the icon using unicode? such as ef05 to get 5-star-hotel.

screen shot 2017-06-30 at 3 47 36 pm

@ranesr
Copy link
Owner

ranesr commented Jun 30, 2017

@klwoon Unfortunately, there is no direct mapping. The only reason why there is no direct mapping for examples like 5-star-hotel is because Apple does not allow to start case values for enum with an integer. Also, Apple does not allow keywords to be case values for enum. All the other icons should be mapped to there icon name.

@klwoon
Copy link
Author

klwoon commented Jul 1, 2017

Thanks for the reply, this library is great!

@klwoon klwoon closed this as completed Jul 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants