如何更改图例条目的形状?(How to change the shape of legend entry?)
我正在使用VisualStudio WebForm C#开发一个图表。 在图例部分中,它不能将指示符/图像/形状更改为破折号。 (可以使用excel轻松完成。有什么方法吗?
我想要的是: - - - - 收入平均值(想象一下是虚线图像)-------收入(想象一下是实线)
我能做的最接近的是:
LegendItem item1 = new LegendItem(); item1.Color = Color.Black; item1.Name = "Income Average"; item1.BackHatchStyle = ChartHatchStyle.DarkVertical; // Adding it into chart legend chart1.Legends[0].CustomItems.Add(item1);
建议要求谢谢。
I'm developing a chart in VisualStudio WebForm C#. In the legend part, It cannot change the indicator/image/shape as dash. (It can be done easily using excel. Is there any method?
What I want is: - - - - Income Average (Imagine is dashed image) ------- Income (Imagine is a solid line)
The closest I can make is:
LegendItem item1 = new LegendItem(); item1.Color = Color.Black; item1.Name = "Income Average"; item1.BackHatchStyle = ChartHatchStyle.DarkVertical; // Adding it into chart legend chart1.Legends[0].CustomItems.Add(item1);
Advices required thanks.
原文:https://stackoverflow.com/questions/20563010
最满意答案
尝试使用
strip_tags
转换HTML标记。<p>{!! strip_tags($alert['message']) !!}</p>
或者,您也可以使用
htmlspecialchars
函数来打印<script>
或类似标签:<p>{!! htmlspecialchars($alert['message']) !!}</p>
这会将特殊实体转换为HTML。
Try to use
strip_tags
to convert HTML tags.<p>{!! strip_tags($alert['message']) !!}</p>
Or, you can also use
htmlspecialchars
function to print<script>
or similar tags:<p>{!! htmlspecialchars($alert['message']) !!}</p>
This will convert special entities to HTML.