本文整理汇总了Java中lecho.lib.hellocharts.model.Line.setAreaTransparency方法的典型用法代码示例。如果您正苦于以下问题:Java Line.setAreaTransparency方法的具体用法?Java Line.setAreaTransparency怎么用?Java Line.setAreaTransparency使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类lecho.lib.hellocharts.model.Line
的用法示例。
在下文中一共展示了Line.setAreaTransparency方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: avg1Line
import lecho.lib.hellocharts.model.Line; //导入方法依赖的package包/类
public Line avg1Line() {
List<PointValue> myLineValues = new ArrayList<PointValue>();
myLineValues.add(new PointValue((float) avg1startfuzzed, (float) unitized(avg1value)));
myLineValues.add(new PointValue((float) end_time, (float) unitized(avg1value)));
Line myLine = new Line(myLineValues);
myLine.setHasPoints(false);
myLine.setStrokeWidth(1);
myLine.setColor(getCol(X.color_average1_line));
myLine.setPathEffect(new DashPathEffect(new float[]{10.0f, 10.0f}, 0));
myLine.setAreaTransparency(50);
return myLine;
}
示例2: avg2Line
import lecho.lib.hellocharts.model.Line; //导入方法依赖的package包/类
public Line avg2Line() {
List<PointValue> myLineValues = new ArrayList<PointValue>();
myLineValues.add(new PointValue((float) start_time, (float) unitized(avg2value)));
myLineValues.add(new PointValue((float) end_time, (float) unitized(avg2value)));
Line myLine = new Line(myLineValues);
myLine.setHasPoints(false);
myLine.setStrokeWidth(1);
myLine.setColor(getCol(X.color_average2_line));
myLine.setPathEffect(new DashPathEffect(new float[]{30.0f, 10.0f}, 0));
myLine.setAreaTransparency(50);
return myLine;
}
示例3: idealLine
import lecho.lib.hellocharts.model.Line; //导入方法依赖的package包/类
public Line idealLine() {
// if profile has more than 1 target bg value then we need to iterate those and plot them for completeness
List<PointValue> myLineValues = new ArrayList<PointValue>();
myLineValues.add(new PointValue((float) start_time, (float) Profile.getTargetRangeInUnits(start_time)));
myLineValues.add(new PointValue((float) predictive_end_time, (float) Profile.getTargetRangeInUnits(predictive_end_time)));
Line myLine = new Line(myLineValues);
myLine.setHasPoints(false);
myLine.setStrokeWidth(1);
myLine.setColor(getCol(X.color_target_line));
myLine.setPathEffect(new DashPathEffect(new float[]{5f, 5f}, 0));
myLine.setAreaTransparency(50);
return myLine;
}
示例4: predictiveLowLine
import lecho.lib.hellocharts.model.Line; //导入方法依赖的package包/类
public Line predictiveLowLine() {
List<PointValue> lowLineValues = new ArrayList<PointValue>();
lowLineValues.add(new PointValue((float) end_time, (float) lowMark));
lowLineValues.add(new PointValue((float) predictive_end_time, (float) lowMark));
Line lowLine = new Line(lowLineValues);
lowLine.setHasPoints(false);
lowLine.setAreaTransparency(40);
lowLine.setColor(ChartUtils.darkenColor(ChartUtils.darkenColor(ChartUtils.darkenColor(getCol(X.color_low_values)))));
lowLine.setStrokeWidth(1);
lowLine.setFilled(true);
return lowLine;
}
示例5: motionLine
import lecho.lib.hellocharts.model.Line; //导入方法依赖的package包/类
private List<Line> motionLine() {
final ArrayList<ActivityRecognizedService.motionData> motion_datas = ActivityRecognizedService.getForGraph((long) start_time * FUZZER, (long) end_time * FUZZER);
List<PointValue> linePoints = new ArrayList<>();
final float ypos = (float)highMark;
int last_type = -9999;
final ArrayList<Line> line_array = new ArrayList<>();
Log.d(TAG,"Motion datas size: "+motion_datas.size());
if (motion_datas.size() > 0) {
motion_datas.add(new ActivityRecognizedService.motionData((long) end_time * FUZZER, DetectedActivity.UNKNOWN)); // terminator
for (ActivityRecognizedService.motionData item : motion_datas) {
Log.d(TAG, "Motion detail: " + JoH.dateTimeText(item.timestamp) + " activity: " + item.activity);
if ((last_type != -9999) && (last_type != item.activity)) {
extend_line(linePoints, item.timestamp / FUZZER, ypos);
Line new_line = new Line(linePoints);
new_line.setHasLines(true);
new_line.setPointRadius(0);
new_line.setStrokeWidth(1);
new_line.setAreaTransparency(40);
new_line.setHasPoints(false);
new_line.setFilled(true);
switch (last_type) {
case DetectedActivity.IN_VEHICLE:
new_line.setColor(Color.parseColor("#70445599"));
break;
case DetectedActivity.ON_FOOT:
new_line.setColor(Color.parseColor("#70995599"));
break;
}
line_array.add(new_line);
linePoints = new ArrayList<>();
}
//current
switch (item.activity) {
case DetectedActivity.ON_FOOT:
case DetectedActivity.IN_VEHICLE:
extend_line(linePoints, item.timestamp / FUZZER, ypos);
last_type = item.activity;
break;
default:
// do nothing?
break;
}
}
}
Log.d(TAG,"Motion array size: "+line_array.size());
return line_array;
}