Scripts for "Subtract selected annotations", "Merge selected annotations", "Duplicate selected annotations" &"Make inverse annotion"

319 views
Skip to first unread message

David

unread,
Nov 12, 2017, 6:58:15 AM11/12/17
to QuPath users
In case of the functions
 
Substract selected annotations
Merge selected annotations
Duplicate selected annotations
Make inverse annotation

the Script editor shows no command history script after using "Create command history script".

Is there a way to generate these scripts mannually?

Best
David



micros...@gmail.com

unread,
Nov 12, 2017, 5:10:05 PM11/12/17
to QuPath users
To help you out in general, when I have questions like this, one of the first places I usually go is:  https://github.com/qupath/qupath and use the search box at the top to search for code that might be helpful.  I think IntelliJ Idea might be another option as long as you set it up correctly, but I have never focused on finishing setting it up.  (https://github.com/qupath/qupath/wiki/Advanced-scripting-with-IntelliJ)

In your case, using the script for the command that I do already know, I was able to find:
https://github.com/qupath/qupath/search?utf8=%E2%9C%93&q=mergeAnnotations&type=

The result of which led me to:
https://github.com/qupath/qupath/blob/3577d75b4a3bfb6b4676962f34fd10b95b61dcfe/qupath-gui-fx/src/main/java/qupath/lib/scripting/QPEx.java

That file seems to have most of the functions you are referring to.  I do not know of any way within QuPath to see the code for those commands.
Reply all
Reply to author
Forward
0 new messages