jqplot Background Color Zones?

匿名 (未验证) 提交于 2019-12-03 10:24:21

问题:

I would like to be able to have several different "zones" indicated by the background on my jqplot bar chart.

I have looked through the documentation, but have been unable to easily identify a way to do this.

Is there a simple "fill" function or parameter that would allow me to set the background in several bands of horizontal color (various heights)?

Thanks in advance.

FG

回答1:

I would use a similar approach as I suggest in the answer to a different question here.

A direct link to the code sample.

You would then set the sizes of the underlying lines accordingly to highlight your regions. This approach is for example used by @Katya presented in the link under one of the comments to the aforementioned answer.

Direct link to Katya's code sample.



回答2:

You can also use the rectangle overlay developed by Bruno Harbulot : https://bitbucket.org/harbulot/jqplot

Here is a jsFiddle sample : http://jsfiddle.net/K2cVL/1/



转载请标明出处:jqplot Background Color Zones?
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!