• 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: Multiple NSViews
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multiple NSViews


  • Subject: Re: Multiple NSViews
  • From: "I. Savant" <email@hidden>
  • Date: Fri, 11 Apr 2008 09:10:48 -0400

On Fri, Apr 11, 2008 at 8:55 AM, Lorenzo <email@hidden> wrote:
> I have defined an NSView "info view" on IB.
>  This view contains several NSTextFields.
>  Now I want to programmatically create copies of this view and attach them to
>  the objects on my window. So if on my window I have 10 objects, I should see
>  the 10 objects, each one having its "info view". Each view reports
>  information about each object on the screen.
>  What's the best way to do that?

  If you're targeting Leopard, you could always use NSCollectionView -
it's perfectly suited for what you're trying to do (so long as the
views are of homogenous size).

  Otherwise, it's easiest to put your view in its own separate nib,
then load an instance in each time you need it.

http://cocoadevcentral.com/articles/000064.php

--
I.S.
_______________________________________________

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

References: 
 >Multiple NSViews (From: Lorenzo <email@hidden>)

  • Prev by Date: Re: custom dragging destination feedback in an NSTableView
  • Next by Date: Re: Core Data, Threads and Document based app
  • Previous by thread: Multiple NSViews
  • Next by thread: Building a custom Data Detector
  • Index(es):
    • Date
    • Thread