Skip to content

gly/LCToast

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LCToast

Add toast to UIView.

Requirements

  • iOS 8.0+

Features

The following is a comparison of features with Toast and SVProgressHUD.

LCToast Toast SVProgressHUD
image position top center left center top center
superview any views any views UIWindow
automatic calculation text time interval
dismiss loading when toast shown
click the loading to dismiss it
modify center
progress
subtitle
queue
support for disabling superview interaction

Usage

show toast

[self.view lc_showToast:@"床前明月光,疑是地上霜。举头望明月,低头思故乡。"];
LCToastPositionTop LCToastPositionCenter LCToastPositionBottom
top center bottom

show image toast

[self.view lc_showToast:@"春种一粒粟,秋收万颗子。四海无闲田,农夫犹饿死。锄禾日当午,汗滴禾下土。谁知盘中餐,粒粒皆辛苦。" image:[UIImage imageNamed:@"warning"] position:(LCToastPositionCenter)];

show loading

[self.view lc_showLoading];

show progress

[self.view lc_showProgress:0.3];

Installation

CocoaPods

To integrate LCToast into your Xcode project using CocoaPods, specify it in your Podfile:

pod 'LCToast'

Manual

  1. Download everything in the LCToast folder;
  2. Add (drag and drop) the source files in LCToast to your project;
  3. Import UIView+LCToast.h.

License

LCToast is provided under the MIT license. See LICENSE file for details.

About

Add toast to UIView.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Objective-C 98.1%
  • Ruby 1.9%