Bold part of an NSAttributedString without changing the font

If you bold by changing the NSFontAttributeName you’ll have to specify the font face. If you don’t want to change the font face, use the NSStrokeWidthAttributeName with a negative value:

Result:

Text with some bold part

Leave a Reply