-
Notifications
You must be signed in to change notification settings - Fork 48
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
Uppercase and Capitalized? #6
Comments
Hey @gmarm. Thats nice! sure, that would be something that people will like to have I think. |
Yes that's how I initially approached it, however it didn't work. I tried adding a I did manage to make it work in a quick and less elegant way as can be seen here https://github.com/gmarm/IBLocalizable/pull/1, however I'm not happy with result. There are now three I would very much prefer to somehow get it working with an approach similar to the first one. If you have any ideas, lets discuss. |
Yes, like you mention you cant do stored properties in extensions without being hacky. How about instead of using Thats a little better, no? |
As I said, that's what I initially tried, unless I'm missing something you're pointing out. My main problem was the implementation of @IBInspectable public var capitalized: Bool {
// implementation?
} for example in the |
@gmarm may be you can try something like that ;)
|
@HamzaGhazouani Thanks, that's interesting. Although, is there any guarantee that setting |
Hi @gmarm, you should be sure that the |
I have been using a similar solution to what
IBLocalizable
does for quite some time using user defined attributes, although not having to define user defined attributes myself is admittedly so much cooler!Over time, I realized that I was creating outlets just so I can capitalize or uppercase the localizable properties of UI elements, so I added a few extra methods for handling that. Something like:
Do you think something like that, implemented according to
IBLocalizable
's architecture would make sense to be added?The text was updated successfully, but these errors were encountered: