IOS抗锯齿和程序启动时间设置

1.程序启动过程中各个阶段所消耗的时间

在工程的scheme中添加环境变量DYLD_PRINT_STATISTICS = 1,这样在调试时,可以在控制台打印出程序启动过程中各个阶段所消耗的时间。

2.抗锯齿的两种方法

第一种:

self.view.layer.allowsEdgeAntialiasing = YES;

第二种:

self.view.layer.borderColor = [UIColorclearColor].CGColor;

self.view.layer.borderWidth = 1.f;

3.调节UINavigationBar的leftBarButtonItem离左边的距离

UIBarButtonItem *buttonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"back-button-whiteArrow.png"] style:UIBarButtonItemStylePlain target:self action:@selector(logoutBarBtnPressed:)];

UIBarButtonItem *fixedBarButtonItem = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil];

fixedBarButtonItem.width = -15;

self.navigationItem.leftBarButtonItems = [NSArray arrayWithObjects:fixedBarButtonItem, buttonItem, nil];

©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容