美文网首页
Xcode代码块 Code Snippets

Xcode代码块 Code Snippets

作者: 微生物成长 | 来源:发表于2016-09-22 15:10 被阅读0次

    存储路径

    /Users/用户名/Library/Developer/Xcode/UserData/CodeSnippets

    <#占位符格式#>

    例:

    UIButton*replaceButton = [UIButtonbuttonWithType:UIButtonTypeCustom];

    replaceButton.tag = <#Value#>;

    replaceButton.frame = CGRectMake(<#CGFloat x#>, <#CGFloat y#>, <#CGFloat width#>, <#CGFloat height#>);

    [replaceButtonsetTitle:@"<#string#>"forState:UIControlStateNormal];

    [replaceButtonsetImage:[UIImageimageNamed:@"<#string#>"]forState:UIControlStateNormal];

    [replaceButtonsetBackgroundImage:[UIImageimageNamed:@"<#string#>"]forState:UIControlStateNormal];

    [replaceButton setTitleColor:[UIColor <#color#>] forState:UIControlStateNormal];

    [replaceButton setBackgroundColor:[UIColor <#color#>]];

    [replaceButton addTarget:selfaction:@selector(<#selector#>) forControlEvents:UIControlEventTouchUpInside];

    [<#view#> addSubview:replaceButton];

    相关文章

      网友评论

          本文标题:Xcode代码块 Code Snippets

          本文链接:https://www.haomeiwen.com/subject/rtdzettx.html