iOS 7 UIDatePicker - missing white text? - ios

I'm just updating my application to use iOS 7. My plan is to set the background color in black with white text on a UIDatePicker. Is there a possible way I can set the color of the text on a UIDatePicker? If not, then it would be nice to have "setDatePickerViewStyle:UIDatePickerStyleLightContent" for UIDatePicker to be similar to the status bar style.
Any suggestion appreciated.

According the the styling guide, UIDatePickers cannot be styled:
https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/UIKitUICatalog/UIDatePicker.html#//apple_ref/doc/uid/TP40012857-UIDatePicker-SW1

Related

Storyboard is not showing custom color hex code in XCode 12.0.1

After updating to the latest Xcode, into storyboard I am not able to see actual custom color hex code. It is showing a white(FFFFFF) color hex code all time.
Can someone please help me with this? Please check the below screenshot.
I have noticed this same problem since the latest XCode Version 12.0.1.
A workaround that works for me is to
Click on the custom color to bring up the color chooser.
The color chooser is the wrong color, but tap on any other color in the color chooser.
Tap Cmd+Z to undo the color change. Magically the original custom color is now selected in the color chooser.
Almost the same idea work around and quicker without needing to change the color (and then reverse):
Select your color (this will make the color picker appear) in the drop list.
Select again your color (with the picker still shown) in the drop list (not in the color picker window), it will update the picker to your color.
Apple has now fixed this issue in Xcode 12.5
Fixed an issue where the custom colors swatch in an inspector’s color
properties displayed an incorrectly offset focus indicator.
Reference: Apple Xcode 12.5 Release Notes

iOS 13 Navigation Bar Prompt is Always Black

I have read the other posts about the UINavigationBar's Prompt not following the color values of the actual Title. Most of the posts are from the iOS 11 era, and the solutions no longer work on iOS 13.
These are examples of previous posts that no longer have working solutions:
Can't change UINavigationBar prompt color
Change font of prompt in UINavigationController
iPhone: Possible to change the color of just the prompt of the UINavigationBar?
Has anyone else encountered this?
I would suggest the following:
Check that the device is not running in Dark Mode.
Verify that the background-color was not modified anywhere in the code.
Make sure that the style is set to default like in the screenshot below:

iOS Swift Notifications action background color

After some search i couldn't find information on how to change notification button background colors. Is this possible to do with Swift in iOS?
Thanks :)
The only thing you can do is to set it to red color. You can achieve it if you set actionButton.destructive equal to true

Change iOS System Keyboard Background Image and Buttons Image

Rather than creating a custom keyboard...how can I change the ios keyboard background image and get reference of the keyboard button or just the keyboard view programatically?
I do not want to replicate the whole ios keyboard, just tweak the keyboard here and there.
Solution Update:
You cannot update only the background or the buttons of the iOS System Keyboard! This is dues to the reason that Apple has limited the access to the Keyboard API. The most you can do is change the keyboard background color i.e. dark or light.
If you need to change the background to an image like me, you need to extend the ios keyboard i.e. make your own custom keyboard!
Please check below for accepted answer!
Hope this helps!
You can do something like this,
myTextField.keyboardType = UIKeyboardTypeDecimalPad; // many other options
myTextField.keyboardAppearance = UIKeyboardAppearanceDark; //many other options
If you want totally customize keyboard then refer this tutorial.
Hope this will help :)
For dark background you can use
mytextfield.keyboardAppearance = UIKeyboardAppearanceAlert;
For more customisation follow this link:
https://developer.apple.com/library/ios/documentation/UIKit/Reference/UITextInputTraits_Protocol/index.html

Xcode: reverting back to default color in iOS

I am trying to find a way to revert back to the system default color programmatically for iOS components using code. The only other way would be to use 2 controls - 1 set to either color and switch them.
Any info is appreciated. Thanks.
I tried below code in order to change the background of a button to its default color and it worked for me
submitBtn.backgroundColor = UIColor.clear

Resources