BMXFlatButton
A couple of Swift UIButton with a flat appearance, released as a Cocoa Touch Framework. The framework contains two button types: FlatButton and CircularButton. The first is a squared button with optional rounded corners and border; you can tweak the colors to obtain a filled or outlined style. The circular button is a circle shaped button intended to be used without a title; it also can have a optional border.
For a complete example see the enclosed BMXFlatButtonTestproject.
Features
- designable in Interface Builder
- customizable highlighted color (defaults to normal color but 2% darker)
- customizable border size and color
- customizable corner radius (only for
FlatButton)
Usage
- Add
BMXFlatButtonframework to project inProject > General > Linked Frameworks and Libraries. - Set Custom Class in Identity Inspector. Choose
FlatButtonfor flat squared buttons orCircularButtonfor circular buttons.
- Configure the button properties as required in Attribute Inspector.
Notes
- Xcode 6 beta 4 fixed the issues below
- Xcode 6 beta 3: issue below is fixed but to compile the test project you'll need to apply this fix.
- Xcode 6 beta 2: due to a Interface Builder limitation, the Custom Class Class field does not show the
FlatButtonandCircularButtonoptions in the selection box, you'll need to write them manually.
Contact
On this page
Contributors
MIT License
Created July 5, 2014
Updated February 23, 2025



