- Number of license segments
- Number of characters in a segment
- Placeholder character
- (Optional) Highlighting if the licence key is invalid
[DSFLicenseKeyControlView createWithName:@"Eight by Three License Key"
segmentCount:3
segmentSize:8
key:@"ABCDEFGH-IJKLMNOP-QRSTUVWX"];
DSFLicenseKeyControlView.create(withName: "Eight by Three License Key",
segmentCount: 3,
segmentSize: 8,
key: "ABCDEFGH-IJKLMNOP-QRSTUVWX")
[DSFMutableLicenseKeyControlView createMutableWithName:@"Four by Six License Key"
segmentCount:4
segmentSize:6
key:@"123456-ABCDEF-CATDOG-NOODLE"];
DSFMutableLicenseKeyControlView.createMutable(withName: "Four by Six License Key",
segmentCount: 4,
segmentSize: 6,
key: "123456-ABCDEF-CATDOG-NOODLE")
These provide interface builder inspectables, so that you can :-
- Configure your license key field within IB
- Preview your license key directly in your view
Use Interface Builder to build your views live
- Tab between the fields in your license key
- When a field is filled, moves automatically to the next field
You can copy and paste your license key into a field, and if the copied key matches the settings, will properly fill the fields
Comes with Voiceover support out-of-the-box, meaning that your visually impaired users can use your app straight away.
Uses RSVerticallyCenteredTextFieldCell
by Daniel Jalkut of Red Sweater Software