UIButton

class UIButton : UIControl, NSCoding
  • 设置背景颜色

    Declaration

    Swift

    public func setBackgroundColor(color: UIColor, for forState: UIControl.State)

    Parameters

    color

    color

    forState

    Button状态