Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

ios - iOS13 White Color issue with textColor of UIKit

Before iOS13 application Layout working as excepted. After latest dark theme and light theme update by apple in iOS13.1, Their is so, many issue facing in existing application. Like UITextField placeHolder with whiteColor which are previously blackColor, UIDatePicker textColor with whiteColor which are previously blackColor.

Can anyone help me with below DatePicker text color issue. which are invisible because whiteColor, TextColor should be blackColor.

enter image description here

Any help appreciated. Thank you.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Swift 5 with iOS 13

Common solution which is work for my whole application without perform any file specific changes.

Work for Xcode 11 or higher version, Build upload fail on prior version of Xcode 11.

Set UIUserInterfaceStyle to 1 in your info.plist file.

enter image description here

OR

AppDelegate.swift

    if #available(iOS 13.0, *) {
        window?.overrideUserInterfaceStyle = .light
    } else {
        // Fallback on earlier versions
    }

We have to specify user interface style light for any existing application.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...