iPhone simulator just shows a white screen in XCode - xcode

Just downloaded the latest version of xcode. I'm a newbie and will appreciate any help I can get. I created a pretty basic app using the storyboard feature. It has 1 table view (with 3 rows; listed as red, blue, and green) and then when you click the red row it 'should' takes you to another screen where it tells you all about the color red in a text view window. However, when I go to launch the iphone simulator it just shows a white screen. I'm going to assume that I can't use the storyboard feature as a full blown creator and I'm going to need to add some code somewhere?

Related

Background color of tabbar and alert messages are bright yellow after xcode update

I updated my xcode to 12.3 and it changed the background colors to bright yellow on Navigation Tab bar and alertviews.
I have them set to default colors and that appears to be light grey. The text and images remain black but I noticed that one of the images has gone to full color. Very weird.
Also the background color of the entire simulator, even the App Settings page, has turned bright yellow. I can change colors in the inspector panel (though the text tint does not change, always white) and it changes it on the xib screen but the simulator still shows the bright yellow background with the correct blue if selected and dark gray if not selected images and text.
The change effected every tab bar in the app. When run on actual device, the colors are normal. Translucent is checked. When unchecked the background color appears white.
Anyone give me advice on what to do here?
I ran into the same issue after install xcode 12.3. This is how to fix the issue.
Certain parts of the screen appear yellow in Interface Builder and the simulator.
First do this...
Open your Simulator and go to File > GPU Selection > Prefer Integrated GPU in
Then do this...
Quit Xcode and simulator
Unplug power cable
Restart Xcode and simulator
Check storyboard or simulator to confirm yellow tint is gone
Reconnect in power cable
Worked for me. Good luck
MacOS had an update and after I installed that, the colors reverted to normal.

Xcode preview changing even after pinning it

I have the Canvas preview open and auto-refreshing the view that I am working on.
When I click on the pin in the bottom left corner, it fills with blue, giving me the impression that it's been pinned. But, when I navigate to a different view, that view is then previewed and the pin in the bottom left is still highlighted blue.
I'm currently worthing within Xcode 11.5.
I've experienced the same issue on the, as of writing, latest Xcode 12.4. After messing around with it, I've been able to figure it out; the trick is to make sure that at the time of pinning, the live preview is off. Then pin, change previews, and voila.

Xcode: How to show Preview in separate window instead of showing in Assistant editor?

When I'm making edits in storyboard I know how to show the preview in the assistant editor (as shown in the below screen shot).
How to show the preview in a separate window, so that I'll be able to drag it to my the screen attached to my computer?
UPDATE: Adding few more images to clarify what is the "Storyboard Preview":
In XCode 7 I managed to do this by selecting File -> New window, then adding a preview-part teh same way you illustrate above. I then drag it to my secondary screen resize everything to give a good preview of the screen sizes I want.

Xcode iPad simulator keyboard opens in middle of screen

I am running xcode 4.3.2 and just started having the following problem.
All projects running in the simulator are positioning the popup keyboard in the center of the IPAD simulator. The IPHONE simulator is fine with the normal keyboard positioned at the bottom of the screen. Even a simple new project with a single text field shows the keyboard in the middle of the screen with equal amounts of white space above and bellow. This occurs in all orientations.
Interestingly, UIPickerViews also exhibit the same behavior.
This is driving me nuts, as it has been fine for many months and now all the objects (text fields etc.) are hidden when the keyboard plops down smack in the middle of the screen.
Please help. Thanks in advance.
Tom
This is a feature of the iPad. You can "drag" the keyboard with the drag handle in the lower-right hand corner of the keyboard. The image from this blog post by Rob Rogers indicates how to use it. My guess is you inadvertently moved your keyboard.

Xcode 4 and iPad2 splash screen issue

Thank you for reading this.
I created a brand new project in Xcode 4 (Window based kind) and tried to get the splash screens working.
If I click on the blue icon of my project (top of the project hierarchy) and then click on "Target/Project", I see that I can drag and drop two launch images to use them as splash screens.
My portrait picture is a 768 x 1004 px png file and my landscape picture is a 1024 x 748 png file.
When I drop the portrait picture, everything looks fine but when I do the same with the landscape picture, I have a big yellow exclamation point that appears.
If I hover my mouse pointer long enough on the exclamation point, it says:"
the size of the launch image for iPad in landscape mode does not match
the recommended size of 1024 x 748 pixels
".
Just to be sure, I verified in Photoshop and a mac buit-in application and both do say my image is a png file of 1024 x 748.
I tried another picture and got the same message. I created a new Xcode project and also got the same message.
When I build and run the minimalistic project in the iPad simulator, I get the portrait splash vertically in Portrait orientation (ok) and the portrait splash horizontally in Landscape mode (not ok).
What can I do?
Just for you to know:
When I go to the Project-Info.plist, I do see "Supported Interface Orientations (iPad)" and it has 4 items:
Portrait (Bottom home button)
Portrait (top home button)
Landscape (left home button)
Landscape (right home button)
I also copied manually the 5 following files at the root of the project but it didn't help
Default-Landscape~ipad.png
Default-Portrait~ipad.png
Default-LandscapeLeft~ipad.png
Default-LandscapeRight~ipad.png
Default-PortraitUpsideDown~ipad.png
Whatever I do, it just recognizes the portrait picture and uses them for each orientation...
At this point, my project is very minimal and is just made of an appDelegate "h" and "m" file and a "mainWindow.xib" file, that's it (I didn't edit any of them yet).
Any clue?
Thank you.
Edit: try making the image 748x1024 instead of 1024x748 as suggested here.
From SO question - iPad Launch image landscape:
If you're on Xcode 4.0.2+ then the landscape iPad launch image needs
to be 748 * 1024. This is how it works in one of my apps.
Also, Upgrading to xcode 4.1 will fix the big yellow warning you get even when an image is the correct size.
The warning is also different based on your plist setting for "Status Bar is initially hidden" or not. If it's hidden, then it needs to be 1024x768, it not hidden then 1024x748... etc.

Resources