0

Issue with light mode in AirPrint(Swift). AirPrint Issue

Is there any way to change the colour of the navigation bar?

4

1 回答 1

0

请试试这个委托方法

- (UIViewController *)printInteractionControllerParentViewController: (UIPrintInteractionController *)printInteractionController
{
 return self.navigationController; 
} 
-(void)printInteractionControllerDidPresentPrinterOptions:(UIPrintInteractionController *)printInteractionController { 
// self.navigationController.topViewController.navigationController.navigationBar.tintColor=[UIColor redColor];
 self.navigationController.navigationBar.tintColor = [UIColor greenColor];
 // self.navigationController.topViewController.navigationController.navigationBar.barTintColor=[UIColor purpleColor];
 self.navigationController.topViewController.navigationController.navigationBar.tintColor=[UIColor yellowColor];
}
于 2021-03-29T12:16:30.660 回答