确定 ASP.NET Chart 控件使用的颜色

发布于 2024-08-12 12:37:52 字数 273 浏览 4 评论 0原文

我想了解 ASP.NET Chart 控件中的特定调色板使用哪些颜色。

我已经知道 Chart 类上有一个枚举来设置调色板,例如

myChart.Palette = ChartColorPalette.Berry;

但我想知道哪些颜色属于调色板。

在有人问之前(我知道您会问),我需要知道颜色的原​​因是因为我想在图表图像之外创建自己的图例。

我还知道我可以在图表的数据点上设置自己的颜色,但我不想实现自己的调色板。

I'd like to find out which colours are used for a particular pallette in the ASP.NET Chart control.

I already know there is an enum on the Chart class to set the palette, e.g.

myChart.Palette = ChartColorPalette.Berry;

But I'd like to know which colours belong to the palette.

Before anyone asks - as I know you will - the reason I need to know the colours is because I want to create my own legend outside of the chart image.

I also know that I can set my own colours on the DataPoints for the chart, but I'd rather not have to implement my own palette.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文