Re: (no subject) - NSOutlineView
Re: (no subject) - NSOutlineView
- Subject: Re: (no subject) - NSOutlineView
- From: Orr Philip <email@hidden>
- Date: Sat, 17 Mar 2007 00:01:03 +0000
Hi there Uli and thanks for the quick reply.
I do basically understand what you have said and maybe I'm just being
a bit slow here. I do have an NSOutlineView working, but still don't
understand the hows.
If I've got an array of objects to be displayed and one of those is
an array of more objects, clicking on the arrow to the left reveals a
list of those said objects but how does the application know what
values it is being asked to display. The way I had it in my head was
that it was an NSTableView and your application would be asked for
the value of the 25th item, which was 5 layers deep. This I'm sure is
wrong, especially as you said that it "Might help to see
NSOutlineView as a collection of small NSTableViews". Does this mean
that each new array has it's own column header or am I still getting
it wrong.
Phil
On 16 Mar 2007, at 21:54, Uli Kusterer wrote:
Am 16.03.2007 um 22:13 schrieb Orr Philip:
Could someone like to explain please how NSOutlineView works, I've
looked up the internet and ran through the examples that Apple
give you, but for some reason I still don't quite understand how
it works out what value is needed for the cell.
I do understand the NSTableView okay and many columns say that
NSOutlineView is the same, sorry I don't think so.
Basically I'm looking to have a rootless column with any number of
children spawning from my options.
Might help to see NSOutlineView as a collection of small
NSTableViews. The "root" is NIL. The outline view will ask you how
many sub-items another item should have, and then just like with an
NSTableView, you can return an item for each column.
So, if you want a "rootless" view, just return a number bigger
than 1 when asked for the number of subitems of item NIL.
Anything else that isn't clear?
Cheers,
-- M. Uli Kusterer
http://www.zathras.de
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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