Questions tagged [ios-darkmode]

In macOS and iOS (13.0 and later), users can choose to adopt a system-wide light or dark appearance. The dark appearance, known as Dark Mode, implements an interface style that many apps already adopt. Users choose the aesthetic they prefer, and can also choose to toggle their interface based on ambient lighting conditions or a specific schedule.

All iOS/Mac apps should support both light and dark interface styles, but might perform better with a specific appearance in some places.

271 questions
8
votes
2 answers

Xamarin.Forms: Disabled entry has white TextColor when Dark Mode is enabled on iOS

I seem to have some troubles with the TextColor of my Entry on iOS when Dark Mode is enabled. Whenever I set the Entry's Enabled state to false, the TextColor turns white and it's not possible to change. I used the following simple code to reproduce…
8
votes
5 answers

How to set default label color based on dark/light mode (in Swift)

I am trying to update my iOS app for dark mode, but am having trouble with setting the dark mode colors in code. Upon editing a UITextView, the color I want the text color to be white in dark mode, and black in light mode (which is default label…
tHatpart
  • 1,302
  • 3
  • 12
  • 27
8
votes
3 answers

How can I turn the MKMapView for dark mode?

How can I change the map to dark mode from iOS 13? I have opt-out from UserInterfaceStyle so system-wide colors will not apply to me, so I'll do it manually. I've seen this video from apple WWDC2019 - Session 236, at 8:19s but that's for snapshots…
Marlhex
  • 1,870
  • 19
  • 27
8
votes
0 answers

How to support Dark mode launch screen in iOS 13 with custom color?

I am working on adapting my existing iOS 11+ app to the new Dark Mode in iOS 13. Using dynamic / named colors works without any problem to switch between been normal and dark appearance, except on the apps launch screen. A simple XIB file is…
Andrei Herford
  • 17,570
  • 19
  • 91
  • 225
8
votes
1 answer

hasDifferentColorAppearance is true when app is backgrounded

Apple recommends that we use traitCollectionDidChange and compare trait collections using hasDifferentColorAppearance to catch when dark mode is toggled, and act on it if we need to. Like this: override func traitCollectionDidChange(_…
rodskagg
  • 3,827
  • 4
  • 27
  • 46
8
votes
1 answer

Fallback behavior for new iOS 13 system colors in iOS 12

I’m currently adopting to Dark Mode and I figured that using the new system colors like systemBackground and label in Interface Builder also just works when running the app in iOS 12. I half expected to get a compiler error, but instead the app…
Frank Rupprecht
  • 9,191
  • 31
  • 56
7
votes
1 answer

How can I remove Gmail App Dark Mode stylings?

I'm building out an email using mjml and the design is pretty standard and not flexible to change. In gmail the copy becomes illegible because gmail inverts the white copy to black copy. I want gmail to keep my intended stylings, is there a method…
Moe-Joe
  • 1,012
  • 3
  • 15
  • 27
7
votes
2 answers

traitCollectionDidChange being called multiple times when only going to background

I have found that when putting app into background the traitCollectionDidChange method is being called twice and showing that trait collections differ when actually no changes have been made. - (void)traitCollectionDidChange:(UITraitCollection…
Evan
  • 101
  • 7
7
votes
2 answers

Border color doesn't change when changing themes in iOS 13

I recently developed app which is compatible with Dark mode. And dark mode also works fine. Btw when I change from dark->light, light->dark mode from device, all colors change as expected except border color. Let's say border color is black when…
Ioan Moldovan
  • 2,272
  • 2
  • 29
  • 54
7
votes
1 answer

Xcode 11, Asset catalogue naming convention for dark / light images?

Previously images dragged into the Xcode asset catalogue could be named as follows ... Rabbit@2x.png Rabbit@3x.png on releasing the drag these images were automatically assigned to the correct 2x & 3x slots within the catalogue. Now with iOS 13…
fuzzygoat
  • 26,573
  • 48
  • 165
  • 294
7
votes
1 answer

PWA - Status bar background and text color on IOS 13 dark-mode

I'm experiencing some trouble with my PWAs status bar color after Apple introduced the dark mode on the new IOS 13. I used to set the "apple-mobile-web-app-status-bar-style" to "black-translucent" for a transparent background with white text on the…
Bulhosa
  • 71
  • 1
  • 3
7
votes
4 answers

How we Support Dark Mode in Current iOS App with iOS 13?

My current app is developed in objC and Swift both. i need to support a darkmode. can anyone suggest how can i achieve this by globally?
Pushp
  • 1,064
  • 10
  • 18
6
votes
1 answer

UIViewController userInterfaceStyle is always light

When darkmode is enabled, UIViewControllers always use light mode. viewController.traitCollection.userInterfaceStyle is always Light but window.traitCollection.userInterfaceStyle is Dark. UIUserInterfaceStyle is not set in plist. I tried all…
Martin Vandzura
  • 3,047
  • 1
  • 31
  • 63
6
votes
1 answer

app doesn't update and traitCollectionDidChange doesn't fire when user changes appearance in settings

In my app I allow the user to override the appearance that is set on the device. Here's the class that handles updating the UI if they want to override the system-wide appearance: class UserInterfaceStyleController { init() { …
Brian M
  • 3,812
  • 2
  • 11
  • 31
6
votes
1 answer

Why iOS13 changes the font-family inside NSAttributedString for paragraphs

My application uses NSAttributedString to display text to the user. Most of this text is inside the paragraph HTML tags (

). When it's inside the tags, the font family is changed to some Times style. It happend in the new version iOS 13, before we…

Grzegorz Świerad
  • 365
  • 1
  • 2
  • 10
1 2
3
18 19