Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
172 views
in Technique[技术] by (71.8m points)

javascript - JavaScript图表库(JavaScript Chart Library)

Would anyone recommend a particular JavaScript charting library - specifically one that doesn't use flash at all?(有人会推荐一种特定的JavaScript图表库-特别是根本不使用Flash的图书馆吗?)

  ask by community wiki translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

There is a growing number of Open Source and commercial solutions for pure JavaScript charting that do not require Flash.(越来越多的不需要Flash的用于纯JavaScript制图的开源和商业解决方案。)

In this response I will only present Open Source options.(在此回复中,我将仅介绍开放源代码选项。) There are 2 main classes of JavaScript solutions for graphics that do not require Flash:(对于不需要Flash的图形,有两种主要的JavaScript解决方案类:) Canvas-based, rendered in IE using ExplorerCanvas that in turns relies on VML(基于画布,基于IE使用ExplorerCanvas呈现,而后者又依赖于VML) SVG on standard-based browsers, rendered as VML in IE(基于标准的浏览器上的SVG,在IE中呈现为VML) There are pros and cons of both approaches but for a charting library I would recommend the later because it is well integrated with DOM, allowing to manipulate charts elements with the DOM, and most importantly setting DOM events.(两种方法都有优点和缺点,但对于制图库,我建议使用后者,因为它与DOM集成良好,允许使用DOM操作图表元素,最重要的是设置DOM事件。) By contrast Canvas charting libraries must reinvent the DOM wheel to manage events.(相比之下,Canvas制图库必须重新发明DOM轮以管理事件。) So unless you intend to build static graphs with no event handling, SVG/VML solutions should be better.(因此,除非您打算构建没有事件处理的静态图,否则SVG / VML解决方案应该更好。) For SVG/VML solutions there are many options, including:(对于SVG / VML解决方案,有很多选择,包括:) Dojox Charting , good if you use the Dojo toolkit already(Dojox Charting ,如果您已经使用过Dojo工具包那就很好) Raphael -based solutions(基于Raphael的解决方案) Raphael is a very active, well maintained, and mature, open-source graphic library with very good cross-browser support including IE 6 to 8, Firefox, Opera, Safari, Chrome, and Konqueror.(Raphael是一个非常活跃,维护良好且成熟的开源图形库,具有很好的跨浏览器支持,包括IE 6至8,Firefox,Opera,Safari,Chrome和Konqueror。) Raphael does not depend on any JavaScript framework and therefore can be used with Prototype, jQuery, Dojo, Mootools, etc...(Raphael不依赖任何JavaScript框架,因此可以与Prototype,jQuery,Dojo,Mootools等一起使用。) There are a number of charting libraries based on Raphael, including (but not limited to):(有许多基于Raphael的制图库,包括(但不限于):) gRaphael , an extension of the Raphael graphic library(gRaphael是Raphael图形库的扩展) Ico , with an intuitive API based on a single function call to create complex charts(Ico具有基于单个函数调用的直观API,可以创建复杂的图表) Disclosure: I am the developer of one of the Ico forks on github .(披露:我是github上Ico分支之一的开发人员。)

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...