Latest 2.0.0
License MIT
Platforms ios 8.0

CI Status


To run the example project, clone the repo, and run pod install from the Example directory first.


To integrate the TAGKeyboard in your project follow the steps :-

  1. "import TAGKeyboard".
  2. extend your view controller with TAGKeyboard.
    class ViewController: TAGKeyboard {}
  3. Add the scroll view on your view and take the outlet to main viewcontroller.
  4. Implement the viewDidLoad() and call the super.viewDidLoad() and also set the delegate instance for respective text view and text fields.
  5. From your viewDidLoad set the
    scrollViewHolder = @your_scrollview

    @IBOutlet var baseScrollView: UIScrollView!

    override func viewDidLoad() {
      // "Do call the super"
      scrollViewHolder = baseScrollView
      testTextView.delegate = self
      testTextfield.delegate = self
  6. Now implement the respective delegates for text view and text field. "Do call the super of that particular method."
Example for text view delegates:-
override func textViewShouldBeginEditing(textView: UITextView) -> Bool {
    return (super.textViewShouldBeginEditing(textView))

override func textViewDidEndEditing(textView: UITextView) {

override func textViewDidBeginEditing(textView: UITextView) {
Example for text field delegates:-
override func textFieldShouldReturn(textField: UITextField) -> Bool {
    return (super.textFieldShouldReturn(textField))

override func textFieldDidBeginEditing(textField: UITextField) {

override func textFieldDidEndEditing(textField: UITextField) {
  1. If you are using following method then need to call the super of particular one. This method are implemented in TAGKeyboard class.

    1.1  If you want this method in your view then implement it in your view controller and call the parent func bu super.<br />
    main function:-
    <br />
    override public func viewDidLayoutSubviews() {
            screenSize = UIScreen.mainScreen().bounds
    1.2 To disappear the keyboard on orientation change implemented this method in TAGKeyboard class. 
    (Can by pass this method)

    override public func viewWillTransitionToSize(size: CGSize, withTransitionCoordinator coordinator: UIViewControllerTransitionCoordinator) {

    1.3 dismissKeyboard() :- called only view.endEditing(). But need to implemented by user on particular view.     <br />
  2. Also user need to implement the tap gesture on their view controller separately.


TAGKeyboard is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod 'TAGKeyboard', '~>2.0.0'


AbhishekThorat, [email protected]


TAGKeyboard is available under the MIT license. See the LICENSE file for more info.

Latest podspec

    "name": "TAGKeyboard",
    "version": "2.0.0",
    "summary": "To solve the text area and keyboard issue in iOS.",
    "description": "To integrate TAGKeyboard in your project you need to install the pod file. Then just extend the your class by TAGKeyboard, and implement the text feild and text view delegate on that view controller.",
    "homepage": "",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    "authors": {
        "AbhishekThorat": "[email protected]"
    "source": {
        "git": "",
        "tag": "2.0.0"
    "platforms": {
        "ios": "8.0"
    "source_files": "TAGKeyboard/Classes/**/*"

Pin It on Pinterest

Share This