CHRealHideUIView 2.0.0

CHRealHideUIView 2.0.0

TestsTested βœ—
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Dec 2016
SwiftSwift Version 3.0
SPMSupports SPM βœ—

Maintained by Calvin Huang.




  • By
  • Calvin

CHRealHideUIView

Snapshot

snapshot

About

When hidding the view, we expect the hidden view will not leave blank space.
For example there are two views => πŸΆπŸ˜„πŸ±, hide πŸ˜„ should be 🐢🐱␣ , however in iOS will be 🐢␣🐱.
Even view don’t draw, auto layout will retain their frame.
CHRealHideUIView help you hide views and will not leave blank space.

Usage

You can hide and show views very easy, just hide(view) or show(view).

class ViewController: UIViewController {
    @IBOutlet weak var view: UIView!

    @IBAction func toggleHideAndShowButtonClicked(_: AnyObject) {
        if (view.hidden) {
            show(view)
        } else {
            hide(view)
        }
    }
}

License

Copyright Β© Calvin Huang. This software is licensed under the MIT License.