Storyboard orientation Xcode 6.3 - xcode

I need to design an app in landscape mode. I selected the ViewController and went to the attribute inspector and selected the orientation to Landscape but the controller view in storyboard doesn't become in the landscape mode. Please suggest what I am doing wrong. I am using Xcode 6.3
Thanks

Since the size of view controller is freeform it doesn't rotate. If you can change the size of view controller, you can see it rotating.
Check this screenshot

Related

Xcode/Swift Adaptive Layout Issues

I am currently in the process of testing if my app works on both iphone and ipad and setting up the respective autolayout. For some reason on this particular viewcontroller, when I switch from iphone to ipad 9.7 the viewcontroller does not change the height and width of its view resulting in something that looks like this. Also, I am only having issues with this particular storyboard. The rest adjust their views to the correct size like they are supposed to .

How to incorporate a UISearchController into new (iOS8) UISplitviewController

I try to build a simple app based on the UISplitViewController template from Xcode 6 for universal apps (with Storyboard and CoreData/NSFetchedResultsController). This app should also provide a search bar for the MasterViewController. Unfortunately, Xcode 6 provides no InterfaceBuilder element for the UISearchBar/UISearchController combo (only the depreciated UISearchBar/UISearchDisplayController).
In the iOS Developer library, Apple provides the "Table Search with UISearchController" example, but this is not based on the UISplitViewController and supports only iPhone.
My problem is, that I'm not able to show the detail view on the correct ViewController under all circumstances. I tried to transfer the approach from the Apple example project to the UISplitViewController template. In this, one is encouraged to show the search results in a separate UITableViewController subclass (ResultsTableViewController) and use this as the searchResultsController of the UISearchController. I was not able to create a scene in InterfaceBuilder for this setup so I had to add these manually in code.
The problems begin when I click on a table cell of the ResultsTableViewController. This vc is not part of the scene in InterfaceBuilde and I don't know how to add it to the SplitViewController setting correctly. The biggest problem is the weird behavoir of the iPhone 6 Plus and the UISplitViewController. In portrait mode it behaves like an iPhone and doesn't seem to have a SplitViewController and only uses a NavigationController to which I push my DetailViewController. In landscape mode it behaves like an iPad with SplitViewController were I have to get the second ViewController of the SplitViewController childControllers and push the DetailViewController on this one.
Now it happens, when I start in portrait mode and switch to landscape mode that the DetailViewController is all gone, showing gray space where the DetailVC should be. It seems, when going to portrait mode, the DetailViewController gets kicked from the SplitViewController (or the SplitViewController gets kicked at all in favor for the iPhones NavigationController setup). When switching back to landscape the SplitViewController is initialized again but without proper initialization of the DetailViewController.
Is there any template or suggestion on how to correctly implement search capabilities on a universal UISplitViewController?
Cheers
Björn

iOS 7 force landscape on a UIViewController with UINavigationController

In my app I want one view controller to be shown in landscape because it is a signature pad. The rest of the views are portrait. I can force the view to be landscape without a problem as long as it is not embedded in a Navigation Controller. The problem is that I want the Navigation bar to show also. Does anyone know a workaround for this?
You can either present your view controller instead of push using UINavigationController (See kjam's solution in the following link) or you may try this solution of arpan_techisavy.

image position iOS 7 vs iOS 6

I have a background image issue for my app after I updated the project for iOS 7.
The app is navigation controller managed. I have a background image (UIImageView) created in IB. Since I place it a bit under the navigation menu I assume that the placement is calculated from the top of the view which in iOS 7 is beneath the Navigation Controller. When I run the app in iOS 6 the image is quite far down on the screen. Once again I assume this is because the top of the view in iOS 6 is below the Navigation Controller menu.
How do I fix so that the image has the same vertical distance from the navigation controller in iOS7 and iOS6?
Best regards
Frederik
iOS 7 brings several changes to how you lay out and customize the appearance of your UI. The changes in view-controller layout, tint color, and font affect all the UIKit objects in your app. In addition, enhancements to gesture recognizer APIs give you finer grained control over gesture interactions.
Please refer answer here.
One solution what I did is : I hooked background image to a reference from my xib, and set the frame programmatically from ViewDidLoad. It works fine.Please note that not forget to check iPhone 5 and iPhone 4 and set height to 568 and 480 respectively.

Xcode 4.5 "Apply retina 4 Form factor" toggle button not working properly

I'm trying to update an IOS app for IOS6 and iPhone 5, but I have a problem resizing some views from the main Storyboard.
When I click on the new "Apply Retina 4 Form Factor" button, some of the views included in the StoryBoard don´t resize. I´ve checked all the settings for every Scene and seem to be configured in the same way. Any idea? Thanks in advance.
You might have found your solution but I just had a similar problem. For future notice, I found the fix was in the show size inspector and instead of using layout rectangle, I used frame rectangle.
I was having the same problem, this answer worked for me and finally removed the letterbox:
https://stackoverflow.com/a/12927282/539149
So add a 640x1136 launch image called Default-568h#2x.png and set the "Retina (4-inch)" target setting to it. More info for the other sizes here:
http://www.idev101.com/code/User_Interface/launchImages.html
Just in case it helps others, I had tried these links and none of them got rid of the letterbox, but they did at least enable the resize masks:
Resize of UIViewController in storyboard
Xcode 4.5: can't set root view autoresizingMask in Interface Builder
how do you resize (visually, not programmatically) the detail view of a UISplitViewController in a storyboard?
iphone 5 and storyboard setting autoresizing masks

Resources