Removing the highlight in a selected UIButton
<p>A normal UIButton should look like this (I understand that button are supposed to have different colours from other text, but that this is a special case):</p>

<p><a href="https://i.stack.imgur.com/vkT6I.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vkT6I.png" alt="enter image description here"></a></p>

<p>I wanted to use the <code>selected</code> property of a UIButton to determine whether it should be bold or not, and I already set the <code>.Selected</code> control state to have bold text with the following code:</p>

<pre><code>let boldedOption = [NSFontAttributeName: UIFont.boldSystemFontOfSize(15), NSForegroundColorAttributeName: UIColor.whiteColor()]
signInButton.setAttributedTitle(NSAttributedString(string: "SIGN IN", attributes: boldedOption), forState: .Selected)
</code></pre>

<p>However, when I programmatically set the button's <code>selected</code> property to be true, this is the result:</p>

<p><a href="https://i.stack.imgur.com/PJaN1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PJaN1.png" alt="enter image description here"></a></p>

<p>What I originally want to achieve is for the button to have bolded text whenever the <code>selected</code> property of the UIButton is <code>true</code>, but in this case a border gets in the way, and the text is certainly not white as well.</p>

<p>Is there any way to dynamically bold the text of the UIButton based on user input with the <code>selected</code> property, or do I have to hack together another less elegant solution with a boolean?</p>