Sample Header Ad - 728x90

How do I add preview devices to Interface Builder in Xcode to retrieve the device's code?

2 votes
1 answer
8100 views
Is there any way to add devices to the selection in the lower left corner? enter image description here I want to add the iPad Air and iPad Mini, so that I can view their ID (e.g. for iPhone 4 "retina3_5") when I view the .xib file as code. ---------- My actual problem is that I am generating .xib files from a model and don't want Xcode to be asking like this Xcode asking for an initial device for an initial device when viewing the generated view in Xcode. The only and therefore initial device for this view is set in the model. I already added the following lines which set the initial device: The only problem is that I don't know the identifiers for iPad Air and iPad Mini. I know their resolution is the same as that of the iPad Pro 9.7" so I might as well just use the ID of the Pro but that doesn't feel completely right. Any suggestions? I already spent a lot of time on searching how to add devices (the only suitable answer I found said press + in the lower left corner, but there is none for me) and for the keys of i-devices but without luck. Apple seems not have documented the xib-format at all.
Asked by Florian Blume (123 rep)
Feb 21, 2017, 03:55 PM
Last activity: Feb 22, 2017, 09:35 AM