Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Bug fixed in V 10.

According to the documentation, Dynamic Details & Options section, especially:

For interactive mouse operations Dynamic[expr,{f_start, f, f_end}] typically evaluates f_start[val,expr] once when the mouse is pressed, then evaluates f[val,expr] whenever the mouse is moved, and then evaluates f_end[val,expr] once when the mouse is released.

I find the following behaviour a possible bug:

x = {.5, .5};
Graphics[{ Circle[],
           Locator[Dynamic[x, {Print[#] &, Automatic, None}]]

enter image description here

As you see f_start = Print[#]& is evaluated twice each time.

Is this a bug?

I've marked Bold the word typically in the quotation from documentation. Is this reffering to this case?

Here's the link to the question where Anon and I have faced this issue for the first time: Moving a locator based on the movement of another

share|improve this question
If you put {Print["start"] &, Print["mid"] &, Print["end"] &} inside the Dynamic, you will see, that there is a mouse-moved event ("mid") registered between the two "start" events. I am still pondering on the significance of this detail... – István Zachar Sep 10 '13 at 14:13
up vote 9 down vote accepted

Yes, it is a bug. I am quite confident it will be fixed in an upcoming release.

share|improve this answer
So you've faced it earlier and consulted with Wolfram? – Kuba Sep 10 '13 at 21:19
I was considerably less confident than Rolf. Especially when I tried it in a development build, and it behaved worse. But then I fixed it. So I guess my confidence matches Rolf's, now. :) Beta testers should see this in the next beta build. – John Fultz Sep 12 '13 at 6:39
John for president! – Rolf Mertig Sep 12 '13 at 7:29

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.