update plotType drop down on selection

The drop down for plot types should only contain plot types that can
be combined. The reason is, that we can only draw images with two
x/y-axis. Therefore a combination of types that would need three or more
axis is not supported.
This commit is contained in:
2019-12-27 18:45:37 +01:00
parent aede78a285
commit 4f5fe15ac7
4 changed files with 29 additions and 31 deletions

View File

@@ -45,7 +45,10 @@ public class AggregateHandlerCollection {
// TODO merge axis definitions and use the greater values for: range,
// ticsIncrement
} else {
Preconditions.checkSmaller(result.size(), 2, "at most two different axis are supported");
Preconditions.checkSmaller(result.size(), 2,
"At most two different axis are supported. "
+ "The combination of plot types needs more than two " + axis
+ "-axis. Remove one or more plot types.");
final GnuplotAxis mirrorAxis = axis.mirrorAxis();
handler.updateAxis(mirrorAxis);
result.add(type);