Re: locator snap
- To: mathgroup at smc.vnet.net
- Subject: [mg88452] Re: [mg88237] locator snap
- From: Joe Bolte <joeb at wolfram.com>
- Date: Mon, 5 May 2008 06:17:21 -0400 (EDT)
- References: <200804291049.GAA28216@smc.vnet.net>
On Apr 29, 2008, at 6:49 AM, Maarten van der Burgt wrote:
> Dear all,
>
> In the example below the locator can be moved to any position in the
> graphic.
> Can the locator be made to snap to multiples of say 0.1?
>
> Manipulate[Column@{Graphics[{}, Axes -> True], p}, {{p, {0, 0}},
> Locator}]
>
> Thanks for your help.
>
> Maarten
Manipulate[
p = Round[p, .1];
Column@{Graphics[{}, Axes -> True], p},
{{p, {0, 0}}, Locator}]
Cheers,
Joe