I've created a sub class of UITableViewController named LoginViewController with the XIB file using XCode. Then I opened the XIB file with IB and set the table's style to grouped. Finally I wrote the following code:
- (void)applicationDidFinishLaunching:(UIApplication *)application {
LoginViewController *loginViewController = [[LoginViewController alloc] initWithNibName:@"LoginViewController" bundle:[NSBundle mainBundle]];
[window addSubview: loginViewController.view];
window.backgroundColor = [UIColor blueColor];
[window makeKeyAndVisible];
[window layoutSubviews];
}
I set the window's background color to blue for you to see what the problem is. I put a link to the screenshot
As you can see in the screenshot the table view is not display correctly because a margin between the bottom of the main window and the table view is being set and I don't know why.
If I don't use the table style grouped the problem does not occur