• 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: NSTextView scrolling problem...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTextView scrolling problem...


  • Subject: Re: NSTextView scrolling problem...
  • From: Mike Ferris <email@hidden>
  • Date: Mon, 9 Dec 2002 10:21:10 -0800

This probably indicates that sometimes you are calling -scrollRangeToVisible (or something else thatqueries the layout manager about layout) while the text storage object is "editing" (ie it has been sent a beginEditing without yet being sent a matching endEditing).

When this happens, the layout manager is unaware of what is going on and has stale layout info. If you start asking it questions in this state, things can go bad quickly. In this case, text has been appended to the storage but not yet laid out and so when the text view starts asking for glyph ranges and layout info and so forth, it is asking about characters that the layout manager doesn't know about yet.

Something along these lines is almost certainly the problem. The range {length, 0} is a valid range to use.

Mike
_______________________________________________
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: 
 >NSTextView scrolling problem... (From: Nico <email@hidden>)

  • Prev by Date: Re: Subject: Re: Cocoa Book / ok, ok.
  • Next by Date: Re: Subclassing NSWindowController
  • Previous by thread: Re: NSTextView scrolling problem...
  • Next by thread: Re: basic Obj-C lesson (was runtime error with NSArray no
  • Index(es):
    • Date
    • Thread