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

Re: NSLevelIndicatorCell


  • Subject: Re: NSLevelIndicatorCell
  • From: "Adam R. Maxwell" <email@hidden>
  • Date: Fri, 17 Feb 2006 18:12:07 -0800


On Feb 17, 2006, at 11:57, email@hidden wrote:

I am using an NSLevelIndicatorCell in an NSTableView and I have not been able to make the cell uneditable. Even when I make the column uneditable it does not work. If I make the Class (NSMutableDictionary) it is bound to an (NSDictionary) I get errors that it is trying to modify a non-mutable class. But at least the display does not change. I want this to be a read-only column, that the user cannot change. How do I do that? I have been unsuccesful in all attempts and do not want to create a new subclass of NSMutableDictionary that ignores updates. It would seem that creating a read-only level indicator would be a common usage. Has anyone else had this problem? Any solutions?

Yes, this drove me crazy a few months ago; you want "enabled" instead of "editable." Here's my solution, copy-and-pasted from awakeFromNib:


NSLevelIndicatorCell *cell = [[tableView tableColumnWithIdentifier:@"score"] dataCell];
[cell setLevelIndicatorStyle:NSRelevancyLevelIndicatorStyle]; // the default one makes the tableview unusably slow
[cell setEnabled:NO]; // this is required to make it non-editable


hth,
Adam


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >NSLevelIndicatorCell (From: email@hidden)

  • Prev by Date: Re: Attributed string not displaying with effects of attributes in an NSTextView...
  • Next by Date: Re: Attributed string not displaying with effects of attributes in an NSTextView...
  • Previous by thread: NSLevelIndicatorCell
  • Next by thread: *Still* Crashing Cross Development
  • Index(es):
    • Date
    • Thread