• 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
Smaller Button in NSTextFieldCell
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Smaller Button in NSTextFieldCell


  • Subject: Smaller Button in NSTextFieldCell
  • From: Mike Rossetti <email@hidden>
  • Date: Tue, 17 Apr 2007 17:57:46 -0600

Here's another question:

Given a column in in a table view I would like to present some text, but for certain rows I would also like to show a small button that says 'Details...'. At the current time I've implemented it as a NSButtonCell where in its drawTitleWithFrame: I draw the text and then if the button is needed I draw the button by calling drawWithFrame: with a smaller rect.

The problem is that I need to also shrink the active area of the cell to the bounds of the little button. I haven't found a way to accomplish this.

I suppose I could create a custom view that I plug into the cell and then hide/show the button in question, but I'm hoping there is a simpler way.

Any suggestions?

Thanks,
Mike

_______________________________________________

Cocoa-dev mailing list (email@hidden)

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


  • Prev by Date: Moderator: EOT [Re: Custom document icons]
  • Next by Date: Re: safe and efficient way tp duplicate NSMutable array
  • Previous by thread: Adding Custom Menu Items to NSPopUpButtonCell with Bindings
  • Next by thread: Global variable for whole application.
  • Index(es):
    • Date
    • Thread