Main.storyboard is pitch black - ios

I've been coding in Xcode for a long time but I've never used the storyboard. When I opened it up I got this pitch-black.
Does any one know how to fix this ?

A lot can cause a black screen. I think, most likely, you are currently previewing dark mode. You can switch back to light mode by clicking View as and changing the appearance.
Or, the background color of the view might be set to black (probably not the case though). You can change this in the attributes inspector.
Black color
System background color
System Background Color is white in light mode, and black in dark mode.
And there's always the possibility that Xcode is glitching. In that case, quit and relaunch.

For me, I had a datepicker set to inline mode, and it messed things up. I'd try and recall if you did anything that Xcode didn't like before it went black, and try and reverse that.

Related

iOS 11+ launch screen - custom named colors in dark mode

Is it possible to use user defined named colors in the launch screen storyboard?
I tried creating test color in xcassets, with appearances {dark, any} and setting it as Launch screen main view background.
I noticed significant differences:
- in RELEASE my custom colors never work
- in DEBUG some colors work, some are ignored, some are changing values (e.x. dark color is correct, but light is biased), and generally it is a mess
I know I need to delete app every time since launch screen is cached, are there any additional constraints? I fail to get any consistent results. Only thing that seems to work is "System background color".
Similar question goes for images.
OK, so short update. It is possible to use named colors and images with dark appearance on the launch screen after all.
It just works like nightmare. Which means that some parts are getting somehow cached (not sure what is happening underneath).
The final result is that to get consistent results, I had not only to delete app from the device, but also restart the phone.
I also noticed, that images with dark appearance are somehow broken - twice bigger or twice smaller, than their "any" appearance counterparts (even when I used exactly same files). That altogether creates unbelievable mess making it hard to test.
This is still a mess in iOS 13. I ended up using the build in dynamic system colours and tinting them with an overlay.

Setting next LaunchScreen during runtime

In my app the background color can be changed. Currently the LaunchScreen is just white and changes to the background color once the app has loaded. Is there any way that I can change the color that the LaunchScreen is going to have the next time the app starts. I know there is no way to run code while in the LaunchScreen, but maybe its image can be changed during runtime.
As said in the comment, it is impossible.

SKStoreProductViewController buttons displaying in White color

I am using SKStoreProductViewController in my app.Some times buttons are showing in white colour. how to change button colour to default colour.
Since SKStoreProductViewController is an OS view controller, it should have consistent presentation every time you open it (that's the case from my experience), unless if maybe you are open it from different OS versions.
Please describe what do you mean in "sometimes" - what are you doing different?

Why have my storyboards become transparent?

I'm sure I screwed something up here, but my storyboard backgrounds have all become transparent. Is there something I could have done to have done this accidentally? The color settings show that I have full opacity, so can anyone tell me why this is happening? I've done nothing programmatically, regarding the background. I'm using Xcode 6.3.1.

How to access the system selected menu item blue color?

I'm working on an app that has a custom NSView on a NSStatusBar which performs all of the drawing when the user clicks it. But here's the problem, the color I'm currently drawing as the view's background color is not the same as the system blue color.
My app's color:
Twitter's menu item color (system):
As you clearly see, my blue color is way lighter than the system. This is the code I'm currently using (and worked perfectly on versions older than Yosemite):
[[NSColor selectedMenuItemColor] set];
NSRectFill(rect);
I've even tried color picking the menu item's color but it seems like the color is affected by the wallpaper below the menu bar.
Any ideas on how to achieve the system look?
As you said, in Yosemite, docks, status bars etc. are affected by whatever is behind them. Try enabling System Preferences > Accessibility > Display > Reduce Transparency and you'll see what your color looks like without this feature./
Here is an idea - Maybe you should use the Vibrancy effect and derive from NSVisualEffectView. I knew that I've seen a very similar thread somewhere here in the past, and it took me quite some time to find it. Here it is:
Trouble matching the vibrant background of a Yosemite NSMenuItem containing a custom view
I think Matthes' answer to that question would lead you to the resolution of your issue. Be sure to check it out. I hope it will help - Good luck and report back!

Resources