Latest 1.4
Homepage https://github.com/ChanggnahC/CHButton
License MIT
Platforms ios 7.0, requires ARC
Authors

CocoaPods

pod 'CHButton', '~> 1.4'

CHButton

示例:

一个参数改变图片位置:
button.imageMode = CHImageModeRight;

设置图片和文字间距:
button.imageTitleRange = 10;

block实现点击事件:

;

角标:

/**
 * 角标显示的信息,可以为数字和文字<br>
 */
@property (nonatomic) NSString *badgeValue;
/**
 * 角标背景颜色,默认为红色
 */
@property (nonatomic) UIColor *badgeBGColor;
/**
 *  角标文字的颜色
 */
@property (nonatomic) UIColor *badgeTextColor;
/**
 *  角标字号
 */
@property (nonatomic) UIFont *badgeFont;
/**
 *  角标的气泡边界
 */
@property (nonatomic) CGFloat badgePadding;
/**
 *  角标的最小尺寸
 */
@property (nonatomic) CGFloat badgeMinSize;
/**
 *  角标的x值
 */
@property (nonatomic) CGFloat badgeOriginX;
/**
 *  角标的y值
 */
@property (nonatomic) CGFloat badgeOriginY;
/**
 *  当角标为0时,自动去除角标
 */
@property BOOL shouldHideBadgeAtZero;

感谢您的star ^ _ ^

Latest podspec

{
    "name": "CHButton",
    "version": "1.4",
    "platforms": {
        "ios": "7.0"
    },
    "summary": "A delightful setting interface framework.",
    "homepage": "https://github.com/ChanggnahC/CHButton",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "chang": "[email protected]"
    },
    "social_media_url": "https://www.jianshu.com/u/230f674988cc",
    "source": {
        "git": "https://github.com/ChanggnahC/CHButton.git",
        "tag": 1.4
    },
    "source_files": "CHButtonDemo/CHButton/CHButton.{h,m}",
    "requires_arc": true
}

Pin It on Pinterest

Share This