1

I have a story board file as the launch screen. I have set image in button background Image. In that image, I have an image set for light and dark mode. but when I switch to dark mode, it always shows light mode image.

Pratik Gadoya
  • 1,420
  • 1
  • 16
  • 27
  • 2
    Have you tried uninstalling the app, restarting your phone and installing again? The Launch Screen is heavily cached by the OS and that's the only reliable way I found to really update the screen. – Frank Rupprecht Nov 22 '19 at 07:54
  • Thank you @FrankSchlegel! Searched forever before I found this answer. Deleting the app and restarting the phone worked! – Caleb L Oct 21 '20 at 10:32

2 Answers2

2

I'm not sure if you still need an answer to this, but I recently had the same issue. For me, what fixed this was to uncheck the box 'Preserve Vector Data' within the image set properties. This means resizing won't work on the vector image, but you will see the image change with light/dark mode toggled within the storyboard. Alternatively if I go back and check 'Preserve Vector Data' (back to the original state) the Dark image will display when the app is running if the simulator phone is in Dark mode.

Ash
  • 21
  • 3
0

Make sure you have enabled Appearance to Any, Dark. And check that you have added images for dark mode appearance.

enter image description here

Manikandan
  • 1,195
  • 8
  • 26
  • I have done this steps correctly dude, Still not working –  Nov 22 '19 at 07:34
  • 2
    Please uninstall and installed your app. The launch screen will be cache in the system. it will only update when you install the app. – Manikandan Nov 22 '19 at 10:06
  • rebooted device and reinstalled app but image does not changed, the background color i set to systemBackgroundColor, but does not change while change to dark mode – famfamfam Apr 06 '21 at 17:17