Re: NSTextView becomes temporarily unresponsive

2010-07-15 Thread David Swofford
In case anyone is interested... I filed a bug. In the meantime, I am able to work around the problem by subclassing NSTextStorage and overriding doubleClickAtIndex: (a suggestion by Doug Davidson). I didn't have a clue how to write the primitive methods required for subclassing NSTextStorage,

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread Aki Inoue
This is indeed an issue with the text system (trying to pre-heat the inserted text range for various text checking tasks). Please file a bug. > 4. As a workaround, could you use underscore characters instead of hyphens? I > tried using en dash and got the same result as hyphens. > > 5. May I su

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread David Swofford
On Jul 13, 2010, at 7:34 PM, Ross Carter wrote: > I don't think it has anything to do with wrapping. AFAICT, layout is complete > before the delay begins. I think this is a bug that you need to report. Maybe > Doug or Aki can chime in with a solution. Thanks for a very informative reply. > Her

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread Ross Carter
I don't think it has anything to do with wrapping. AFAICT, layout is complete before the delay begins. I think this is a bug that you need to report. Maybe Doug or Aki can chime in with a solution. Here are some things that I found: 1. The problem is indeed the hyphen characters. Replace all th

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread Graham Cox
On 14/07/2010, at 5:24 AM, David Swofford wrote: > Ah... I see a difference, and it's very relevant. My example has a lot of > hyphen characters in it (FWIW these represent gaps in a sequence alignment > and are typically common in these kinds of files). Your example was all > letters. When

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread David Swofford
On Jul 13, 2010, at 2:38 PM, Ross Carter wrote: > Could you post a test file somewhere? I just tried creating 187 pages of > repeating ACCGACTACCGACT in TextEdit and it worked fine. Ah... I see a difference, and it's very relevant. My example has a lot of hyphen characters in it (FWIW these r

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread David Swofford
On Jul 13, 2010, at 2:38 PM, Ross Carter wrote: > Could you post a test file somewhere? I just tried creating 187 pages of > repeating ACCGACTACCGACT in TextEdit and it worked fine. Thanks for your interest! I've put an example at http://www.duke.edu/~dls36/nstextview_problem/ Remember, you h

Re: NSTextView becomes temporarily unresponsive

2010-07-13 Thread Ross Carter
On Jul 12, 2010, at 6:01 PM, David Swofford wrote: > I'm beginning the conversion of a scientific app from Carbon to Cocoa, and > have run into a problem with NSTextView. FWIW, I have it embedded in an > NSScrollView that is in turn included as an HICocoaView in a Carbon window > (but I don't

NSTextView becomes temporarily unresponsive

2010-07-12 Thread David Swofford
I'm beginning the conversion of a scientific app from Carbon to Cocoa, and have run into a problem with NSTextView. FWIW, I have it embedded in an NSScrollView that is in turn included as an HICocoaView in a Carbon window (but I don't think this is relevant to my problem). It works, but I've r