Re: How Insert values into a NSCell of NSTableView?
Re: How Insert values into a NSCell of NSTableView?
- Subject: Re: How Insert values into a NSCell of NSTableView?
- From: Fritz Anderson <email@hidden>
- Date: Thu, 11 Dec 2003 10:30:16 -0600
You've got the wrong mental model for NSTableView. It isn't an array of
NSCells. It keeps only one NSCell for each column, and moves that cell
down the column (substituting row data as it goes) in order to draw it.
NSTableView does not keep values. It asks a data source for row/column
values to display in the course of the drawing process I just
described. (The view sends the tableView:objectValueForTableColumn:row:
message to its data source.) So the way you change a cell value is to
change the knowledge of it in the data source, and tell the NSTableView
to go looking for it by sending it the message reloadData.
-- F
On 11 Dec 2003, at 10:04 AM, Roberto wrote:
How can I insert a value into a NSCell of an NSTableView?
Must I use setDataCell??
_______________________________________________
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.