Latest 1.1.1
Homepage https://github.com/ZHIOSLIB/ZHSignatureView
License MIT
Platforms ios 8.0, requires ARC
Frameworks UIKit
Authors

电子签名

调用

SignViewController *signVC = [[SignViewController alloc] init];
[self.navigationController pushViewController:signVC animated:YES];
signVC.signResult = ^(UIImage *signImage) {
   self.signImageView.image = signImage;
};

初始化

如果要横屏,在横屏之后布局

CGSize size = UIScreen.mainScreen.bounds.size;
CGFloat navHeight = self.navigationController.navigationBar.frame.size.height;
self.navigationController.navigationBar.translucent = NO;
ElectronicSignView *sign = [[ElectronicSignView alloc] initWithFrame:CGRectMake(0, 0, size.width, size.height-navHeight)];
sign.lineColor = [UIColor blueColor];
sign.signDone = ^(UIImage *signImage) {
  self.signResult(signImage);
  [self.navigationController popViewControllerAnimated:YES];
};
[self.view addSubview:sign];

至于如何设置横屏,请下载demo查看

Latest podspec

{
    "name": "ZHSignatureView",
    "version": "1.1.1",
    "summary": "u7535u5b50u7b7eu540d",
    "description": "u7535u5b50u7b7eu540du5c01u88c5u6210u89c6u56feuff0cu4f7fu7528u7075u6d3b",
    "homepage": "https://github.com/ZHIOSLIB/ZHSignatureView",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "leezhihua": "[email protected]"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/ZHIOSLIB/ZHSignatureView.git",
        "tag": "1.1.1"
    },
    "source_files": "ZHSignatureView/Classes/*.{h,m}",
    "frameworks": "UIKit",
    "requires_arc": true
}

Pin It on Pinterest

Share This