Remove rounded corner of modal uinavigationcontroller
ios, ipad, presentmodalviewcontroller, uinavigationcontroller
Solution
VC.m
#import <QuartzCore/QuartzCore.h>
-(void)viewWillAppear:(BOOL)animated
{
[self.navigationItem setTitle:@"Navigationbar without corner"];
self.navigationController.view.layer.cornerRadius = 0;
}
Here is the result for above code
Problem
I'm presenting a UINavigationController modally. ``` _navigationController.modalPresentationStyle = UIModalPresentationFormSheet; ``` I want to show the modal controller with rounded corners. I tried this: Remove rounded corner for uiviewcontroller's view ipad It's working fine with UIViewControllers. For UINavigationController, I tried setting corner radius of navigation controller's view to 0. Also set corner radius of UIViews of all the UIViewControllers inside the UINavigationController. But nothing is working. Anyone have any idea how to do it??