// RESTORE SESSION AFTER EXPORT IF NEED BE
if (sessionToRestore != null)
{
- Console.debug("Restoring session from "
- + sessionToRestore);
-
- sview.getBinding().restoreSession(sessionToRestore.getAbsolutePath());
+ Console.debug(
+ "Restoring session from " + sessionToRestore);
+
+ sview.getBinding().restoreSession(
+ sessionToRestore.getAbsolutePath());
}
} catch (ImageOutputException ioexec)
continue;
} finally
{
- try {
+ try
+ {
this.colourAlignFrame(af, originalColourScheme);
} catch (Exception t)
{
- addError("Unexpected error when restoring colourscheme to alignment after temporary change for export.",t);
+ addError(
+ "Unexpected error when restoring colourscheme to alignment after temporary change for export.",
+ t);
}
}
}
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
+ if (avm != null && !avm.containsArg(Arg.GROOVY))
+ {
+ // nothing to do
+ return;
+ }
+
if (af == null)
{
- addWarn("Did not have an alignment window for id=" + id);
+ addWarn("Groovy script does not have an alignment window. Proceeding with caution!");
return;
}
if (avm.containsArg(Arg.GROOVY))
{
- String groovyscript = avm.getValue(Arg.GROOVY);
- if (groovyscript != null)
+ for (ArgValue groovyAv : avm.getArgValueList(Arg.GROOVY))
{
- // Execute the groovy script after we've done all the rendering stuff
- // and before any images or figures are generated.
- Console.info("Executing script " + groovyscript);
- Jalview.getInstance().executeGroovyScript(groovyscript, af);
+ String groovyscript = groovyAv.getValue();
+ if (groovyscript != null)
+ {
+ // Execute the groovy script after we've done all the rendering stuff
+ // and before any images or figures are generated.
+ Console.info("Executing script " + groovyscript);
+ Jalview.getInstance().executeGroovyScript(groovyscript, af);
+ }
}
}
}
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
+ if (avm != null && !avm.containsArg(Arg.IMAGE))
+ {
+ // nothing to do
+ return true;
+ }
+
if (af == null)
{
- addWarn("Did not have an alignment window for id=" + id);
+ addWarn("Do not have an alignment window to create image from (id="
+ + id + "). Not proceeding.");
return false;
}
ArgValuesMap avm = argParser.getLinkedArgs(id);
AlignFrame af = afMap.get(id);
+ if (avm != null && !avm.containsArg(Arg.OUTPUT))
+ {
+ // nothing to do
+ return true;
+ }
+
if (af == null)
{
- addWarn("Did not have an alignment window for id=" + id);
+ addWarn("Do not have an alignment window (id=" + id
+ + "). Not proceeding.");
return false;
}