dig

DigitalKeyboard

手动实现简单的身份证数字键盘

Showing:

Popularity

Downloads/wk

0

GitHub Stars

100

Maintenance

Last Commit

3yrs ago

Contributors

3

Package

Dependencies

0

License

MIT

Categories

Readme

DigitalKeyboard

CI Status Version Platform

DigitalKeyboard

A custom digital keyboard for idcard

👀 See also:

dititalkeyboard_display

CocoaPods

CocoaPods is a dependency manager for Cocoa projects. You can install it with the following command:

$ gem install cocoapods

CocoaPods 0.39.0+ is required to build IDCardKeyboard 3.0.0+.

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

Swift 2.2:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'
use_frameworks!

target '<Your Target Name>' do
    pod 'IDCardKeyboard', '~> 1.0.8'
end

Swift 2.3:

    pod 'IDCardKeyboard', :git => 'https://github.com/CNKCQ/DigitalKeyboard.git', :branch => 'Swift2.3'

Swift 3.0:

     pod 'IDCardKeyboard', '1.2.6'

Swift 4.0:

    pod 'DigitalKeyboard'

Then, run the following command:

$ pod install

Carthage

    github "CNKCQ/DigitalKeyboard"   

📖 Usage

import UIKit

class ViewController: UIViewController {
  
  override func viewDidLoad() {
      super.viewDidLoad()
      // Do any additional setup after loading the view, typically from a nib.
      view.backgroundColor = UIColor.orange
      let textField = UITextField(frame: CGRect(x: 100, y: 120, width: 200, height: 35))
      textField.borderStyle = .roundedRect
      view.addSubview(textField)
      let keyboard = DigitalKeyboard(view: view)
      keyboard.style = .Number
      keyboard.customDoneButton(title: "hello", titleColor: UIColor.blue, theme: UIColor.green)
      textField.inputView = keyboard
      textField.becomeFirstResponder()
  }
  
  override func didReceiveMemoryWarning() {
      super.didReceiveMemoryWarning()
      // Dispose of any resources that can be recreated.
  }
}

  🔑 Basics Swift 2.2、Swift 3.0、Swift4.0

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100