• 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: reset textcontainer size?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: reset textcontainer size?


  • Subject: Re: reset textcontainer size?
  • From: Douglas Davidson <email@hidden>
  • Date: Thu, 19 Jan 2006 16:59:34 -0800


On Jan 19, 2006, at 4:49 PM, Nik Youdale wrote:

I have a method which calls [textContainer setContainerSize:aSize]. This sets the size of the text container just fine, and the text wraps itself around the new container etc. Its all good.

My question is, how do reset the default behavior of the text container - that is, to resize itself and its textView according to the contents of its text?


Actually, the default text container is just very large; it is the text view that resizes itself based on the contents of the text. You can find out the original container size by taking note of it before you first resize your container, or by creating a new text container and examining its size.


For more on resizing behavior, check out the documentation on text containers, and the TextSizingExample.

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: 
 >reset textcontainer size? (From: Nik Youdale <email@hidden>)

  • Prev by Date: A caution for those moving to gcc 4.0.1
  • Next by Date: Re: NSLayoutManager subclassing
  • Previous by thread: reset textcontainer size?
  • Next by thread: Encoding Cocoa objects and checking for equality
  • Index(es):
    • Date
    • Thread