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

Re: Subclassing NSLevelIndicatorCell


  • Subject: Re: Subclassing NSLevelIndicatorCell
  • From: "Adam R. Maxwell" <email@hidden>
  • Date: Thu, 28 Jun 2007 06:37:46 -0700


On Jun 28, 2007, at 03:56, Todd Freese wrote:

I am having troubles subclassing NSLevelIndicatorCell. I want to add a text percentage display in the middle of the bar graph display. This subclass is displayed in an NSTableView. My thoughts are to subclass NSLevelIndicatorCell and override the drawWithFrame method. However, my call to super does not seem to be working as my text is displayed, but bar graph is not. Here is my code:

NSLevelIndicatorCell doesn't call the NSCell drawing methods AFAICT, so subclassing it is impossible (rdar://problem/4998206). You can override one of its private drawing methods such as _drawRelevancyWithFrame:inView:, but that may break if and when they fix it. I did it because the default height in a tableview is ugly, so if it breaks it's not critical.


--
Adam
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please 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


  • Follow-Ups:
    • Re: Subclassing NSLevelIndicatorCell
      • From: Todd Freese <email@hidden>
References: 
 >Subclassing NSLevelIndicatorCell (From: Todd Freese <email@hidden>)

  • Prev by Date: Parse Python class
  • Next by Date: window swapping
  • Previous by thread: Subclassing NSLevelIndicatorCell
  • Next by thread: Re: Subclassing NSLevelIndicatorCell
  • Index(es):
    • Date
    • Thread