Skip to content

Commit

Permalink
Help string include StripChart specific arguments, if -strp option s …
Browse files Browse the repository at this point in the history
…present
  • Loading branch information
alexgobbo committed May 14, 2018
1 parent 58356b4 commit 75e6795
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions src/main/java/ch/psi/pshell/ui/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,16 @@ static String getHelpMessage() {
sb.append("\n\t-nlaf\tUse Nimbus look and feel (cross platform)");
sb.append("\n\t-dlaf\tUse a dark look and feel (cross platform)");
sb.append("\n\t-args=...\tProvide arguments to interpreter");
sb.append("\n\t-f=<..>\tRuns a file instead of entering interactive shell (together with -c option)");
sb.append("\n\t-p=<..>\tLoads a plugin");
sb.append("\n\t-f=<..>\tRun a file instead of entering interactive shell (together with -c option)");
sb.append("\n\t-p=<..>\tLoad a plugin");

if (isStripChart()){
sb.append("\n\nStrip Chart arguments:");
sb.append("\n\t-f=<..>\tOpen a Strip Chart configuration file (.scd)");
sb.append("\n\t-config=<..>\tLoad a JSON configuration string (same format as in .scd file)");
sb.append("\n\t-start\tStart the data displaying immediately");
}
sb.append("\n");
return sb.toString();
}

Expand Down Expand Up @@ -250,6 +258,10 @@ static public boolean isHelpOnly() {
static public boolean isAutoClose() {
return App.hasArgument("a");
}

static public boolean isStripChart() {
return hasArgument("strp");
}

static public File getFileArg() {
try {
Expand Down Expand Up @@ -705,7 +717,7 @@ public Object showPanel(GenericDevice dev) {
if (isConsole()) {
startStandaloneShell();
logger.log(Level.INFO, "Create shell");
} else if (hasArgument("strp")) {
} else if (isStripChart()) {
StripChart.create(getFileArg(), getArgumentValue("config"), getStripChartFolderArg(), hasArgument("start"));
} else {
if (isDual()) {
Expand Down

0 comments on commit 75e6795

Please sign in to comment.