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 (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to