Re: Unclear on NSView's isOpaque concept (and optimization in general)
Re: Unclear on NSView's isOpaque concept (and optimization in general)
- Subject: Re: Unclear on NSView's isOpaque concept (and optimization in general)
- From: Alastair Houghton <email@hidden>
- Date: Thu, 6 Nov 2003 12:45:00 +0000
On 6 Nov 2003, at 12:22, Leon McNeill wrote:
On 6 Nov 2003, at 11:09, Alastair Houghton wrote:
"You aren't supposed to overlap sibling views" is a bit strong of a
statement, isn't it? According to the documentation, it's simply "not
recommended", and in my case nesting a view that's to be drawn on top
of another made no difference to performance according to my tests,
and would merely serve to greatly complicate my layout process.
Indeed, [NSView addSubview:positioned:relativeTo:]'s documentation
seems to indicate that there's nothing wrong with overlapping sibling
views. I would definitely like to hear some concrete statements about
how I'll suffer by using overlapping sibling NSViews.
The order in which sibling views are rendered isn't defined and may
even change during a single run of your program due to optimisations in
the frameworks. So if you overlap them, you may find that they don't
always display correctly. Using overlapping sibling views won't
degrade the performance of your app., but it might make it misbehave.
I'm definitely inclined to agree with you, that my best hope lies in
eliminating as many NSViews as I can. It's just disappointing that
there seems to be so much overhead in NSViews.
That, of course, is why we have NSCell and NSMatrix.
Kind regards,
Alastair.
_______________________________________________
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.