Custom @IBDesignable button for Interface Builder that doesn't require any coding.
- uses Interface Builder
- wire up like standand button
- IBDesignable styles for: round or square, flat or raised
- IBDesignable elements for color, text, text-size
- glow feedback
- optional image
- Xcode 6.1
- iOS 8.0+
NOTE: demo uses 8.0 & ios 9
- Copy JGTapButton.swift class to your Xcode Project
- Drag a UIView and assign JGTapButton as class for each button
- For each JGTapButton use the Attributes Inspector to modify the default IBInspectable elements as desired:
- Round On for round button or Off for square
- Raised On for raised style or Off for flat
- Title caption
- Optional image
- Button color
- Font size
- Font color
- Use the Connections Inspector to wire the Touch Up Inside event in your Storyboard or to an @IBAction in your code
Demo example is included.
Demo icons adapted from Shali Nguyen (http://shalinguyen.github.io/socialicious/)