# HwwCreateManager **Repository Path**: fengye12538/HwwCreateManager ## Basic Information - **Project Name**: HwwCreateManager - **Description**: 模仿Masonry自定义所有的UI控件设置属性:UIlabel、UITextFile、UIScorllView、UITableView...... - **Primary Language**: Objective-C - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-03-07 - **Last Updated**: 2020-12-18 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # HwwCreateManager [![CI Status](https://img.shields.io/travis/2297711051@qq.com/HwwCreateManager.svg?style=flat)](https://travis-ci.org/2297711051@qq.com/HwwCreateManager) [![Version](https://img.shields.io/cocoapods/v/HwwCreateManager.svg?style=flat)](https://cocoapods.org/pods/HwwCreateManager) [![License](https://img.shields.io/cocoapods/l/HwwCreateManager.svg?style=flat)](https://cocoapods.org/pods/HwwCreateManager) [![Platform](https://img.shields.io/cocoapods/p/HwwCreateManager.svg?style=flat)](https://cocoapods.org/pods/HwwCreateManager) ## Example To run the example project, clone the repo, and run `pod install` from the Example directory first. ## Requirements ## Installation HwwCreateManager is available through [CocoaPods](https://cocoapods.org). To install it, simply add the following line to your Podfile: ```ruby pod 'HwwCreateManager' #import "ViewController.h" #import "UILabel+hwwcreate.h" @interface ViewController () @end @implementation ViewController - (void)viewDidLoad { [super viewDidLoad]; UILabel *testlb = [[UILabel alloc]init]; [testlb hww_createLabelWithManager:^(HwwCreateManager * _Nonnull manager) { manager.test(@"测试文本内容").testColor([UIColor redColor]) .font([UIFont systemFontOfSize:16]) .textAlignment(NSTextAlignmentLeft) .backgroundColor([UIColor greenColor]) .borderWidth(1) .borderColor([UIColor blueColor]) .frame(CGRectMake(100, 300, 200, 200)) .shadowOffset(CGSizeMake(5, 5)) .shadowColor([UIColor grayColor]) .lineBreakMode(NSLineBreakByCharWrapping) .numberOfLines(0); }]; [self.view addSubview:testlb]; UIImageView *imageView = [[UIImageView alloc]init]; [imageView hww_createImageViewWithManager:^(HwwCreateManager * _Nonnull manager) { manager.image([UIImage imageNamed:@"bootpage1"]) .frame(CGRectMake(100, 64, 200, 300)) .borderWidth(1) .borderColor([UIColor blackColor]) .cornerRadius(10) .backgroundColor([UIColor redColor]) .contentMode(UIViewContentModeScaleAspectFit); }]; [self.view addSubview:imageView]; UIButton *button = [[UIButton alloc]init]; [button hww_createButtonWithManager:^(HwwCreateManager * _Nonnull manager) { manager.title(@"点我",UIControlStateNormal) .titlecolor([UIColor redColor],UIControlStateNormal) .titlecolor([UIColor grayColor],UIControlStateHighlighted) .backgroundColor([UIColor greenColor]) .cornerRadius(5) .borderWidth(1) .borderColor([UIColor blackColor]) .frame(CGRectMake(100, 600, 100, 30)) .target(NSStringFromSelector(@selector(buttontest)),self,UIControlEventTouchUpInside); }]; [self.view addSubview:button]; UITextField *textfield = [[UITextField alloc]init]; [textfield hww_createTextFieldWithManager:^(HwwCreateManager * _Nonnull manager) { manager.placeholder(@"123").testColor([UIColor redColor]) .frame(CGRectMake(100, 100, 100, 30)) .clearButtonMode(UITextFieldViewModeAlways) .borderStyle(UITextBorderStyleRoundedRect) .secureTextEntry(YES) .autocorrectionType(UITextAutocorrectionTypeYes) .keyboardType(UIKeyboardTypeNumberPad) .clearsOnBeginEditing(YES) .adjustsFontSizeToFitWidth(YES) .minimumFontSize(10) .returnKeyType(UIReturnKeySend) .keyboardAppearance(UIKeyboardAppearanceDark); }]; [self.view addSubview:textfield]; ![输入图片说明](https://images.gitee.com/uploads/images/2020/0307/182858_bc5be843_2072965.png "屏幕截图.png") } ``` ## Author 2297711051@qq.com, 2297711051@qq.com ## License HwwCreateManager is available under the MIT license. See the LICENSE file for more info.