Latest 0.1.7
Homepage https://github.com/MrDML/MLMenu
License MIT
Platforms ios 8.0
Authors

CI Status
Version
License
Platform

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Preview

Demo

Requirements!

iOS 8.0

Installation

MLMenu is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod 'MLMenu' / pod 'MLMenu', '~> 0.1.7'

Use

// 标题数组 必传
NSArray *titles = @[@"发起群聊",@"添加朋友",@"扫一扫",@"收付款"];
// 图片数组
NSArray *images = @[@"scan",@"scan",@"scan",@"scan"];

// 初始化一个带有三角形菜单控件
MLMenuView *menuView = [[MLMenuView alloc] initWithFrame:
CGRectMake([UIScreen mainScreen].bounds.size.width - 100 - 10, 0, 100, 44 * 4)
WithTitles:titles WithImageNames:images
WithMenuViewOffsetTop:k_StatusBarAndNavigationBarHeight
WithTriangleOffsetLeft:80];

// 设置覆盖层背景颜色 默认是透明
[menuView setCoverViewBackgroundColor:[UIColor lightGrayColor]];
// 提供block回调和代理回调
menuView.didSelectBlock = ^(NSInteger index) {
NSLog(@"%zd",index);
};
[menuView showMenuEnterAnimation:MLEnterAnimationStyleNone];

Other Use

// 设置线条颜色
menuView.separatorColor = [UIColor ...];
// 设置字体大小
menuView.font = [UIFont systemFontOfSize:...];
// 设置字体颜色
menuView.titleColor = [UIColor ...];
// 设置背景颜色
menuView.backgroundColor = [UIColor ...];

Author

MrDML, [email protected]

License

MLMenu is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "MLMenu",
    "version": "0.1.7",
    "summary": "A Simple MLMenu.",
    "description": "WeChat QQ top right menu option function.",
    "homepage": "https://github.com/MrDML/MLMenu",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "MrDML": "[email protected]"
    },
    "source": {
        "git": "https://github.com/MrDML/MLMenu.git",
        "tag": "0.1.7"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source_files": "MLMenu/Classes/**/*"
}

Pin It on Pinterest

Share This