#APESuperHUD A simple way to display a HUD with a message or progress information in your application.
##Features
- Simplicity.
- Customizable. See Change appearance.
- Fully written in Swift.
- Unit tests.
##Requirements
- iOS 8 or later.
- Xcode 7 or later.
##Installation
####CocoaPods
You can use CocoaPods to install APESuperHUD
by adding it to your Podfile
:
platform :ios, '8.0'
use_frameworks!
target 'MyApp' do
pod 'APESuperHUD', :git => 'https://github.com/apegroup/APESuperHUD.git'
end
Note that this requires CocoaPods version 36, and your iOS deployment target to be at least 8.0:
####Carthage
You can use Carthage to install APESuperHUD
by adding it to your Cartfile
:
github "apegroup/APESuperHUD"
##Usage Don't forget to import.
import APESuperHUD
####Show message HUD ######With default icon
APESuperHUD.showOrUpdateHUD(.Email, message: "1 new message", duration: 3.0, presentingView: self.view, completion: { _ in
// Completed
})
######With custom image
APESuperHUD.showOrUpdateHUD(UIImage(named: "apegroup")!, message: "Demo message", duration: 3.0, presentingView: self.view, completion: { _ in
// Completed
})
####Show HUD with loading indicator ######With loading text
APESuperHUD.showOrUpdateHUD(.Standard, message: "Demo loading...", presentingView: self.view, completion: nil)
######Without loading text
APESuperHUD.showOrUpdateHUD(.Standard, message: "", presentingView: self.view, completion: nil)
######With funny loading texts
APESuperHUD.showOrUpdateHUD(.Standard, funnyMessagesLanguage: .English, presentingView: self.view, completion: nil)
####Remove HUD
APESuperHUD.removeHUD(animated: true, presentingView: self.view, completion: { _ in
// Completed
})
####Change appearance
APESuperHUD.appearance.cornerRadius = 12
APESuperHUD.appearance.animateInTime = 1.0
APESuperHUD.appearance.animateOutTime = 1.0
APESuperHUD.appearance.backgroundBlurEffect = .None
APESuperHUD.appearance.iconColor = UIColor.greenColor()
APESuperHUD.appearance.textColor = UIColor.greenColor()
APESuperHUD.appearance.loadingActivityIndicatorColor = UIColor.greenColor()
APESuperHUD.appearance.defaultDurationTime = 4.0
APESuperHUD.appearance.cancelableOnTouch = true
APESuperHUD.appearance.iconWidth = 48
APESuperHUD.appearance.iconHeight = 48
APESuperHUD.appearance.fontName = "Caviar Dreams"
APESuperHUD.appearance.fontSize = 14
##Contributing All people are welcome to contribute. See CONTRIBUTING for details.
##License APESuperHUD is released under the MIT license. See LICENSE for details.