增加SerieSymbol的Color、Opacity配置

This commit is contained in:
monitor1394
2019-08-07 23:33:27 +08:00
parent 4684affac6
commit 6c680d0d98
6 changed files with 6912 additions and 37203 deletions

View File

@@ -79,8 +79,8 @@ namespace XCharts
{
continue;
}
var color = m_ThemeInfo.GetColor(serieNameCount);
color.a = 200;
var color = serie.symbol.color != Color.clear ? serie.symbol.color : (Color)m_ThemeInfo.GetColor(serieNameCount);
color.a *= serie.symbol.opacity;
int maxCount = maxShowDataNumber > 0 ?
(maxShowDataNumber > serie.dataCount ? serie.dataCount : maxShowDataNumber)
: serie.dataCount;
@@ -111,7 +111,7 @@ namespace XCharts
for (int count = 0; count < serie.symbol.animationSize.Count; count++)
{
var nowSize = serie.symbol.animationSize[count];
color.a = (byte)(255 * (symbolSize - nowSize) / symbolSize);
color.a = (symbolSize - nowSize) / symbolSize;
DrawSymbol(vh, serie.symbol.type, nowSize, 3, pos, color);
}
RefreshChart();