I\'m trying to create a label programmatically using NSTextField, but it comes out blurry: screenshot
This is my code so far:
NSTextfield *textfield
If you have no background (including clear) and your text is a subview of any layer-backed superview (you've turned on "wants layer" in code or in IB to allow animations/transitions), you'll get blurry text. You have to choose either no layer backed view or a label with a solid background color.
Try this below:
textField.drawsBackground = true
textField.backgroundColor = NSColor.white.withAlphaComponent(.leastNormalMagnitude)