• 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: Conditionally formatting cells in an NSTableView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Conditionally formatting cells in an NSTableView


  • Subject: Re: Conditionally formatting cells in an NSTableView
  • From: matt neuburg <email@hidden>
  • Date: Tue, 26 Nov 2002 12:07:56 -0800

On Tue, 26 Nov 2002 06:56:54 -0800, "Tamara L. Cravit" <email@hidden> said:

>What I'd like to do next is to conditionally format some cells to be in
>bold, based on whether or not a particular data element is nil. Can I do
>this in the NSTableDataSource "aTable objectValueForTableColumn:row:"
>method or is there somewhere better to do this?
>A pointer in the right direction would be greatly appreciated!

The NSTableColumn has a dataCell that does the drawing of the cell. This can be the same NSCell for the entire column, in which case you would supply a "smart" NSCell subclass, or you can supply a different NSCell for each row by overriding NSTableColumn's dataCellForRow:. m.

matt neuburg, phd = email@hidden, http://www.tidbits.com/matt
pantes anthropoi tou eidenai oregontai phusei
Subscribe to TidBITS! It's free and smart. http://www.tidbits.com/
_______________________________________________
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.

  • Prev by Date: Re: customizing NSTextView
  • Next by Date: Re: Strip Chart Tool?
  • Previous by thread: Re: Conditionally formatting cells in an NSTableView
  • Next by thread: proper location for a database file
  • Index(es):
    • Date
    • Thread