prefs.setInteger(keyLineWidth, component.getDataViewLineWidth(device));
String keyLineStyle = keyPrefix + ".lineStyle";
prefs.setInteger(keyLineStyle, component.getDataViewLineStyle(device));
CometeColor curveColor = component.getDataViewCurveProperties(device).getColor();
String greenKeyLineColor = keyPrefix + ".green";
String redKeyLineColor = keyPrefix + ".red";
String blueKeyLineColor = keyPrefix + ".blue";
String alphaKeyLineColor = keyPrefix + ".alpha";
if (curveColor != null) {
prefs.setInteger(greenKeyLineColor, curveColor.getGreen());
prefs.setInteger(redKeyLineColor, curveColor.getRed());
prefs.setInteger(blueKeyLineColor, curveColor.getBlue());
prefs.setInteger(alphaKeyLineColor, curveColor.getAlpha());
}
String keyFillStyle = keyPrefix + ".fillStyle";
prefs.setInteger(keyFillStyle, component.getDataViewFillStyle(device));
// The method getDataViewViewType() for Curve properties tab is missing
// The method getDataViewCometeFillColor() is not working
CometeColor curveFillColor = component.getDataViewCometeFillColor(device);
String greenFillColor = keyPrefix + ".fill.green";
String redFillColor = keyPrefix + ".fill.red";
String blueFillColor = keyPrefix + ".fill.blue";
String alphaFillColor = keyPrefix + ".fill.alpha";
if (curveFillColor != null) {
prefs.setInteger(greenFillColor, curveFillColor.getGreen());
prefs.setInteger(redFillColor, curveFillColor.getRed());
prefs.setInteger(blueFillColor, curveFillColor.getBlue());
prefs.setInteger(alphaFillColor, curveFillColor.getAlpha());
}
String keyBarWidth = keyPrefix + ".barWidth";
prefs.setInteger(keyBarWidth, component.getDataViewBarWidth(device));
String keyFillMethod = keyPrefix + ".barFillMethod";
prefs.setInteger(keyFillMethod, component.getDataViewFillMethod(device));
// The methods getDataViewTransformA0(), getDataViewTransformA1(),
// getDataViewTransformA2() are not working
String keyTransformA0 = keyPrefix + ".transformA0";
prefs.setDouble(keyTransformA0, component.getDataViewTransformA0(device));
String keyTransformA1 = keyPrefix + ".transformA1";
prefs.setDouble(keyTransformA1, component.getDataViewTransformA1(device));
String keyTransformA2 = keyPrefix + ".transformA2";
prefs.setDouble(keyTransformA2, component.getDataViewTransformA2(device));
String keyMarkerVisible = keyPrefix + ".markerVisible";
if (component.getDataViewMarkerProperties(device).isLegendVisible()) {
prefs.setBoolean(keyMarkerVisible, "true");
}
else {
prefs.setBoolean(keyMarkerVisible, "false");
}
String keyMarkerSize = keyPrefix + ".markerSize";
prefs.setInteger(keyMarkerSize, component.getDataViewMarkerSize(device));
String keyMarkerStyle = keyPrefix + ".markerStyle";
prefs.setInteger(keyMarkerStyle, component.getDataViewMarkerStyle(device));
CometeColor markerColor = component.getDataViewMarkerProperties(device).getColor();
if (markerColor != null) {
String redMarkerCometeColor = keyPrefix + ".marker.red";
String greenMarkerCometeColor = keyPrefix + ".marker.green";
String blueMarkerCometeColor = keyPrefix + ".marker.blue";
String alphaMarkerCometeColor = keyPrefix + ".marker.alpha";
prefs.setInteger(redMarkerCometeColor, markerColor.getRed());
prefs.setInteger(greenMarkerCometeColor, markerColor.getGreen());
prefs.setInteger(blueMarkerCometeColor, markerColor.getBlue());
prefs.setInteger(alphaMarkerCometeColor, markerColor.getAlpha());
}
String smoothingExtrapolation = keyPrefix + ".smoothingExtrapolation";
prefs.setInteger(smoothingExtrapolation, component
.getDataViewSmoothingExtrapolation(device));