• 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: When do I have to update the typing attributes?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: When do I have to update the typing attributes?


  • Subject: Re: When do I have to update the typing attributes?
  • From: Douglas Davidson <email@hidden>
  • Date: Tue, 3 Oct 2006 10:46:54 -0700


On Oct 3, 2006, at 10:04 AM, Jim Correia wrote:

The documentation for -[NSTextView setTypingAttributes:] says:

	Typing attributes are reset automatically whenever the selection
	changes. If you add any user actions that change text attributes,
	you should use this method to apply those attributes to a
	zero-length selection.

Is it unnecessary to change the typing attributes when there is a non-zero length selection? (The reason I ask is that it appears the -changeFont: action modifies the text storage and changes the typing attributes for a non-zero-length selection.)

The convention is that user actions that change attributes should always set the typing attributes. There might not be a subsequent change in selection before the next typing. You can file a documentation bug if the documentation does not make this clear.


Douglas Davidson
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >When do I have to update the typing attributes? (From: Jim Correia <email@hidden>)

  • Prev by Date: Re: How to draw a rotated image in a view?
  • Next by Date: Re: Overriding NSCell's editWithFrame:...
  • Previous by thread: When do I have to update the typing attributes?
  • Next by thread: Re: When do I have to update the typing attributes?
  • Index(es):
    • Date
    • Thread