WangGuibin / WGBEasyMarqueeView

简易的跑马灯功能,支持pod集成 OC版

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

WGBEasyMarqueeView

Example

    WGBEasyMarqueeView *marqueeView = [[WGBEasyMarqueeView alloc] init];
    marqueeView.backgroundColor = [UIColor lightGrayColor];
    marqueeView.contentMargin = 50;
    marqueeView.speed = 1.5f;
    [self.view addSubview: marqueeView];
    if (self.marqueeType != 3) {
        marqueeView.marqueeType = self.marqueeType;
        marqueeView.contentView = self.label;
    }else{
        marqueeView.marqueeType = WGBEasyMarqueeTypeReverse;
        marqueeView.contentView = self.customView;
    }
    self.marqueeView = marqueeView;
}

- (void)viewDidLayoutSubviews{
    [super viewDidLayoutSubviews];
    self.marqueeView.bounds = CGRectMake(0, 0, 300 , 60);
    self.marqueeView.center = self.view.center;
}

更具体使用例子可参考demo

swift版本 请前往

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

Requirements

Installation

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

pod 'WGBEasyMarqueeView'

Author

Wangguibin, 864562082@qq.com

License

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

About

简易的跑马灯功能,支持pod集成 OC版

License:MIT License


Languages

Language:Objective-C 93.5%Language:Ruby 6.5%