• 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: row bg color in NSOutlineView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: row bg color in NSOutlineView


  • Subject: Re: row bg color in NSOutlineView
  • From: "John C. Randolph" <email@hidden>
  • Date: Sat, 22 Dec 2001 02:39:39 -0800

On Saturday, December 22, 2001, at 02:06 AM, Itrat Khan wrote:

> On Saturday, December 22, 2001, at 01:29 AM, jgo wrote:
>
>>> To save storage, NSTableView reuses cells to draw multiple items.
>>
>> Are they that massive? I thought that part of the idea of cells
>> is that they're lighter than views.
>
> They are lighter, but if you had 1,000 rows and five columns,
> you'd need 5,000 instances instead of just one.

Well, an NSTableView would have five cells in this case, but
your point still holds.

>> I don't quite get this. If one can set the cell for a specific
>> point in the table (column & row), then it must not be getting
>> re-used everywhere.
>
> You don't actually set the cell, you're given the cell and you
> can update its attributes (state, text colour, etc.).

Exactly. You're given the cell *and* the location it's about to
draw, so you can alter it accordingly.

-jcr

"I fear all we have done is to awaken a sleeping giant and fill
him with a terrible resolve." -Admiral Isoroku Yamamoto, Dec 7,
1941.


References: 
 >Re: row bg color in NSOutlineView (From: Itrat Khan <email@hidden>)

  • Prev by Date: Re: row bg color in NSOutlineView
  • Next by Date: Re: Cross platform Cocoa/Obj-C
  • Previous by thread: Re: row bg color in NSOutlineView
  • Next by thread: Re: row bg color in NSOutlineView
  • Index(es):
    • Date
    • Thread