Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import UIKit
- @IBDesignable class CustomBorderView: UIView {
- @IBInspectable var cornerRadius: CGFloat = 0{
- didSet{
- self.layer.cornerRadius = cornerRadius
- }
- }
- @IBInspectable var borderWidth: CGFloat = 0 {
- didSet{
- self.layer.borderWidth = borderWidth
- }
- }
- @IBInspectable var borderColor: UIColor = UIColor.clear{
- didSet{
- self.layer.borderColor = borderColor.cgColor
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement