-
Notifications
You must be signed in to change notification settings - Fork 550
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
Now supports customized footer text attributes. #57
Conversation
Please @chiunam, let me know if you think there's a better solution to this issue. |
Fixes this issue. |
Hi @diegoreymendez, I prefer making the control to conform UIApperance rather than using properties for UI customisation. I made an experiment code [ae80272] to change the toolbar for that so it can be overridden by code like this:- UIBarButtonItem *barButtonItem = [UIBarButtonItem appearanceWhenContainedIn:[UIToolbar class], [CTAssetsPickerController class], nil];
[barButtonItem setTitleTextAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:10], NSForegroundColorAttributeName: [UIColor redColor]} forState:UIControlStateNormal]; Please share your thought. |
Hi @chiunam, I've just tested it and it does indeed work. If you want to push this it'll be ok for us. Trying to conform to My only concern: This will still override the parent project's default A possible third alternative could be to just remove the appearance configuration from the library, and let your demo app set that up... although this would effectively make the library use the system colors by default when called by another app. It seems like all solutions have pros and cons, so any of the proposed solutions would be ok for us. Just let me know what you decide and we'll modify our project accordingly. Thank you very much! |
I think it is fine to set appearance again after picker's creation as it follows lazy initialisation concept. Though I want to make it easier for guys using default The experiment code will be merged to the master branch. Stay tuned. |
…troller # By Clement T # Via Clement T * 'master' of https://github.com/chiunam/CTAssetsPickerController: Update CocoaPods Spec Update README.md Update RELEASE-NOTES.md Resize screenshot Update Screenshot to iPhone 6 1and2papa#56 Move the localisable string to separated string table 1and2papa#57 Make the picker's toolbar to conform UIApperance so that it can be overridden Update CocoaPods Spec Update RELEASE-NOTES.md 1and2papa#55 Fix: Pictures disappear until you do scrolling gesture when you take screenshot Rectify documentation Conflicts: CTAssetsPickerDemo.xcodeproj/project.pbxproj
This fix allows for the customization of the footer's
UIBarButtonItem
global-appearance text attributes withoutCTAssetPickerController
overriding it.For example:
Another alternative to this fix could be to remove from
CTAssetsPickerController.m
the code that sets the footer'sUIBarButtonItem
text attributes.