You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are two places where a (user-modifiable) image name can be stored:
As a property of the project entry
As a field in the ImageServer metadata
The first is best when using a project, the second exists to provide a sensible default (since it's generally based on the original image file) and to handle cases where a project isn't being used.
When the name is set in the project, then that's the one the user generally expects to see because it's the most prominent in the UI. But when writing a script, I don't necessarily know whether it will be run in a project or not. As a result, I often find myself having to do something like this:
var entry = getProjectEntry()
var server = getCurrentServer()
var imageName = entry ==null? server.getMetadata().getName() : entry.getImageName()
There should be one or more new methods added to QP to make this less awkward.
The text was updated successfully, but these errors were encountered:
There are two places where a (user-modifiable) image name can be stored:
ImageServer
metadataThe first is best when using a project, the second exists to provide a sensible default (since it's generally based on the original image file) and to handle cases where a project isn't being used.
When the name is set in the project, then that's the one the user generally expects to see because it's the most prominent in the UI. But when writing a script, I don't necessarily know whether it will be run in a project or not. As a result, I often find myself having to do something like this:
There should be one or more new methods added to
QP
to make this less awkward.The text was updated successfully, but these errors were encountered: