• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to change default font for NSTextView?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to change default font for NSTextView?


  • Subject: Re: How to change default font for NSTextView?
  • From: Douglas Davidson <email@hidden>
  • Date: Wed, 13 Feb 2002 11:54:49 -0800

On Wednesday, February 13, 2002, at 11:25 AM, David Rehring wrote:

However, setFont: does NOT work until AFTER there is some text in the
NSTextView.

As well, if the user deletes all the text in the NSTextView, the font
reverts to the default font.

No, not so--setFont: sets the typing attributes. In fact, I just created a test project that does this very thing, and established that setFont: works when there is no text in the textview, and that deleting all the text in the textview leaves the font as set, whether the textview allows rich text or not. Of course, if rich text is allowed, and the user changes the font of the text, then the font chosen by the user is the one used.

Do you have a sample project that exhibits the behavior you mention?

Douglas Davidson
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: How to change default font for NSTextView? (From: David Rehring <email@hidden>)

  • Prev by Date: Re: How do I open an NSDrawer in awakeFromNib?
  • Next by Date: Re: about help
  • Previous by thread: Re: How to change default font for NSTextView?
  • Next by thread: Re: How to change default font for NSTextView?
  • Index(es):
    • Date
    • Thread