Re: How to detect when an NSTextView has finished being loaded into a window?
Re: How to detect when an NSTextView has finished being loaded into a window?
- Subject: Re: How to detect when an NSTextView has finished being loaded into a window?
- From: Keith Blount <email@hidden>
- Date: Mon, 21 Feb 2011 13:04:43 -0800 (PST)
Hi Matt,
Many thanks for the reply. Unfortunately that doesn't really work, as if it is hidden in any way then it is off screen and therefore the artefacts bug rears its ugly head. (The whole thing is in a tab view, and even if the text view is in a different tab to the visible one while it is set up, the artefacts bug appears.)
I may try rewiring it to load when the scroll view makes it to the window instead of the text view, although if NSScrollView does anything extra in _setWindow: I'll most likely have the same problem, of course. What would be ideal would be if I could find a way of knowing when the NSTextView has finished loading into the window completely, and _setWindow: has finished, but I don't think there's a way of doing that unfortunately... So I probably need to re-examine my wiring and set-up.
Thanks again and all the best,
Keith
--- On Mon, 2/21/11, Matt Neuburg <email@hidden> wrote:
> From: Matt Neuburg <email@hidden>
> Subject: Re: How to detect when an NSTextView has finished being loaded into a window?
> To: "Keith Blount" <email@hidden>
> Cc: email@hidden
> Date: Monday, February 21, 2011, 6:16 PM
> On Mon, 21 Feb 2011 06:22:35 -0800
> (PST), Keith Blount <email@hidden>
> said:
> > I've also tried only posting the notification after a
> delay of 0, which works and avoids the crash, but is a
> little slow - you can see the original text view getting
> loaded on screen before being swapped for the multiple page
> view.
> >
>
> If the nub of the remaining problem is what "you can see",
> I wonder why you don't simply have these text views be
> hidden. That way they are in the window (so that they are
> loaded correctly) but the user sees nothing. Or, if that
> doesn't work, cover them with something else (another view,
> or even a secondary window). You can cover the intervening
> time with a progress indicator of some sort. m.
>
> --
> matt neuburg, phd = email@hidden,
> <http://www.apeth.net/matt/>
> A fool + a tool + an autorelease pool = cool!
> AppleScript: the Definitive Guide - Second Edition!
> http://www.apeth.net/matt/default.html#applescriptthings
_______________________________________________
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