zoukankan      html  css  js  c++  java
  • DEPRECATED方法 修改

    使用中经常会遇到,特意总结一下:

    原方法名 功能 摒弃版本 推荐方法 使用方式
    sizeWithFont 根据字体大小获取size iOS7.0 sizeWithAttributes

    参数Dictionary

    key:参考NSAttributeString.h

    例子

    NSMutableParagraphStyle* paragraphStyle = [[NSParagraphStyle defaultParagraphStyle] mutableCopy];

    paragraphStyle.lineBreakMode = NSLineBreakByClipping;

    paragraphStyle.alignment     = textAlignment;

    CGSize title1Size = [text sizeWithAttributes:@{NSFontAttributeName : font

    ,NSParagraphStyleAttributeName:paragraphStyle

    }];

    持续更新中    

        

  • 相关阅读:
    C#基础
    进制转换
    养猪和存储空间
    独热码和二进制码
    mux_xz
    饮料机
    亚稳态
    mos管功耗
    功能覆盖率和代码覆盖率
    时序逻辑电路输出特点
  • 原文地址:https://www.cnblogs.com/zhangrunchao/p/6008014.html
Copyright © 2011-2022 走看看