title: UITextfield text color is not changing while not in focus
body: <p>So I have two <code>UITextFields</code>: name and amount and two <code>UIButtons</code>: income, expense.<br>
  When I press the expense button I want my <code>amount</code> textfield color to change to red or green if income button is pressed. </p>
  
  <p>This only works if <code>amount</code> textfield is in focus, if <code>name</code> textfield is in focus, the color is not changed for amount.  </p>
  
  <p>Is there a way to change the color of the textfield if it's not in focus ?</p>
  
  <p>edit:</p>
  
  <p>Here is my code where I change the color:</p>
  
  <pre><code>@IBAction func typeBtnPressed(_ sender: UIButton) {
      if sender.tag == Buttons.expense.rawValue {
          amountTxt.textColor = .red
      } else {
          amountTxt.textColor = .green
      }
  }
  </code></pre>