Quantcast

Macro shortcuts

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Macro shortcuts

heshamza
Im trying to create a shortcut out of a macro that I have created.

I have installed the macro, and am able to run it from imagej, but whenever I try to create a shortcut, my macro does not appear in the list of available options...

any ideas?
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Macro shortcuts

Michael Schmid-3
Hi anonymous,

did you have a look at the documentation?
   http://rsb.info.nih.gov/ij/developer/macro/macros.html

e.g. for shortcut 'a'
     macro "Macro 1 [a]" {
         print("The user pressed 'a'");
     }

Installing the macro is ok, you need that to get the shortcut working.

If you want to have your macro available all the time (without  
installing), add it to the StartupMacros.txt file in the ImageJ/
macros directory.

Michael
________________________________________________________________

On 28 Oct 2010, at 22:13, heshamza wrote:

> Im trying to create a shortcut out of a macro that I have created.
>
> I have installed the macro, and am able to run it from imagej, but  
> whenever
> I try to create a shortcut, my macro does not appear in the list of
> available options...
>
> any ideas?
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Macro shortcuts

heshamza
thanks Michael!!

On Oct 29, 2010, at 12:05 PM, Michael Schmid wrote:

> Hi anonymous,
>
> did you have a look at the documentation?
>   http://rsb.info.nih.gov/ij/developer/macro/macros.html
>
> e.g. for shortcut 'a'
>     macro "Macro 1 [a]" {
>         print("The user pressed 'a'");
>     }
>
> Installing the macro is ok, you need that to get the shortcut working.
>
> If you want to have your macro available all the time (without  
> installing), add it to the StartupMacros.txt file in the ImageJ/
> macros directory.
>
> Michael
> ________________________________________________________________
>
> On 28 Oct 2010, at 22:13, heshamza wrote:
>
>> Im trying to create a shortcut out of a macro that I have created.
>>
>> I have installed the macro, and am able to run it from imagej, but  
>> whenever
>> I try to create a shortcut, my macro does not appear in the list of
>> available options...
>>
>> any ideas?
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Macro shortcuts

zuzie3
This post has NOT been accepted by the mailing list yet.
In reply to this post by heshamza
The trick is probably including the underscore in the file name.

From the documentation: "the macro will be automatically installed as a "Hello World" command in the Plugins menu when you restart ImageJ, assuming the file name has an underscore in it and the macro was saved in the plugins folder or a subfolder"
Loading...