Re: NSTextView default plain text font
Re: NSTextView default plain text font
- Subject: Re: NSTextView default plain text font
- From: Keary Suska <email@hidden>
- Date: Sat, 26 Jul 2014 08:56:45 -0600
On Jul 25, 2014, at 8:05 PM, Carl Hoefs <email@hidden> wrote:
> I have an OS X app that uses an NSTextView to hold text that is pasted into it (among other things). I've deselected "Allows Rich Text" in Xcode because I want the text displayed uniformly in a non proportional font and all of the same size (such as Monaco 12 pt). However, the text that is pasted into the NSTextView is always displayed in Helvetica 12 pt font. I don't see what method I would use to set this, either programmatically or directly within Xcode.
It is somewhat counter-intuitive, but setting the font on an NSTextView does not set the "default" font. You need to call -setTypingAttributes: on the text view to set the "default" font.
HTH,
Keary Suska
Esoteritech, Inc.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden