• 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: Properly wrapping non-contiguous NSTextViews
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Properly wrapping non-contiguous NSTextViews


  • Subject: Re: Properly wrapping non-contiguous NSTextViews
  • From: Martin Wierschin <email@hidden>
  • Date: Sun, 14 Aug 2011 01:46:50 -0700

I think Ross's confusion stems from your statement that:

>>> There is one NSLayoutManager and one NSTextStorage behind each text view

You make it sound as if a single NSTextView is responsible for completely showing all the text in each NSTextStorage. In other words, that each of your NSLayoutManagers has exactly one NSTextContainer (and one NSTextView) associated with it. But from your code and described strategy, it sounds like you actually have multiple NSTextContainers (and NSTextViews) associated with each NSLayoutManager.

>>> So how do I prevent NSLayoutManager from drawing cut-off glyphs in a series of non-contiguous text views? Yes, I did make sure that the text container's size tracks the text view's size.

I don't know the particulars of your situation or what might be triggering the cutoff display (are they just descenders?), but have you tried reducing the height of the NSTextContainer while keeping your NSTextView height the same? (You'll have to disable automatic resizing). That should make NSLayoutManager place/assign less lines of text to the view, while keeping the drawable view bounds the same.

~Martin

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Properly wrapping non-contiguous NSTextViews
      • From: Nick Zitzmann <email@hidden>
References: 
 >Properly wrapping non-contiguous NSTextViews (From: Nick Zitzmann <email@hidden>)
 >Re: Properly wrapping non-contiguous NSTextViews (From: Ross Carter <email@hidden>)
 >Re: Properly wrapping non-contiguous NSTextViews (From: Nick Zitzmann <email@hidden>)

  • Prev by Date: Re: File Copy With Progress?
  • Next by Date: xCode 4 and integrated IB
  • Previous by thread: Re: Properly wrapping non-contiguous NSTextViews
  • Next by thread: Re: Properly wrapping non-contiguous NSTextViews
  • Index(es):
    • Date
    • Thread