Latest 0.0.5
License MIT
Platforms ios 8.0, requires ARC
Dependencies MBProgressHUD
Frameworks UIKit, Foundation

Pod Version
Pod Platform
Pod License
Carthage compatible

MBHUD is a clean and easy-to-use HUD meant to display the progress of an ongoing task on iOS.
MBHUD depends on the MBProgressHUD, it is standing on the shoulders of giants, simple encapsulation of MBProgressHUD.
In this to pay tribute to the MBProgressHUD.



From CocoaPods

CocoaPods is a dependency manager for Objective-C, which automates and simplifies the process of using 3rd-party libraries like MBHUD in your projects. First, add the following line to your Podfile:

pod 'MBHUD'

If you want to use the latest features of MBHUD use normal external source dependencies.

pod 'MBHUD', :git => ''

This pulls from the master branch directly.

Second, install MBHUD into your project:

pod install


Even though MBHUD is written in Objective-C, it can be used in Swift with no hassle. If you use CocoaPods add the following line to your Podfile:


If you added MBHUD manually, just add a bridging header file to your project with the MBHUD header included.


(see sample Xcode project in /Demo)

MBHUD is created as a singleton (i.e. it doesn’t need to be explicitly allocated and instantiated; you directly call [MBHUD method]).

Use MBHUD wisely! Only use it if you absolutely need to perform a task before taking the user forward. Bad use case examples: pull to refresh, infinite scrolling, sending message.

Using MBHUD in your app will usually look as simple as this (using Grand Central Dispatch):

[MBHUD showLoading:nil onView:nil];
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
    // time-consuming task
    dispatch_async(dispatch_get_main_queue(), ^{
        [MBHUD hid];


MBHUD can be customized via the following methods:

 设置 MBProgressHUDBackgroundStyle 为 Blur
+ (void)setHUDBackgroundStyleBlur;

 设置 MBBackgroundView 的 color

 @param color UIColor
+ (void)setHUDBackgroundViewColor:(UIColor *)color;

 设置 BezelView 的颜色

 @param color UIColor
+ (void)setHUDBezelViewColor:(UIColor *)color;


 @param color UIColor
+ (void)setHUDContentColor:(UIColor *)color;

 设置 HUD 内容边距

 @param margin margin
+ (void)setHUDMargin:(CGFloat)margin;

 设置 HUD 最小尺寸

 @param minSize minSize
+ (void)setHUDMInSize:(CGSize)minSize;

 让SuperView响应操作,即禁用HUD的 userInteractionEnabled = NO
+ (void)superViewUserInteractionEnabled;


This code is distributed under the terms and conditions of the MIT license.

Latest podspec

    "name": "MBHUD",
    "version": "0.0.5",
    "summary": "u7ad9u5728u5de8u4ebau7684u80a9u4e0auff0cMBProgressHUD u7b80u5355u5c01u88c5",
    "description": "Let MBProgressHUD tu use simple",
    "homepage": "",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    "authors": {
        "qyfeng": "[email protected]"
    "platforms": {
        "ios": "8.0"
    "source": {
        "git": "",
        "tag": "0.0.5"
    "source_files": "MBHUD/**/MBHUD.{h,m}",
    "resources": "MBHUD/MBHUD/MBHUD.bundle",
    "frameworks": [
    "requires_arc": true,
    "dependencies": {
        "MBProgressHUD": []

Pin It on Pinterest

Share This