• 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: Create a custom control (widget)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Create a custom control (widget)


  • Subject: Re: Create a custom control (widget)
  • From: Scott Anguish <email@hidden>
  • Date: Mon, 10 Feb 2003 01:49:31 -0500

On Monday, February 10, 2003, at 12:17 AM, Salter, Adam Q wrote:

This might sound silly, but I can't find any clear tutorials for building a
custom "control"... what I want is a "stars" rating selection like in
iTunes...


oh, I want one of those too. :-)

Each control is going to be slightly different to code. This one is actually pretty simple in that you just need to figure how far over the click/drag is, set the value accordingly, and then implement the draw routine.

Chapter 18 of Cocoa Programming (http://www.cocoaprogramming.net) shows you how to write a custom pie control, and this is adaptable to what you need if you remove the trig :-)

There is also an excellent example of a control in the ADC/WWDC download area that Chuck Pisula wrote for WWDC 2002. It goes the extra length to also cover how to palletize it.
_______________________________________________
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.
References: 
 >Create a custom control (widget) (From: "Salter, Adam Q" <email@hidden>)

  • Prev by Date: simple Distributed Objects question
  • Next by Date: Bind NSOutlineView to database ( newbie )
  • Previous by thread: Re: Create a custom control (widget)
  • Next by thread: Re: Create a custom control (widget)
  • Index(es):
    • Date
    • Thread