     func createButton(dataObject: TabDataObject, atIndex index: Int) {
         let button = TabButton(index: index, dataObject: dataObject)
         button.delegate = self
-        button.selectedColor = accentColor
-        button.unselectedColor = defaultTitleColor
+        button.selectedColor = tintColor
+        button.unselectedColor = textColor
         stackView.addArrangedSubview(button)
         buttons.append(button)
     }

    
    // MARK: - Inspectable properties
    
    @IBInspectable public var underlineHeight: CGFloat = 2.0 {
        didSet {
            underlineHeightConstraint?.constant = underlineHeight
        }
    }
    
    @IBInspectable public var underlineOnBottom: Bool = true {
        didSet {
            configureVerticalPositions()
        }
    }
    
    @IBInspectable public var selectedIndex: Int = 0 {
        didSet {
            updateTabs()
        }
    }
    
    @IBInspectable public var accentColor: UIColor = UIColor.blueColor() {
        didSet {
            updateColors()
        }
    }
    
    @IBInspectable public var defaultTitleColor: UIColor = UIColor.blackColor() {
        didSet {
            updateColors()
        }

    }
    
    func configureVerticalPositions() {
        if underlineTop {
            underlineBottomConstraint?.active = false
            underlineTopConstraint?.active = true
        } else {
            underlineBottomConstraint?.active = true
            underlineTopConstraint?.active = false
        }
        
        let shadowHeight = 0.5
        let shadowWidth = 0.0

        let shadowOffset: CGSize
        if shadowTop {
            shadowOffset = CGSize(width: shadowWidth, height: -shadowHeight)
        } else {
            shadowOffset = CGSize(width: shadowWidth, height: shadowHeight)
        }
        
        layer.shadowOffset = shadowOffset
