ZKStatusBarNotification 1.2

ZKStatusBarNotification 1.2

测试已测试
多语言语言 SwiftSwift
许可证 MIT
发布时间最新发布2017 年 9 月
SwiftSwift 版本4.0
SPM支持 SPM

WangWenzhuang 维护。



  • 作者:
  • WangWenzhuang




可以在 iOS App 状态栏中轻松显示消息通知。

error
info
info

实现功能

  • 显示状态消息
  • 自定义(情景背景色、字体颜色、字体、自动消失间隔秒)

运行环境

  • iOS 8.0+
  • Xcode 8+
  • Swift 3.0+

安装

手动安装

  • ZKStatusBarNotification 文件夹拖动到您的项目中

快速开始

导入 ZKStatusBarNotification

import ZKStatusBarNotification

显示状态 -> 信息

ZKStatusBarNotification.showInfo("Star 一下吧")

显示状态 -> 成功

ZKStatusBarNotification.showSuccess("操作成功")

显示状态 -> 错误

ZKStatusBarNotification.showError("出现错误了")

自定义显示样式

设置字体

ZKStatusBarNotification.setFont(_ font: UIFont)

设置字体颜色

ZKStatusBarNotification.setTextColor(_ color: UIColor)

设置状态 -> 信息背景颜色

ZKStatusBarNotification.setInfoBackgroundColor(_ color: UIColor)

设置状态 -> 错误背景颜色

ZKStatusBarNotification.setErrorBackgroundColor(_ color: UIColor)

设置状态 -> 成功背景颜色

ZKStatusBarNotification.setErrorBackgroundColor(_ color: UIColor)

设置自动隐藏时间

ZKStatusBarNotification.setAutoDismissDelay(_ delay: Int)