• 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
NSLayoutManager Problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSLayoutManager Problem


  • Subject: NSLayoutManager Problem
  • From: Eric Forget <email@hidden>
  • Date: Thu, 21 Oct 2004 13:34:55 -0400

Hi,

It looks to me like a bug in NSLayoutManager, but maybe it is me that I'm
doing a bad thing.

I have some text displayed with NSLayoutManager in the form of (without the
dash lines):

-------------------------------------------------
1) Lorem ipsum dolor sit amet, consectetuer
adipiscing elit. Nam dui. Vivamus vitae ante
eget nibh venenatis molestie. Phasellus
condimentum tempus erat. Sed nec tellus sit
amet lectus scelerisque sodales.
-------------------------------------------------

Or in the form of:

-------------------------------------------------
Lorem ipsum dolor sit amet, consectetuer
adipiscing elit. Nam dui. Vivamus vitae ante
eget nibh venenatis molestie. Phasellus
condimentum tempus erat. Sed nec tellus sit
amet lectus scelerisque sodales.
-------------------------------------------------

Unfortunately, after some "trigger event" the layout is changed to the
following for all the NSLayoutManager instances. They share nothing: neither
the storage or the container. Look at the last line of the paragraph:

-------------------------------------------------
1) Lorem ipsum dolor sit amet, consectetuer
adipiscing elit. Nam dui. Vivamus vitae ante
eget nibh venenatis molestie. Phasellus
condimentum tempus erat. Sed nec tellus sit
amet lectus scelerisque sodales.
-------------------------------------------------

And for the other form:

-------------------------------------------------
Lorem ipsum dolor sit amet, consectetuer
adipiscing elit. Nam dui. Vivamus vitae ante
eget nibh venenatis molestie. Phasellus
condimentum tempus erat. Sed nec tellus sit
amet lectus scelerisque sodales.
-------------------------------------------------

And this bad layout is repeated to all the paragraphs in the same
storage/container. The last line of all paragraph has the same layout as the
first paragraph!

One of the trigger seems to be once one layout manager has laid out a long
paragraph, say more than 2000 chars, and that it doesn't fit in the
container. After that all the layout manager behaves incorrectly forever, or
until I quit my application. To me it looks like some globals has been
scrapped, but I may be wrong.

Any others have seen such behavior?

Thanks,

Éric

___________________________________________________________________

Eric Forget Cafederic
email@hidden <http://www.cafederic.com/>



_______________________________________________
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

  • Prev by Date: Re: Help Help or is there any logic to CFBundleHelpBookName
  • Next by Date: Re: creating NSTextField instances
  • Previous by thread: Bindings, Floats, and NSMutableDictionary
  • Next by thread: Array of dictionaries + NSUserDefaultsController
  • Index(es):
    • Date
    • Thread