Re: Slider bar have two sections
Re: Slider bar have two sections
- Subject: Re: Slider bar have two sections
- From: Graham Cox <email@hidden>
- Date: Sat, 19 Dec 2009 23:08:22 +1100
On 19/12/2009, at 8:58 PM, XiaoGang Li wrote:
> Hello Lists,
> I have a application used to review the graphics. In the user
> interface, there is a slider bar, which used to control the zoom value, the
> zoom value range from 20% to 2000%. You know, it is better to locate the
> slider knob in the middle of the slider when the zoom value is 100%. That's
> to say, when the knob is dragged between the beginning to the middle of the
> slider, the zoom value range from 20% to 100%, when the knob is dragged
> between the middle of the slider to the end, the zoom value range from 100%
> to 2000%.
> I don't know how to customize this kind of slider bar, could you
> please give me a hint? do i need to implement a slider controller?
This came up a few days ago in connection with a pitch-shift slider for a musical app. Just do a suitable range/scale mapping from the linear slider to the geometric values you want. You'd do that in the controller that is handling the slider - it doesn't need a separate slider controller.
--Graham
_______________________________________________
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