title: ButtonDownFcn with an argument in Matlab
body: <p>I have a patch which I have included below and I want to add an additional ButtonDownFcn to the patch. When I do the second option the code does not work I get to many output arguments.</p>
  
  <p>Original patch</p>
  
  <pre><code>for i = 1:10
      counter = counter+1;
      hpatch(counter) = patch([x(17) x(18) x(1) x(1)],[y(17) y(18) y(1) y(1)],[0 0 0 0],...
      'Parent',hAx,'ButtonDownFcn', ['winopen(''' file(counter) ''');']));
  end
  </code></pre>
  
  <p>New desired patch</p>
  
  <pre><code>for i = 1:10
      counter = counter+1;
      hpatch(counter) = patch([x(17) x(18) x(1) x(1)],[y(17) y(18) y(1) y(1)],[0 0 0 0],...
      'Parent',hAx,'ButtonDownFcn', ['winopen(''' file(counter) ''');'],...
      'ButtonDownFcn', @saveClickData(counter));
  end
  </code></pre>
  
  <p>Here is the function </p>
  
  <pre><code>saveClickData(counter)
  </code></pre>
  
  <p>should it be this?:</p>
  
  <pre><code>saveClickData(source,event)
  </code></pre>