//按比例显示图片
UIImage *backGroundImage = [UIImage imageNamed:@”titleImage”];
backGroundImage = [backGroundImage resizableImageWithCapInsets:UIEdgeInsetsZero resizingMode:UIImageResizingModeStretch];
[self.navigationController.navigationBar setBackgroundImage:backGroundImage forBarMetrics:UIBarMetricsDefault];
---------------------
作者:曾三岁
来源:CSDN
原文:https://blog.csdn.net/zsansui/article/details/76083141
版权声明:本文为博主原创文章,转载请附上博文链接!