SFNotify 0.0.2

SFNotify 0.0.2

测试测试
语言语言 Objective-CObjective C
许可 MIT
发布上次发布2014年12月

未申明的用户维护。



SFNotify 0.0.2

简单的自定义用户通知

基于andreamazz / UIView-Notify

安装

  • 将文件夹SFNotify复制到您的项目中。

用法

导入SFNotify.h

  • 默认通知
    NSString *yourMessage = [NSString stringWithFormat:@"This is the:\nSFNotify"];  //Change the text

    [self.view notify:yourMessage
        withDirection:DEFAULT_DIRECTION
  withBackgroundColor:DEFAULT_COLOR_BACKGROUND
             withFont:DEFAULT_FONT
        withTextColor:DEFAULT_TEXT_COLOR
         withDuration:DEFAULT_TIME_DURATION];
  • 自定义通知
    NSString *yourCustomMessage = [NSString stringWithFormat:@"This is the custom:\nSFNotify\n\nFeel free to modify whatever you want"];  //Change the text

    [self.view notify:yourCustomMessage
        withDirection:DIRECTION_LEFT_TO_RIGHT  //Custom direction
  withBackgroundColor:[UIColor blackColor] //Custom notify background color
             withFont:[UIFont fontWithName:@"menlo" size:12] //Custom font
        withTextColor:[UIColor whiteColor] //Custom font color
         withDuration:4.0]; //Custom duration

屏幕

Demo DEFAULT

Demo DIRECTION_BOTTOM_TO_TOP

Demo DIRECTION_LEFT_TO_RIGHT