Answers for "swift uibutton title color doesnt change"

1

set color for uibutton programmatically swift

button.setTitleColor(.red, for: .normal)
Posted by: Guest on February-21-2020
1

swift how to change the header color

func tableView(tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
    let returnedView = UIView(frame: CGRectMake(x, y, width, height)) //set these values as necessary
    returnedView.backgroundColor = UIColor.lightGrayColor()

    let label = UILabel(frame: CGRectMake(labelX, labelY, labelWidth, labelHeight))
    label.text = self.sectionHeaderTitleArray[section]
    returnedView.addSubview(label)

    return returnedView
}
Posted by: Guest on December-20-2019

Code answers related to "swift uibutton title color doesnt change"

Code answers related to "Swift"

Browse Popular Code Answers by Language