• 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: Repositioning a content view w/in a window
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Repositioning a content view w/in a window


  • Subject: Re: Repositioning a content view w/in a window
  • From: "Michael Ash" <email@hidden>
  • Date: Fri, 25 Jul 2008 21:50:42 -0400

On Fri, Jul 25, 2008 at 9:42 PM, Graham Cox <email@hidden> wrote:
> Well, it's the usual approach. The content view is something that the window
> owns to act purely as the root of its view hierarchy - there's usually not
> much to be gained by fiddling with it or putting your own content there
> directly. For example, when you drag a custom view (or any view) into a
> window in Interface Builder, it's actually adding it as a subview of the
> implied contentView, which you never see in IB.

In fact I would go so far as to say that if you ever use
-setContentView:, you are very probably doing it wrong. It is, for the
most part, not a very useful call, and you can accomplish the same
thing more naturally, easily, and flexibly by adding the view as a
subview to the content view instead.

Mike
_______________________________________________

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

  • Follow-Ups:
    • Re: Repositioning a content view w/in a window
      • From: "Henry McGilton (Starbase)" <email@hidden>
References: 
 >Repositioning a content view w/in a window (From: "R.L. Grigg" <email@hidden>)
 >Re: Repositioning a content view w/in a window (From: Andrew Merenbach <email@hidden>)
 >Re: Repositioning a content view w/in a window (From: "R.L. Grigg" <email@hidden>)
 >Re: Repositioning a content view w/in a window (From: Graham Cox <email@hidden>)

  • Prev by Date: Re: Repositioning a content view w/in a window
  • Next by Date: Re: Problem when archiving data: [_NSViewGState encodeWithCoder:] unrecognized selector
  • Previous by thread: Re: Repositioning a content view w/in a window
  • Next by thread: Re: Repositioning a content view w/in a window
  • Index(es):
    • Date
    • Thread